JP2749286B2 - Auto focus camera - Google Patents

Auto focus camera

Info

Publication number
JP2749286B2
JP2749286B2 JP16066995A JP16066995A JP2749286B2 JP 2749286 B2 JP2749286 B2 JP 2749286B2 JP 16066995 A JP16066995 A JP 16066995A JP 16066995 A JP16066995 A JP 16066995A JP 2749286 B2 JP2749286 B2 JP 2749286B2
Authority
JP
Japan
Prior art keywords
subroutine
mode
camera
communication
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Lifetime
Application number
JP16066995A
Other languages
Japanese (ja)
Other versions
JPH07318789A (en
Inventor
東 宮沢
栄二 大塚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Olympus Corp
Original Assignee
Olympus Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Olympus Corp filed Critical Olympus Corp
Priority to JP16066995A priority Critical patent/JP2749286B2/en
Publication of JPH07318789A publication Critical patent/JPH07318789A/en
Application granted granted Critical
Publication of JP2749286B2 publication Critical patent/JP2749286B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Focusing (AREA)
  • Automatic Focus Adjustment (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】この発明はオートフォーカスカメ
ラの撮影レンズの駆動に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to driving of a photographic lens of an autofocus camera.

【0002】[0002]

【従来の技術】オートフォーカスカメラにおいては、モ
ータによりレンズが駆動されオートフォーカス動作が行
われる。ここで、オートフォーカス動作時等のレンズの
駆動時に何らかの異常が生じ、レンズが途中で停止した
場合、特定の異常処理を行ないレンズを所定の位置に復
帰させている。この異常処理の一例が特開昭62−17
5721号公報に記載されている。
2. Description of the Related Art In an autofocus camera, a motor drives a lens to perform an autofocus operation. Here, if any abnormality occurs during driving of the lens such as during an autofocus operation and the lens stops halfway, specific abnormal processing is performed to return the lens to a predetermined position. An example of this abnormal processing is disclosed in JP-A-62-17.
No. 5721.

【0003】しかし、この従来技術には異常停止状態で
あることを揮発性のメモリに記憶することが記載されて
いるだけであり、故障解析等のために、外部装置と接続
して検査することについては記載されていない。
[0003] However, this conventional technique has an abnormal stop state.
It is stated that there is a storage in volatile memory
Connected to external devices for failure analysis, etc.
There is no mention of conducting inspections.

【0004】このように従来のオートフォーカスカメラ
は、レンズ駆動の異常状態を検出した場合に、レンズの
駆動を停止する。この状態で故障解析のために外部装置
と接続して検査を行うとしても、異常状態で停止したま
まであるので、外部装置と通信を行うことができず、正
確な故障解析をすることができなかった。
As described above, the conventional auto-focus camera detects the abnormal state of the lens drive, and
Stop driving. In this state, external devices for failure analysis
Even if an inspection is performed by connecting to the
Communication with external devices.
No accurate failure analysis could be performed.

【0005】[0005]

【発明が解決しようとする課題】 本発明は上述した事情
に対処すべくなされたもので、その目的は電源が遮断さ
れてもレンズ駆動の異常状態を記憶しておくことがで
き、異常処理動作でも外部装置との通信を可能とし、
正確な故障解析が可能なオートフォーカスカメラを提供
することである。
SUMMARY OF THE INVENTION The present invention has been made in view of the above circumstances, and has as its object to be able to store an abnormal state of lens driving even when the power is turned off, and to perform an abnormal processing operation. it possible to communicate with an external device among,
An object of the present invention is to provide an autofocus camera capable of performing accurate failure analysis .

【0006】[0006]

【課題を解決するための手段】本発明のオートフォーカ
スカメラは、撮影レンズの焦点調節量を検出する手段
と、上記焦点調節量に基づいて上記撮影レンズを駆動す
る手段と、上記撮影レンズの駆動に伴ってパルスを発生
させるパルス発生手段と、上記パルスが所定の時間発生
しなかったときは異常と判断する異常判断手段と、カメ
ラの電源が遮断された場合でも記憶状態を保持する電気
的に書換え可能な不揮発性記憶素子で構成され、上記異
常判断に基づいて異常状態を記憶する記憶手段と、上記
異常判断手段によって異常状態と判断された際に、上記
駆動手段による駆動を停止するとともに外部装置との通
信を実行可能とする異常処理手段とを具備するものであ
る。
According to the present invention, there is provided an autofocus camera, comprising: means for detecting a focus adjustment amount of a photographic lens; means for driving the photographic lens based on the focus adjustment amount; and driving of the photographic lens. and abnormality determining means for determining an abnormality when a pulse generating means for generating a pulse, in which the pulse has not occurred a predetermined time in association with, turtle
Electricity that retains its memory state even when the power to the
Manner is composed of rewritable nonvolatile memory element, and storing means for storing the abnormal state on the basis of the abnormality determination, when it is determined that the abnormal state by the abnormality determination means, the
Stop the driving by the driving means and communicate with the external device.
Error processing means for making communication possible.
You.

【0007】[0007]

【作用】本発明によるオートフォーカスカメラによれ
ば、電源が遮断されてもレンズ駆動の異常状態を電気的
に書換え可能な不揮発性記憶素子に記憶しておき、電源
再投入後の異常処理動作中であっても、外部装置と通信
を行うことができるので、通信によって不揮発性記憶素
子に異常状態であったことが記憶されているか否かを検
知することにより、容易に故障解析をすることができ
る。
According to the autofocus camera of the present invention, the abnormal state of the lens drive can be electrically detected even when the power is cut off.
Stored in a rewritable nonvolatile memory element, and
Communicates with external devices even during abnormal processing operation after re-input
Can be performed, and the non-volatile memory
Check whether the abnormal condition is stored in the child.
With this knowledge, failure analysis can be performed easily.
You.

【0008】[0008]

【実施例】以下、図面を参照してこの発明によるオート
フォーカスカメラの一実施例を説明する。図1は一実施
例の概略を示すブロック図である。1チップマイクロコ
ンピュータからなるCPU10を有するカメラ1に外部
装置2が着脱自在に接続される。CPU10はカメラ1
の種々の動作を制御するプログラムをサブルーチンとし
て有する。カメラ1は外部(EXT)端子3を有し、こ
のEXT端子3を介してカメラ1と外部装置2とが接続
される。これにより、カメラCPU10と外部装置CP
U4とが通信可能となる。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of an autofocus camera according to the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram schematically showing one embodiment. An external device 2 is detachably connected to a camera 1 having a CPU 10 composed of a one-chip microcomputer. CPU 10 is camera 1
As a subroutine. The camera 1 has an external (EXT) terminal 3, and the camera 1 and the external device 2 are connected via the EXT terminal 3. Thereby, the camera CPU 10 and the external device CP
Communication with U4 becomes possible.

【0009】外部装置2はCPU4以外に、操作スイッ
チ5と表示部6を有する。外部装置2としては出荷前の
カメラの調整機器や特殊な撮影を可能とするオプション
のアダプタ機器等が考えられる。
The external device 2 has an operation switch 5 and a display unit 6 in addition to the CPU 4. Examples of the external device 2 include an adjustment device for a camera before shipment and an optional adapter device for enabling special shooting.

【0010】図2にカメラCPU10と外部装置2との
接続を示す。カメラCPU10のCHECK1端子は通
常は“H”レベルであり、外部装置2はカメラと通信を
行なう前にCHECK1端子を“L”レベルにする。こ
のため、CPU10はCHECK1端子のレベルを検出
することにより、外部装置2が通信要求を出したかどう
か判定できる。
FIG. 2 shows the connection between the camera CPU 10 and the external device 2. The CHECK1 terminal of the camera CPU 10 is normally at "H" level, and the external device 2 sets the CHECK1 terminal to "L" level before communicating with the camera. Therefore, the CPU 10 can determine whether the external device 2 has issued a communication request by detecting the level of the CHECK1 terminal.

【0011】通信のためのクロックCLKはカメラ1か
ら発生され、外部装置2はこのクロックCLKに同期し
て、データラインDATAを介して通信内容(コード化
データ)をCPU10に送信する。このデータラインD
ATAは双方向のシリアル通信ラインである。
A clock CLK for communication is generated from the camera 1, and the external device 2 transmits communication contents (coded data) to the CPU 10 via the data line DATA in synchronization with the clock CLK. This data line D
ATA is a bidirectional serial communication line.

【0012】カメラ1の詳細を図3に示す。CPU10
はカメラ全体の動作を制御し、基本クロックは発振回路
20より供給され、リセット回路22からのリセットに
より動作開始される。リセット回路22は電池挿入時、
及びパワースイッチ(図示せず)のオン/オフ動作時に
動作する。
FIG. 3 shows the details of the camera 1. CPU10
Controls the operation of the entire camera, the basic clock is supplied from the oscillation circuit 20, and the operation is started by a reset from the reset circuit 22. When the battery is inserted, the reset circuit 22
And operates when a power switch (not shown) is turned on / off.

【0013】E2 −PROM24は駒数、カメラ状態デ
ータ(巻上げ中、巻戻し中等)、異常データ(故障箇
所)、調整データ(シャッタ制御補正データ、オートフ
ォーカス補正データ、バッテリチェックデータ等の各カ
メラ毎のデータ)を記憶している不揮発性メモリであ
る。このため、交換のために電池が一旦抜かれても、こ
れらのデータは有効である。また、E2 −PROM24
へのデータ書込み中はリセット回路22のリセット動作
は禁止されている。
The E 2 -PROM 24 stores the number of frames, camera status data (winding, rewinding, etc.), abnormal data (fault location), adjustment data (shutter control correction data, autofocus correction data, battery check data, etc.). Is a non-volatile memory that stores data for each. Therefore, even if the battery is removed once for replacement, these data are valid. In addition, E 2 -PROM24
The reset operation of the reset circuit 22 is prohibited while data is being written to the memory.

【0014】E2 −PROM24を読出しモードにする
と、まずDXコードがDX端子26から入力され、シリ
アルライン28を介してCPU10に入力される。つづ
いて、E2 −PROM24のデータがCPU10に転送
される。
When the E 2 -PROM 24 is set to the read mode, the DX code is first input from the DX terminal 26 and is input to the CPU 10 via the serial line 28. Then, data of the E 2 -PROM24 is transferred to the CPU 10.

【0015】AFセンサ(AFIC)30は、例えば位
相差方式のセンサであり、距離データをCPU10に供
給する。CPU10は測光値が一定値以下の暗い場合に
は、AFIC30の動作に合せて補助光源32を点灯す
る。
The AF sensor (AFIC) 30 is, for example, a phase difference sensor, and supplies distance data to the CPU 10. The CPU 10 turns on the auxiliary light source 32 in accordance with the operation of the AFIC 30 when the photometric value is darker than a certain value.

【0016】E2 −PROM24、EXT端子3、AF
IC30はCPU10の入出力ポートを有効利用するた
めに、同一のシリアルライン28に接続され、CPU1
0とデータのやりとりをシリアル通信で行なう。
E 2 -PROM 24, EXT terminal 3, AF
The IC 30 is connected to the same serial line 28 in order to use the input / output port of the CPU 10 effectively.
Data exchange with 0 is performed by serial communication.

【0017】操作スイッチ群34はカメラの種々の操作
スイッチからなり、レリーズスイッチ、モード切換えス
イッチ等からなる。LED群36はファインダ内のLE
Dであり、ストロボ発光予告、合焦表示等のLEDから
なる。LCD38はカメラの表面のLCDであり、駒
数、カメラモード等を表示する。
The operation switch group 34 includes various operation switches of the camera, and includes a release switch, a mode switch, and the like. The LED group 36 is the LE in the viewfinder.
D, which includes LEDs for strobe light emission notice, focus indication, and the like. The LCD 38 is an LCD on the surface of the camera, and displays the number of frames, the camera mode, and the like.

【0018】インターフェース(IFIC)40はモー
タドライバ50や測光ユニット42との信号の伝授、L
CD38への電源の供給、ストロボ64に対するチャー
ジ、及びバッテリチェック等を行なう。なお、図3では
電源は図示を省略している。また、インターフェース4
0はCPU10からの命令によりシャッタモータ(M
s)44、巻上げモータ(Mw)46、ズームモータ
(Mz)48を選択するデコード機能等も持ったインタ
フェースである。なお、デコード機能は測光ユニット4
2での平均測光とスポット測光との切換えも含む。これ
らのモータ44,46,48はインターフェース40の
デコード信号によりモータドライバ50を介して駆動さ
れる。
An interface (IFIC) 40 transmits and receives signals to and from the motor driver 50 and the photometric unit 42.
The power supply to the CD 38, the charging of the strobe 64, the battery check, and the like are performed. Note that the power supply is not shown in FIG. Also, interface 4
0 is a shutter motor (M
s) 44, a winding motor (Mw) 46, and a zoom function (Mz) 48 for selecting a decode function. The decoding function is provided by the photometric unit 4
2 includes switching between average photometry and spot photometry. These motors 44, 46, 48 are driven via a motor driver 50 by a decode signal of the interface 40.

【0019】シャッタモータ44は正転時にオートフォ
ーカスのためのレンズ駆動、逆転時にシャッタ駆動す
る。ここでは、シャッタはレンズシャッタが採用されて
いるとする。
The shutter motor 44 drives a lens for automatic focusing during normal rotation, and performs shutter driving during reverse rotation. Here, it is assumed that a lens shutter is employed as the shutter.

【0020】オートフォーカシングの際、CPU10は
AFIC30で求めた距離データとE2 −PROM24
の調整データを演算して求めた目標位置までモータ44
を正転し、フォーカシングレンズを駆動する。ここで、
フォーカシングレンズのリセット位置はスイッチ(AF
s)52のオン状態で確認され、レンズ位置は、フォー
カシングレンズの単位移動量当り1パルス発生されるフ
ォトインタラプタ(PIs)54のパルス数で確認され
る。
[0020] when the auto-focusing, the distance data and the E CPU10 was determined by the AFIC30 2 -PROM24
To the target position obtained by calculating the adjustment data of
Is rotated forward to drive the focusing lens. here,
The reset position of the focusing lens is set with a switch (AF
s) The confirmation is made in the ON state of 52, and the lens position is confirmed by the number of pulses of the photo interrupter (PIs) 54 generated for one pulse per unit movement amount of the focusing lens.

【0021】すなわち、CPU10はフォトインタラプ
タ(PIs)54の出力を参照してモータ44の正転、
ブレーキ、オフの制御を行ない、目標位置にフォーカシ
ングレンズを停止させる。
That is, the CPU 10 refers to the output of the photo interrupter (PIs) 54 and
Controls braking and off, and stops the focusing lens at the target position.

【0022】シャッタ制御時のモータ44のリセット位
置はスイッチ(AEs)56のオン状態で確認され、E
2 −PROM24の調整データによりデューティ駆動の
比率を変化させることにより一定開口波形が保たれるよ
うに制御される。
The reset position of the motor 44 during the shutter control is confirmed by turning on the switch (AEs) 56.
By controlling the duty drive ratio in accordance with the adjustment data of the 2- PROM 24, control is performed so that a constant aperture waveform is maintained.

【0023】巻上げモータ46は正転時にフィルム巻上
げを、逆転時にフィルム巻戻しを行なう。フィルムの一
駒巻上げ制御はフォトインタラプタ(PIw)58のパ
ルス数をカウントすることにより行われる。
The winding motor 46 winds the film at the time of forward rotation and rewinds the film at the time of reverse rotation. One frame winding control of the film is performed by counting the number of pulses of the photo interrupter (PIw) 58.

【0024】フォトインタラプタ54,58はそれぞれ
シャッタモータ44、巻上げモータ46が選択された時
のみオンとなり、フォトインタラプタ54,58の出力
はIFIC40を介してディジタル的にノイズを除去し
てCPU10に入力される。これは、フォトインタラプ
タ54,58の出力を直接CPU10に入力すると、ノ
イズによりカウント値に誤差が生じることがあるからで
ある。
The photo interrupters 54 and 58 are turned on only when the shutter motor 44 and the hoist motor 46 are selected, respectively. The outputs of the photo interrupters 54 and 58 are input to the CPU 10 after digitally removing noise through the IFIC 40. You. This is because if the outputs of the photo interrupters 54 and 58 are directly input to the CPU 10, an error may occur in the count value due to noise.

【0025】ズームモータ(Mz)48はレンズをズー
ミングし、ズーム位置はズームエンコーダ60により知
ることができる。デートモジュール62は日付、時刻等
のデータをフィルムに写し込むものである。ストロボ6
4もCPU10に接続される。
The zoom motor (Mz) 48 zooms the lens, and the zoom position can be known by the zoom encoder 60. The date module 62 prints data such as date and time on a film. Strobe 6
4 is also connected to the CPU 10.

【0026】次にこの実施例の動作を説明する。先ず、
図4乃至図28を参照してカメラ側のCPU10の動作
を説明し、次いで、図29乃至図35を参照して外部装
置側のCPU4の動作を説明する。
Next, the operation of this embodiment will be described. First,
The operation of the CPU 10 on the camera side will be described with reference to FIGS. 4 to 28, and then the operation of the CPU 4 on the external device side will be described with reference to FIGS. 29 to 35.

【0027】図4はカメラCPU10の『パワーオンリ
セット』ルーチンのフローチャートであり、このルーチ
ンはリセット回路22のリセット動作により開始する。
すなわち、電源が投入されるか、パワースイッチのオン
/オフ動作を行なうと、カメラは先ずこのルーチンを実
行する。
FIG. 4 is a flowchart of a "power-on reset" routine of the camera CPU 10. This routine is started by a reset operation of the reset circuit 22.
That is, when the power is turned on or the power switch is turned on / off, the camera first executes this routine.

【0028】ステップ102 でCPU10の入出力ポー
ト、および内蔵RAMの初期セットを行なう。ステップ
104 でCHECK1端子が“L”レベル、すなわち外部
装置から通信要求が発生されているかどうか判定する。
CHECK1端子が“L”レベルの場合は、ステップ10
6 でサブルーチン『外部装置との通信1』(図24〜図
27)を実行する。
In step 102, the input / output ports of the CPU 10 and the internal RAM are initialized. Steps
At 104, it is determined whether the CHECK1 terminal is at the "L" level, that is, whether a communication request has been issued from an external device.
If the CHECK1 terminal is at the "L" level, step 10
In step 6, the subroutine "communication 1 with external device" (FIGS. 24 to 27) is executed.

【0029】CHECK1端子が“L”レベルでない場
合、またはサブルーチン『外部装置との通信1』が終了
した場合、ステップ108 でサブルーチン『E2 −PRO
M読出し』(図15)を実行し、E2 −PROM24か
らカメラ状態データ、調整データ等がCPU10のRA
Mに書込まれる。ここで始めてカメラ動作が可能な状態
となる。もし、巻上げ、巻戻し、空送り中において電池
がなくなったり、パワースイッチをオフにした場合は、
動作が中断するが、電源再投入時に、中断前の状態を知
る必要がある。
In the case CHECK1 terminal is not "L" level, or if the subroutine "communication with the external device 1 'has been completed, 2 subroutine" E in step 108 -PRO
M reading ”(FIG. 15), and the camera status data, adjustment data, and the like from the E 2 -PROM 24 are stored in the RA of the CPU 10.
Written in M. Only here can the camera be operated. If you run out of batteries or turn off the power switch during winding, rewinding, or empty feeding,
Although the operation is interrupted, it is necessary to know the state before the interruption when the power is turned on again.

【0030】E2 −PROM24から読出したバッテリ
チェックデータを参照して、ステップ110 でサブルーチ
ン『バッテリチェック』(図20)を実行する。次に、
2 −PROM24から読出したカメラ状態データを参
照して、カメラの動作状態をチェックする。ステップ11
2 でカメラの裏蓋の開閉に連動する裏蓋スイッチの出力
により裏蓋が閉じているかどうか判定する。閉じている
場合は、ステップ114 で巻戻し中かどうか判定する。巻
戻し中の場合は、ステップ116 でサブルーチン『巻戻
し』を実行する。
Referring to the battery check data read from the E 2 -PROM 24, a subroutine “battery check” (FIG. 20) is executed in step 110. next,
Referring to camera status data read from the E 2 -PROM24, checks the operation state of the camera. Step 11
In step 2, it is determined whether or not the back cover is closed based on the output of the back cover switch that is linked to the opening and closing of the camera back cover. If it is closed, it is determined in step 114 whether rewinding is in progress. If rewinding is in progress, a subroutine "rewind" is executed in step 116.

【0031】巻戻し中でない場合は、ステップ118 で空
送り中かどうか判定する。空送り中の場合は、ステップ
120 でサブルーチン『空送り』を実行する。空送り中で
ない場合は、ステップ122 で巻上げ中かどうか判定す
る。巻上げ中の場合は、ステップ124 でサブルーチン
『一駒巻上げ』(図14)を実行する。
If it is not during rewinding, it is determined in step 118 whether or not idle feeding is being performed. Step during empty feeding
In step 120, the subroutine "jump feed" is executed. If not, it is determined in step 122 whether or not winding is being performed. If winding is in progress, a subroutine "single frame winding" (FIG. 14) is executed in step 124.

【0032】カメラの裏蓋が閉じていない場合、サブル
ーチン『巻戻し』、『空送り』、または『一駒巻上げ』
が終了した場合、または巻上げ中でない場合は、ステッ
プ126 でパワースイッチがオンかどうか判定する。
If the back cover of the camera is not closed, the subroutine "rewind", "jump feed" or "wind one frame"
Is completed, or if the film is not being wound, it is determined in step 126 whether the power switch is on.

【0033】パワースイッチがオンの場合は、ステップ
128 でLCD38をオンし、ステップ130 でサブルーチ
ン『ストロボチャージ』を実行する。これは、いつでも
ストロボ撮影可能な状態にしておくためである。ステッ
プ132 で90秒タイマをセットする。このタイマはLC
D38の表示時間を90秒に制限するものである。ただ
し、後述するように、表示中にユーザが何らかのスイッ
チ操作をした場合、その時点で再び90秒タイマがセッ
トされる。
If the power switch is on,
At step 128, the LCD 38 is turned on, and at step 130, a subroutine "strobe charge" is executed. This is to ensure that flash photography can be performed at any time. In step 132, a 90 second timer is set. This timer is LC
The display time of D38 is limited to 90 seconds. However, as described later, if the user performs any switch operation during display, the 90-second timer is set again at that point.

【0034】ステップ134 で裏蓋スイッチ(BK)によ
る割込み、巻戻しスイッチ(RW)による割込み、モー
ド指定スイッチ等の各種操作スイッチ(KEYG)によ
る割込み、及びタイマ(65.5ミリ秒)による割込み
の受付を許可する。
At step 134, an interruption by the back cover switch (BK), an interruption by the rewind switch (RW), an interruption by various operation switches (KEYG) such as a mode designation switch, and an interruption by the timer (65.5 milliseconds). Allow the reception.

【0035】ステップ136 でホルトモードにする。ホル
ト動作中は、CPU10の動作は停止しているが、発振
回路20のクロック発振は行われ、LCD38も90秒
間は表示可能である。このホルト動作中のスタンバイ解
除は上述したステップ134 で許可された割込みが発生し
た場合のみ有効とされる。
In step 136, the halt mode is set. During the halt operation, the operation of the CPU 10 is stopped, but the clock oscillation of the oscillation circuit 20 is performed, and the LCD 38 can also display for 90 seconds. The standby release during the halt operation is valid only when the interrupt permitted in step 134 occurs.

【0036】パワースイッチがオンでない場合は、ステ
ップ138 でLCD38をオフし、ステップ140 でBK割
込み、RW割込みのみを許可し、ステップ142 でストッ
プモードになる。ストップ動作でのスタンバイ解除はス
テップ140 で許可された割込みが発生した場合のみ有効
とされる。
If the power switch is not on, the LCD 38 is turned off at step 138, only the BK interrupt and the RW interrupt are permitted at step 140, and the stop mode is set at step 142. The standby release in the stop operation is valid only when the interrupt permitted in step 140 occurs.

【0037】図5〜図7は『スタンバイ解除』ルーチン
のフローチャートであり、ホルト動作(ステップ136
)、ストップ動作(ステップ142 )において割込みが
発生した時に開始される。このように、この実施例で
は、ホルトモード、ストップモードにかかわらず、スタ
ンバイ解除後は同一のルーチンに移行する。これは、ベ
クタ割込みでスタンバイ解除後の動作をそれぞれ定義す
ると、割込みはノイズによっても発生するので、誤動作
を防止するためと、誤ってスタイバイ解除された場合の
処理を簡単にするためである。
FIG. 5 to FIG. 7 are flowcharts of the "standby release" routine, and show the halt operation (step 136).
), And is started when an interrupt occurs in the stop operation (step 142). As described above, in this embodiment, the same routine is performed after the standby mode is released, regardless of the halt mode or the stop mode. This is because if an operation after standby release is defined by a vector interrupt, the interrupt is also generated by noise, so that a malfunction is prevented, and a process in the case where the standby is released by mistake is simplified.

【0038】ステップ150 で、ステップ102 と同様にC
PU10の入出力ポート、および内蔵RAMの初期セッ
トを行なう。ステップ152 でサブルーチン『E2 −PR
OM読出し』(図15)を実行する。これは、ノイズに
よりRAMの内容が変化した場合を補償するためであ
る。
In step 150, C is performed in the same manner as in step 102.
The initial setting of the input / output port of the PU 10 and the built-in RAM is performed. In step 152 subroutine "E 2 -PR
OM readout ”(FIG. 15). This is to compensate for the case where the contents of the RAM have changed due to noise.

【0039】ステップ154 でこのルーチンを開始した割
込みはBK割込みかどうか判定する。BK割込みの場合
は、ステップ156 で裏蓋が閉じているかどうか判定す
る。裏蓋が閉じている場合は、ステップ158 でサブルー
チン『空送り』を実行する。サブルーチン『空送り』が
終了した場合はステップ126 に戻り、パワースイッチの
状態をチェックする。
In step 154, it is determined whether or not the interrupt that started this routine is a BK interrupt. In the case of a BK interrupt, it is determined in step 156 whether the back cover is closed. If the back cover is closed, a subroutine "idling" is executed in step 158. When the subroutine "idling" is completed, the flow returns to step 126 to check the state of the power switch.

【0040】裏蓋が閉じていない場合は、ステップ160
でサブルーチン『裏蓋開』を実行し、駒数、カメラ状態
データをリセットする。サブルーチン『裏蓋開』の終了
後はステップ126 に戻る。裏蓋が開でも閉でもない場合
は、ノイズが有ると判定する。
If the back cover is not closed, step 160
To execute the subroutine "back cover open" to reset the number of frames and camera state data. After the end of the subroutine "back cover opening", the process returns to step 126. If the back cover is neither open nor closed, it is determined that there is noise.

【0041】BK割込みでない場合、あるいはノイズが
有ると判定した場合は、ステップ162 でRW割込みかど
うか判定する。RW割込みの場合は、ステップ164 で巻
戻しスイッチがオンかどうか判定する。巻戻しスイッチ
がオンの場合は、ステップ166 でサブルーチン『巻戻
し』を実行する。サブルーチン『巻戻し』の終了後はス
テップ126 に戻る。
If it is not a BK interrupt or if it is determined that there is noise, it is determined in step 162 whether or not it is a RW interrupt. In the case of an RW interrupt, it is determined in step 164 whether the rewind switch is on. If the rewind switch is on, a subroutine "rewind" is executed in step 166. After the end of the subroutine "rewind", the flow returns to step 126.

【0042】RW割込みでない場合、あるいは巻戻しス
イッチがオンでないの場合は、ステップ168 でタイマ割
込みかどうか判定する。タイマ割込みの場合は、ステッ
プ170 でサブルーチン『表示タイマカウント』(図8)
を実行する。すなわち、サブルーチン『表示タイマカウ
ント』は65.5ミリ秒毎に実行される。サブルーチン
『表示タイマカウント』の終了後はステップ134 に戻
る。
If it is not an RW interrupt, or if the rewind switch is not on, it is determined in step 168 whether it is a timer interrupt. In the case of a timer interrupt, the subroutine "display timer count" is executed in step 170 (FIG. 8).
Execute That is, the subroutine "display timer count" is executed every 65.5 milliseconds. After the end of the subroutine "display timer count", the flow returns to step 134.

【0043】タイマ割込みでない場合は、ステップ172
で巻戻し終了、または空送り失敗であるかどうか判定す
る。巻戻し終了、空送り失敗でない場合は、ステップ17
4 でパワースイッチがオンかどうか判定する。巻戻し終
了、空送り失敗の場合、またはパワースイッチがオンで
ない場合は、ステップ126 に戻る。
If not a timer interrupt, step 172
To determine whether rewinding has been completed or whether the unsuccessful feeding has failed. Step 17 if rewinding is not completed and jumping failure is not failed
4. Determine if the power switch is on. When the rewinding is completed, when the idle feeding fails, or when the power switch is not turned on, the process returns to step 126.

【0044】パワースイッチがオンの場合は、ステップ
176 でKEYG割込みかどうか判定する。KEYG割込
みでない場合は、ステップ178 でLCD表示中かどうか
判定する。LCD表示中でない場合は、ステップ180 で
BK,RW,KEYG割込みを許可し、ステップ182 で
ストップモードになる。このモードは、パワースイッチ
はオンであっても、90秒間ユーザが何も操作しなかっ
たために、LCD38が消える場合である。パワースイ
ッチがオンであれば、ユーザが何らかの操作をすると、
LCD38は再び表示状態となる。
If the power switch is on,
At 176, it is determined whether or not it is a KEYG interrupt. If it is not a KEYG interrupt, it is determined in step 178 whether or not the LCD is being displayed. If the LCD display is not being performed, the BK, RW, and KEYG interrupts are permitted in step 180, and the stop mode is set in step 182. In this mode, even if the power switch is on, the LCD 38 goes out because the user has not operated anything for 90 seconds. When the power switch is on, when the user performs any operation,
The LCD 38 returns to the display state.

【0045】KEYG割込みである場合は、ノイズでK
EYGのポートの状態が変化していてもスイッチ入力を
受付けられるようにするため、KEYGのポートをステ
ップ184 で入力ポートに切換える。ステップ186 でLC
D38をオンする。
In the case of a KEYG interrupt, K
At step 184, the KEYG port is switched to the input port so that the switch input can be accepted even if the state of the EYG port has changed. LC at step 186
D38 is turned on.

【0046】ステップ188 でレリーズボタンが1段押込
まれた(1段目レリーズ)かどうか判定する。1段目レ
リーズの場合は、ステップ190 でサブルーチン『レリー
ズ処理』(図10、図11)を実行する。
In step 188, it is determined whether or not the release button has been depressed one step (first step release). In the case of the first stage release, a subroutine "release process" (FIGS. 10 and 11) is executed in step 190.

【0047】1段目レリーズでない場合は、ステップ19
2 でマクロ状態かどうか判定する。マクロ状態でない場
合は、ステップ194 でズームアップ、またはズームダウ
ンかどうか判定する。ズームアップ、またはズームダウ
ンの場合は、ステップ196 でサブルーチン『ズーム処
理』を実行する。
If it is not the first release, step 19
Step 2 determines whether the camera is in macro mode. If it is not in the macro state, it is determined in step 194 whether the zoom is up or down. In the case of zoom up or zoom down, a subroutine "zoom processing" is executed in step 196.

【0048】サブルーチン『レリーズ処理』、または
『ズーム処理』が終了した場合は、ステップ197 でサブ
ルーチン『レンズリセット』を実行し、フォーカシング
レンズをリセット位置まで戻す。
When the subroutine "release processing" or "zoom processing" is completed, a subroutine "lens reset" is executed in step 197 to return the focusing lens to the reset position.

【0049】サブルーチン『レンズリセット』が終了し
た場合はステップ126 に戻る。マクロ状態である場合、
またはズームアップ、ズームダウンではない場合は、ス
テップ198 でマクロ切換えスイッチがオンかどうか判定
する。スイッチがオンの場合は、ステップ200 でサブル
ーチン『マクロ処理』を実行する。サブルーチン『マク
ロ処理』が終了した場合はステップ126 に戻る。
When the subroutine "lens reset" is completed, the flow returns to step 126. When in macro state,
Otherwise, if it is not zoom-up or zoom-down, it is determined in step 198 whether the macro switch is on. If the switch is on, a subroutine "macro processing" is executed in step 200. When the subroutine "macro processing" is completed, the flow returns to step 126.

【0050】マクロ切換えスイッチがオフの場合は、カ
メラモードスイッチをチェックし、ステップ202 で第1
モードスイッチがオンかどうか判定し、第1モードスイ
ッチがオンの場合は、ステップ204 でサブルーチン『セ
ルフモード』を実行する。サブルーチン『セルフモー
ド』は撮影モードを通常モード、セルフモードに順次切
換える。サブルーチン『セルフモード』が終了した場合
はステップ126 に戻る。
If the macro switch is off, the camera mode switch is checked, and the first
It is determined whether the mode switch is on. If the first mode switch is on, a subroutine "self mode" is executed in step 204. The subroutine "self mode" sequentially switches the shooting mode between the normal mode and the self mode. When the subroutine "Self Mode" is completed, the flow returns to step 126.

【0051】第1モードスイッチがオフの場合は、ステ
ップ206 で第2モードスイッチがオンかどうか判定し、
第2モードスイッチがオンの場合は、ステップ208 でサ
ブルーチン『測光モード』を実行する。サブルーチン
『測光モード』は測光方式を平均測光、スポット測光、
スポットハイライト測光、スポットシャドー測光に順次
切換える。サブルーチン『測光モード』が終了した場合
はステップ126 に戻る。
If the first mode switch is off, it is determined in step 206 whether the second mode switch is on,
If the second mode switch is on, a subroutine "photometry mode" is executed in step 208. The subroutine "Metering mode" is used for the metering method, average metering, spot metering,
Switch sequentially to spot highlight metering and spot shadow metering. When the subroutine "photometry mode" is completed, the flow returns to step 126.

【0052】第2モードスイッチがオフの場合は、ステ
ップ210 で第3モードスイッチがオンかどうか判定し、
第3モードスイッチがオンの場合は、ステップ212 でサ
ブルーチン『ストロボモード』を実行する。サブルーチ
ン『ストロボモード』は発光モードを自動発光、強制発
光(日中シンクロ)、発光禁止に順次切換える。サブル
ーチン『ストロボモード』が終了した場合はステップ12
6 に戻る。
If the second mode switch is off, it is determined in step 210 whether the third mode switch is on.
If the third mode switch is on, a subroutine "strobe mode" is executed in step 212. In the subroutine "strobe mode", the light emission mode is sequentially switched to automatic light emission, forced light emission (daylight synchronization), and light emission inhibition. Step 12 when subroutine "strobe mode" ends
Return to 6.

【0053】第3モードスイッチがオフの場合は、ステ
ップ214 で第4モードスイッチがオンかどうか判定し、
第4モードスイッチがオンの場合は、ステップ216 でサ
ブルーチン『カメラモード』(図9)を実行する。サブ
ルーチン『カメラモード』では、カメラモードを標準
(一駒)、オートズーム、連写、多重露光(2枚)撮
影、∞モードに順次切換える。サブルーチン『カメラモ
ード』が終了した場合はステップ126 に戻る。
If the third mode switch is off, it is determined in step 214 whether the fourth mode switch is on,
If the fourth mode switch is on, a subroutine "camera mode" (FIG. 9) is executed in step 216. In the subroutine "camera mode", the camera mode is sequentially switched to standard (one frame), auto zoom, continuous shooting, multiple exposure (two images) shooting, and ∞ mode. When the subroutine "camera mode" is completed, the flow returns to step 126.

【0054】第4モードスイッチがオフの場合はステッ
プ134 に戻る。図8はサブルーチン『表示タイマカウン
ト』(図5のステップ170 )のフローチャートである。
ステップ230 でCHECK1端子が“L”かどうか判定
する。CHECK1端子が“L”の場合は、ステップ23
2 でサブルーチン『外部装置との通信1』(図22〜図
27)を実行する。このため、サブルーチン『外部装置
との通信1』は65.5ミリ秒毎に実行可能であり、こ
のプログラムではサブルーチン『外部装置との通信1』
を連続して実行することは不可能である。後述するよう
に、サブルーチン『外部装置との通信1』を連続して実
行するプログラムは別に設けられている。
If the fourth mode switch is off, the routine returns to step 134. FIG. 8 is a flowchart of the subroutine "display timer count" (step 170 in FIG. 5).
At step 230, it is determined whether the CHECK1 terminal is "L". If the CHECK1 terminal is "L", step 23
In step 2, the subroutine "communication 1 with external device" (FIGS. 22 to 27) is executed. For this reason, the subroutine "communication 1 with external device" can be executed every 65.5 milliseconds.
Cannot be executed continuously. As described later, a program for continuously executing the subroutine "communication 1 with external device 1" is provided separately.

【0055】CHECK1端子が“L”でない場合、ま
たはサブルーチン『外部装置との通信1』が終了した場
合、ステップ234 で90秒経過したかどうか判定する。
90秒経過した場合はステップ180 (図6)に戻り、ス
トップモードになる。90秒経過しない場合はステップ
236 でサブルーチン『LCD点滅処理』を実行する。こ
こでは、LCD38の警告表示等が65.5ミリ秒を一
定量分周した間隔でオン/オフされ点滅する。サブルー
チン『LCD点滅処理』の終了後はステップ134 に戻
る。
If the CHECK1 terminal is not "L", or if the subroutine "communication 1 with external device" is completed, it is determined in step 234 whether 90 seconds have elapsed.
If 90 seconds have elapsed, the flow returns to step 180 (FIG. 6) to enter the stop mode. Step if not 90 seconds
At 236, a subroutine "LCD blinking process" is executed. Here, a warning display or the like on the LCD 38 is turned on / off at an interval obtained by dividing 65.5 milliseconds by a fixed amount, and blinks. After the subroutine "LCD blinking process" is completed, the routine returns to step 134.

【0056】図9はサブルーチン『カメラモード』(図
7のステップ216 )のフローチャートである。ステップ
240 でモードRAM(MRAM)をインクリメントする
(MRAM←MRAM+1)。ステップ242 でMRAM
が5以上かどうか判定する。MRAMが5以上の場合は
ステップ244 でモードRAMがリセットされる(MRA
M←0)。すなわち、MRAMのデータ0,1,2,
3,4が標準、オートズーム、連写、多重露光、∞の各
カメラモードに対応する。
FIG. 9 is a flowchart of the subroutine "camera mode" (step 216 in FIG. 7). Steps
At 240, the mode RAM (MRAM) is incremented (MRAM ← MRAM + 1). MRAM in step 242
Is determined to be 5 or more. If the MRAM is 5 or more, the mode RAM is reset in step 244 (MRA).
M ← 0). That is, data 0, 1, 2,
3 and 4 correspond to the standard, auto zoom, continuous shooting, multiple exposure, and ∞ camera modes.

【0057】図10、図11はサブルーチン『レリーズ
処理』(図6のステップ190 )のフローチャートであ
る。ステップ250 でCHECK1端子が“L”かどうか
判定する。CHECK1端子が“L”の場合は、ステッ
プ252 でサブルーチン『外部装置との通信2』(図24
〜図27)を実行する。
FIGS. 10 and 11 are flowcharts of the subroutine "release processing" (step 190 in FIG. 6). At step 250, it is determined whether or not the CHECK1 terminal is "L". If the CHECK1 terminal is "L", the subroutine "communication with external device 2" is executed in step 252 (FIG. 24).
To FIG. 27).

【0058】CHECK1端子が“L”でない場合、ま
たはサブルーチン『外部装置との通信2』が終了した場
合、ステップ254 でサブルーチン『測光』を実行する。
ステップ256 で∞モードかどうか判定する。∞モードの
場合は、ステップ258で距離データとして∞データをセ
ットする。ステップ260 でサブルーチン『測距』を実行
する。
If the CHECK1 terminal is not "L", or if the subroutine "communication with external device 2" has been completed, the subroutine "photometry" is executed in step 254.
In step 256, it is determined whether the mode is the mode. In the case of the ∞ mode, ∞ data is set in step 258 as distance data. In step 260, a subroutine "ranging" is executed.

【0059】距離データとして∞データがセットされた
場合、またはサブルーチン『測距』が終了した場合、ス
テップ262 でオートズームモードかどうか判定する。オ
ートズームモードの場合は、ステップ264 でサブルーチ
ン『オートズーム』を実行する。サブルーチン『オート
ズーム』は撮影距離にかかわらず常に人物が一定の大き
さで撮影されるように、距離データに応じて自動的にズ
ーム位置を設定する。
When the $ data is set as the distance data, or when the subroutine "ranging" is completed, it is determined in step 262 whether or not the mode is the auto zoom mode. In the case of the auto zoom mode, a subroutine "auto zoom" is executed in step 264. The subroutine "auto zoom" automatically sets the zoom position according to the distance data so that a person is always photographed at a fixed size regardless of the photographing distance.

【0060】オートズームモードでない場合、サブルー
チン『オートズーム』が終了した場合、ステップ266 で
サブルーチン『AF(レンズ繰出し)』(図12)を実
行し、フォーカスレンズを合焦位置まで駆動する。ステ
ップ268 でサブルーチン『露出演算』を実行する。
If the automatic zoom mode is not set and the subroutine "auto zoom" is completed, a subroutine "AF (lens extension)" (FIG. 12) is executed in step 266 to drive the focus lens to the in-focus position. In step 268, a subroutine "exposure calculation" is executed.

【0061】ステップ270 でレリーズボタンが全部押込
まれた(2段目レリーズ)かどうか判定する。2段目レ
リーズでない場合は、ステップ272 で1段目レリーズか
どうか判定する。1段目レリーズの場合はステップ270
に戻る。この状態は、AFロックの状態である。1段目
レリーズを解除するともとのルーチンに戻る。
In step 270, it is determined whether or not the release button has been fully depressed (second stage release). If it is not the second release, it is determined in step 272 whether it is the first release. Step 270 for the first release
Return to This state is an AF lock state. When the first release is released, the routine returns to the original routine.

【0062】2段目レリーズの場合は撮影動作に入り、
先ず、ステップ274 でサブルーチン『バッテリチェッ
ク』(図20)を実行する。後述するが、バッテリがな
い場合はここで動作を停止する。
In the case of the second stage release, the photographing operation is started,
First, in step 274, a subroutine "battery check" (FIG. 20) is executed. As will be described later, if there is no battery, the operation is stopped here.

【0063】ステップ276 でセルフモードかどうか判定
する。セルフモードの場合は、ステップ278 で第1モー
ドスイッチがオンかどうか判定する。第1モードスイッ
チがオンの場合はステップ126 (図4)に戻り、パワー
スイッチの状態をチェックする。すなわち、第1モード
スイッチをオンすることにより、セルフ待ち状態を途中
解除することができる。
At step 276, it is determined whether the mode is the self mode. In the case of the self mode, it is determined at step 278 whether the first mode switch is on. If the first mode switch is on, the flow returns to step 126 (FIG. 4) to check the state of the power switch. That is, by turning on the first mode switch, the self-waiting state can be canceled halfway.

【0064】第1モードスイッチがオフの場合は、ステ
ップ280 でセルフタイマ(12秒)がカウントアップ
(終了)かどうか判定する。カウント終了でない場合は
ステップ278 に戻る。
If the first mode switch is off, it is determined in step 280 whether the self-timer (12 seconds) has counted up (finished). If the counting is not completed, the flow returns to step 278.

【0065】セルフモードでない場合、またはカウント
終了の場合は、ステップ282 でサブルーチン『露出』を
実行し、シャッタ動作を行なう。ストロボ発光モードの
場合は、ここで、ストロボが発光する。
If it is not the self mode or if the counting is completed, a subroutine "exposure" is executed in step 282 to perform a shutter operation. In the case of the strobe light emission mode, the strobe light is emitted here.

【0066】ステップ284 で多重露光モードかどうか判
定する。多重露光モードの場合は、ステップ286 で多重
1枚フラグがセットされているどうか判定する。多重1
枚フラグがセットされていない場合は、ステップ286 で
多重1枚フラグをセットする。ステップ290 でサブルー
チン『E2 −PROM書込み』(図19)を実行し、も
とのルーチンに戻る。これにより、多重1枚フラグをE
2 −PROM24に書込む。多重1枚フラグがセットさ
れている場合は、ステップ292 で多重1枚フラグをリセ
ットする。
In step 284, it is determined whether the mode is the multiple exposure mode. In the case of the multiple exposure mode, it is determined in step 286 whether the multiple single image flag is set. Multiple 1
If the sheet flag is not set, the multiplexed single sheet flag is set in step 286. Run the subroutine "E 2 -PROM writing" (FIG. 19) at step 290, returns to the original routine. As a result, the multiple single sheet flag is set to E
2- Write to PROM 24. If the multiplex single sheet flag is set, the multiplex single sheet flag is reset in step 292.

【0067】多重露光モードでない場合、または多重1
枚フラグをリセットした場合、ステップ294 でフィルム
有りかどうか判定する。フィルム有りの場合は、ステッ
プ296 でサブルーチン『一駒巻上げ』(図14)を実行
する。
If the mode is not the multiple exposure mode or
When the sheet flag is reset, it is determined in step 294 whether or not there is a film. If there is a film, a subroutine "winding one frame" (FIG. 14) is executed in step 296.

【0068】フィルム有りでない場合、またはサブルー
チン『一駒巻上げ』が終了した場合、ステップ298 で連
写モードかどうか判定する。連写モードの場合はステッ
プ270 に戻り、レリーズボタンが押込まれている限り連
写が継続する。連写モードでない場合はもとのルーチン
に戻る。
If there is no film, or if the subroutine "winding one frame" is completed, it is determined in step 298 whether or not the mode is the continuous shooting mode. In the case of the continuous shooting mode, the process returns to step 270, and continuous shooting continues as long as the release button is pressed. If the mode is not the continuous shooting mode, the process returns to the original routine.

【0069】図12はサブルーチン『AF(レンズ繰り
出し)』(図10のステップ266 )のフローチャートで
ある。ステップ302 でタイマリセットする。ステップ30
3 で測距データとE2 −PROMの調整データによりレ
ンズ繰出し目標位置を決定する。ステップ304 でシャッ
タモータMsを正回転し、フォーカシングレンズを駆動
する。
FIG. 12 is a flowchart of the subroutine "AF (lens extension)" (step 266 in FIG. 10). In step 302, the timer is reset. Step 30
3 in determining a lens extension target position by adjusting data of distance measurement data and E 2 -PROM. In step 304, the shutter motor Ms is rotated forward to drive the focusing lens.

【0070】ステップ306 でフォトインタラプタPIs
の出力が立下った(パルスが1つ発生された)かどうか
判定する。立下った場合は、ステップ308 でカウンタを
カウントアップする。このカウント値を用いて、ステッ
プ310 でフォーカシングレンズが目標位置まで繰り出さ
れたかどうか判定する。目標位置まで繰り出されていな
い場合は、ステップ306 に戻る。
In step 306, the photo interrupter PIs
It is determined whether the output has fallen (one pulse has been generated). If so, the counter is counted up in step 308. Using this count value, it is determined in step 310 whether the focusing lens has been extended to the target position. If it has not been advanced to the target position, the flow returns to step 306.

【0071】目標位置まで繰り出された場合は、ステッ
プ312 でシャッタモータMsの回転を停止する。ステッ
プ314 でAFレンズフラグをリセットする。ステップ31
6 でサブルーチン『E2 −PROM書込み』(図19)
を実行する。この後、もとのルーチンに戻る。
If it has been moved to the target position, the rotation of the shutter motor Ms is stopped in step 312. At step 314, the AF lens flag is reset. Step 31
Subroutine "E 2 -PROM writing" in 6 (FIG. 19)
Execute Thereafter, the process returns to the original routine.

【0072】ステップ306 でフォトインタラプタPIs
の出力が立下っていない場合は、ステップ318 で、フォ
トインタラプタの立下がりから1秒経過したかどうか判
定する。1秒経過していない場合はステップ306 に戻
る。1秒経過した場合は異常と判定し、ステップ320 で
シャッタモータMsの回転を停止する。異常を示すAF
レンズフラグをステップ322 でセットする。
At step 306, the photo interrupter PIs
If the output has not fallen, it is determined in step 318 whether one second has elapsed since the fall of the photointerrupter. If one second has not elapsed, the process returns to step 306. If one second has elapsed, it is determined that there is an abnormality, and in step 320, the rotation of the shutter motor Ms is stopped. AF indicating abnormality
A lens flag is set in step 322.

【0073】ステップ324 でサブルーチン『E2 −PR
OM書込み』(図19)を実行する。ステップ326 でサ
ブルーチン『ダメージ処理』(図13)を実行する。図
13はサブルーチン『ダメージ処理』のフローチャート
である。ステップ332 で全てのアクチュエータをオフす
る。ステップ334 でポートを初期セットする。ステップ
336 で90秒タイマをセットする。ステップ338 で90
秒経過したかどうか判定する。
[0073] subroutine at step 324 "E 2 -PR
OM writing ”(FIG. 19). In step 326, a subroutine "damage processing" (FIG. 13) is executed. FIG. 13 is a flowchart of the subroutine "damage processing". At step 332, all actuators are turned off. At step 334, a port is initially set. Steps
Set the 90 second timer with 336. Step 338 at 90
Determine if seconds have elapsed.

【0074】90秒経過した場合は、ステップ340 でス
トップモードとなる。ステップ340はエンドレスループ
を構成していて、ノイズでストップモードが解除されて
も、再びストップモードにすることによりストップモー
ドが解除できない構成となっている。当然、このエンド
レスループの中にポートの初期セット及びストップ解除
不許可命令を入れておけばさらに良いことは言うまでも
ない。
If 90 seconds have elapsed, the stop mode is set in step 340. Step 340 forms an endless loop. Even if the stop mode is canceled due to noise, the stop mode cannot be canceled by setting the stop mode again. Naturally, it is needless to say that an initial setting of a port and an instruction for disabling stop release are inserted in this endless loop.

【0075】90秒経過していない場合は、ステップ34
2 でCHECK1端子が“L”かどうか判定する。CH
ECK1端子が“L”の場合は、ステップ344 でサブル
ーチン『外部装置との通信3』(図24〜図27)を実
行する。これにより、カメラ異常中でも、外部装置と通
信が可能である。
If 90 seconds have not elapsed, step 34
At 2, it is determined whether the CHECK1 terminal is "L". CH
If the ECK1 terminal is "L", the subroutine "communication with external device 3" (FIGS. 24 to 27) is executed in step 344. Thus, communication with an external device is possible even during a camera abnormality.

【0076】CHECK1端子が“L”でない場合、ま
たはサブルーチン『外部装置との通信3』が終了した場
合、ステップ364 でタイマ割込みを許可し、ステップ36
6 でホルトモードになる。タイマ割込みによりホルトモ
ードが解除されると、ステップ338 に戻る。このサブル
ーチンはパワーオンリセットまで動作する。
If the CHECK1 terminal is not "L", or if the subroutine "communication with external device 3" has been completed, the timer interrupt is permitted in step 364, and step 36
6 enters halt mode. When the halt mode is released by the timer interrupt, the process returns to step 338. This subroutine operates until a power-on reset.

【0077】図14はサブルーチン『一駒巻上げ』(図
4のステップ124 、図11のステップ296 )のフローチ
ャートである。ステップ370 で巻上げ中かどうか判定す
る。巻上げ中でない場合は、ステップ372 で巻上げカウ
ンタをリセットする。ステップ374 で巻上げ中フラグを
セットする。ステップ376 でサブルーチン『E2 −PR
OM書込み』(図19)を実行し、巻上げ中フラグをE
2 −PROM24に書込む。これは、巻上げ中に電源が
オフになった場合でも、前の状態を復元するためであ
る。
FIG. 14 is a flowchart of the subroutine "wind one frame" (step 124 in FIG. 4, step 296 in FIG. 11). At step 370, it is determined whether or not the film is being wound. If not, the winding counter is reset at step 372. In step 374, a winding flag is set. In step 376 subroutine "E 2 -PR
OM writing ”(FIG. 19) and set the winding flag to E.
2- Write to PROM 24. This is to restore the previous state even if the power is turned off during winding.

【0078】巻上げ中の場合、またはサブルーチン『E
2 −PROM書込み』が終了した場合、ステップ378 で
巻上げモータMwを正回転し、フィルムを巻上げる。ス
テップ380 でフォトインタラプタPIwの出力が立下っ
た(パルスが1つ発生された)かどうか判定する。立下
った場合は、ステップ382 で巻上げカウンタをカウント
アップする。このカウント値を用いて、ステップ384 で
一駒巻上げが終了したかどうか判定する。
During winding, or in the subroutine "E
When the " 2- PROM writing" is completed, the winding motor Mw is rotated forward in step 378 to wind the film. In step 380, it is determined whether or not the output of the photo interrupter PIw has fallen (one pulse has been generated). If it has fallen, the winding counter is counted up in step 382. Using this count value, it is determined in step 384 whether the winding of one frame has been completed.

【0079】フォトインタラプタPIwの出力が立下っ
ていない場合、または一駒巻上げが終了していない場合
は、ステップ394 でフィルムエンドかどうか判定する。
フィルムエンドはフォトインタラプタPIwの出力が2
秒以上変化しない場合である。フィルムエンドでない場
合はステップ380 に戻り、フィルムエンドの場合はステ
ップ396 でサブルーチン『巻戻し』を実行する。
If the output of the photo-interrupter PIw has not fallen, or if the winding of one frame has not been completed, it is determined in step 394 whether or not the film has ended.
In the film end, the output of the photo interrupter PIw is 2
It does not change for more than a second. If it is not the film end, the flow returns to step 380. If it is the film end, the subroutine "rewind" is executed in step 396.

【0080】一駒巻上げが終了した場合は、ステップ38
6 で巻上げモータMwの回転を停止する。ステップ388
で駒数カウンタをカウントアップする。ステップ390 で
巻上げ中フラグをリセットする。ステップ392 でサブル
ーチン『E2 −PROM書込み』(図19)を実行し、
巻上げ中フラグ(リセット)をE2 −PROM24に書
込む。この後もとのルーチンに戻る。
When the winding of one frame is completed, step 38
At 6, the rotation of the hoist motor Mw is stopped. Step 388
To increment the frame number counter. At step 390, the winding flag is reset. Run the subroutine "E 2 -PROM write" (FIG. 19) at step 392,
Hoisting flag (reset) written in the E 2 -PROM24. Thereafter, the process returns to the original routine.

【0081】なお、サブルーチン『空送り』はフィルム
ローディングし裏蓋を閉じた後、自動的に数駒フィルム
を巻上げるものであり、サブルーチン『一駒巻上げ』を
数回連続して実行するものである。サブルーチン『巻戻
し』もサブルーチン『一駒巻上げ』と同様に、フィルム
が停止するまで巻上げモータを逆転するものである。
Note that the subroutine "Jump-Advance" automatically winds several frames of film after loading the film and closing the back cover, and executes the subroutine "Single-frame winding" several times continuously. is there. The subroutine "rewinding" is similar to the subroutine "single frame winding", in which the winding motor is reversed until the film stops.

【0082】図15はサブルーチン『E2 −PROM読
出し』(図4のステップ108 、図5のステップ152 )の
フローチャートである。ステップ402 でE2 −PROM
24のアドレスを1にリセットし、ステップ404 でE2
−PROM24のモードを読出しモードとする。ステッ
プ406 でCPU10をシリアル通信入力モードとし、ス
テップ408 でRAMアドレス(ADR)にEPをセット
する。
[0082] Figure 15 is a flowchart of a subroutine "E 2 -PROM reading" (step 108 in FIG. 4, step 152 of FIG. 5). In step 402 E 2 -PROM
24 is reset to 1, and at step 404 E 2
-Set the mode of the PROM 24 to the read mode. At step 406, the CPU 10 is set to the serial communication input mode, and at step 408, EP is set to the RAM address (ADR).

【0083】ここで、各RAMアドレスの内容は図16
に示すようになっている。各データは8ビットのデータ
であり、RAMアドレスEP+1のカメラ状態データの
各ビットの内容は図17に、RAMアドレスEP+2の
異常データの各ビットの内容は図18に示すようになっ
ている。
The contents of each RAM address are shown in FIG.
It is shown as follows. Each data is 8-bit data. The contents of each bit of the camera status data at the RAM address EP + 1 are as shown in FIG. 17, and the contents of each bit of the abnormal data at the RAM address EP + 2 are as shown in FIG.

【0084】ステップ410 でE2 −PROM24から8
つのビットデータをシリアル入力し、E2 −PROM2
4のアドレスをインクリメントする。ステップ412 でシ
リアル入力データをRAMアドレス(ADR)にセット
する。ステップ414 でRAMアドレスをインクリメント
する。ステップ416 でRAMアドレスがE2 −PROM
24のデータ数を越えたかどうか判定する。越えた場合
はもとのルーチンに戻り、越えない場合はステップ410
に戻り、次のアドレスの8つのビットデータをシリアル
入力する。
[0084] In the step 410 from the E 2 -PROM24 8
One of the bit data a serial input, E 2 -PROM2
4 is incremented. At step 412, the serial input data is set at the RAM address (ADR). At step 414, the RAM address is incremented. RAM address in step 416. E 2 -PROM
It is determined whether the number of data exceeds 24. If exceeded, return to the original routine; otherwise, step 410
And serially inputs eight bits of data at the next address.

【0085】図19はサブルーチン『E2 −PROM書
込み』(図11のステップ290 等)のフローチャートで
ある。ステップ422 でE2 −PROM24をリセット
し、E2 −PROM24のアドレスを1とする。ステッ
プ424 でE2 −PROM24を書込みモードに設定す
る。ステップ426 でシリアル通信出力モードを設定し、
ステップ428 でRAMアドレス(ADR)にEPをセッ
トする。
[0085] Figure 19 is a flowchart of a subroutine "E 2 -PROM write" (step 290, etc. of FIG. 11). Reset the E 2 -PROM24 at step 422, and 1 address of E 2 -PROM24. In step 424 sets the E 2 -PROM24 the write mode. In step 426, set the serial communication output mode,
At step 428, EP is set to the RAM address (ADR).

【0086】ステップ430 でCPU10のシリアルアウ
トレジスタにADR番地のデータをセットし、ステップ
432 でシリアル出力し、8つのビットデータをE2 −P
ROM24に転送する。ステップ434 でRAMアドレス
をインクリメントする。
At step 430, the data of the ADR address is set in the serial out register of the CPU 10, and
Serial output 432, E 2 -P eight-bit data
Transfer to the ROM 24. At step 434, the RAM address is incremented.

【0087】ステップ436 でRAMアドレスがE2 −P
ROM24のデータ数を越えたかどうか判定する。越え
た場合はもとのルーチンに戻り、越えない場合はステッ
プ430 に戻り、次のアドレスの8つのビットデータをシ
リアル出力する。
In step 436, when the RAM address is E 2 -P
It is determined whether the number of data in the ROM 24 has been exceeded. If it exceeds, the process returns to the original routine. If it does not exceed, the process returns to step 430 to serially output eight bits of data at the next address.

【0088】図20はサブルーチン『バッテリチェッ
ク』(図4のステップ110 )のフローチャートである。
バッテリチェックは、図21に示すように、カメラ内の
電源電圧VDDを抵抗R1,R2で分圧した電圧をCP
U10に内蔵のA/D変換器でディジタル値に変換し、
これをE2 −PROM24内に記憶されているバッテリ
チェックデータと比較することにより行われる。ここ
で、各カメラ毎に抵抗R1,R2の値にバラツキがある
ので、カメラの出荷前に各カメラ毎に電源電圧VDDの
A/D変換値を求めて、これから求めた調整値(バッテ
リチェックデータ)をE2 −PROM24に書込んでお
く。この書込みのプログラムは外部装置に格納しておい
て、外部装置との通信によりこのプログラムを実行す
る。
FIG. 20 is a flowchart of the subroutine "battery check" (step 110 in FIG. 4).
As shown in FIG. 21, the battery check uses a voltage obtained by dividing the power supply voltage VDD in the camera by resistors R1 and R2 as CP.
The digital value is converted by the A / D converter built in U10,
This is performed by comparing this with the battery check data stored in the E 2 -PROM 24. Here, since the values of the resistors R1 and R2 vary from camera to camera, an A / D conversion value of the power supply voltage VDD is determined for each camera before shipment of the camera, and the adjustment value (battery check data) ) Is written in the E 2 -PROM 24. This writing program is stored in an external device, and the program is executed by communication with the external device.

【0089】A/D変換のための基準電圧Vref はCP
U10からの指令によりIFIC40から供給される。
ステップ440 でサブルーチン『バッテリ値A/D変換』
を実行する。ステップ442 でA/D変換値が調整値以上
かどうか判定する。調整値以上でない場合は、ステップ
444 でサブルーチン『バッテリなし表示』を実行する。
ステップ446 でKEYロックし、ステップ448 でストッ
プモードとする。この場合もエンドレスループになって
いる。これはノイズ等でストップが解除されても、すぐ
に低消費電流モード(ストップ)に戻すためである。
The reference voltage Vref for A / D conversion is CP
It is supplied from the IFIC 40 according to a command from U10.
Subroutine "battery value A / D conversion" in step 440
Execute In step 442, it is determined whether the A / D conversion value is equal to or larger than the adjustment value. If not, go to step
At 444, the subroutine "display without battery" is executed.
At step 446, the key is locked, and at step 448, the stop mode is set. In this case also, an endless loop is formed. This is to return to the low current consumption mode (stop) immediately even if the stop is released due to noise or the like.

【0090】調整値以上である場合は、ステップ450 で
A/D変換値が[調整値+一定値]以上かどうか判定す
る。[調整値+一定値]以上でない場合は、ステップ45
2 でバッテリ少フラグをセットし、もとのルーチンに戻
る。[調整値+一定値]以上である場合は、ステップ45
4 でバッテリ少フラグをリセットし、もとのルーチンに
戻る。
If it is not less than the adjustment value, it is determined in step 450 whether the A / D conversion value is not less than [adjustment value + constant value]. If not (adjustment value + constant value), step 45
2 sets the low battery flag and returns to the original routine. If it is equal to or more than [adjustment value + fixed value], step 45
4 Resets the low battery flag and returns to the original routine.

【0091】次に、外部装置との通信について説明す
る。図22はこの実施例による通信の各種のモードを説
明する図である。先ず、通信モードは大きく別けて、標
準モードとユーティリティモードに分類できる。これ
は、外部装置から発生されるモード指定コードSYAD
2により分類され、SYAD2=0,1,15の場合は
標準モードであり、SYAD2=2の場合はユーティリ
ティモードである。SYAD2の0,1,15はそれぞ
れCPU10に内蔵されているRAMの使用可能な上位
アドレスに相当する。標準モードはモード指定コードC
KDTが“リード”か“ライト”かによりRAM読出し
モード、RAM書込みモードに細分される。ユーティリ
ティモードはモード指定コードSYADによりサブルー
チンコールモード(SYAD=0)、ジャンプモード
(SYAD=1)、連続通信モード(SYAD=E)、
連続通信解除モード(SYAD=D)に細分される。
Next, communication with an external device will be described. FIG. 22 is a diagram for explaining various modes of communication according to this embodiment. First, the communication mode can be roughly divided into a standard mode and a utility mode. This is the mode designation code SYAD generated from the external device.
2, SYAD2 = 0, 1, 15 is the standard mode, and SYAD2 = 2 is the utility mode. 0, 1, and 15 of SYAD2 correspond to usable upper addresses of the RAM built in the CPU 10, respectively. Standard mode is mode designation code C
The mode is subdivided into a RAM read mode and a RAM write mode depending on whether the KDT is “read” or “write”. In the utility mode, a subroutine call mode (SYAD = 0), a jump mode (SYAD = 1), a continuous communication mode (SYAD = E),
It is subdivided into the continuous communication release mode (SYAD = D).

【0092】カメラと外部装置との間の通信データのフ
ォーマットは一定である。一例として、RAM読出しモ
ードとRAM書込みモードの際のCPU10と外部装置
との間の通信データのフォーマットをそれぞれ図23
(a)、(b)に示す。図中、outとあるのはカメラ
から外部装置へ通信されるデータであり、inとあるの
は外部装置からカメラへ通信されるデータである。
The format of the communication data between the camera and the external device is constant. As an example, the format of communication data between the CPU 10 and the external device in the RAM read mode and the RAM write mode is shown in FIG.
(A) and (b) show. In the figure, “out” is data transmitted from the camera to the external device, and “in” is data transmitted from the external device to the camera.

【0093】カメラのCPU10から発生されるクロッ
クCLKに同期してデータラインDATAを介してデー
タが通信される。ここでは外部装置との通信は、どのル
ーチン中かにより通信1〜通信3に分類されていて、先
ず、これらを識別するための同期信号が、RAM読出し
モードかRAM書込みモードかにかかわらずCPU10
から出力される。通信1,通信2,通信3の同期信号は
それぞれ2,3,4個のパルスからなる。
Data is transmitted via the data line DATA in synchronization with the clock CLK generated from the CPU 10 of the camera. Here, the communication with the external device is classified into communication 1 to communication 3 depending on which routine is in progress. First, the synchronization signal for identifying these is determined by the CPU 10 regardless of the RAM read mode or the RAM write mode.
Output from The synchronization signal for communication 1, communication 2, and communication 3 is composed of 2, 3, and 4 pulses, respectively.

【0094】ここで、通信1は『パワーオンリセット』
ルーチン(図4)中、及び『表示タイマカウント』ルー
チン(図8)中における通信であり、通信2はサブルー
チン『レリーズ処理』(図10、図11)中における通
信であり、通信3はサブルーチン『ダメージ処理』(図
13)中における通信である。
Here, communication 1 is "power-on reset".
The communication is performed during the routine (FIG. 4) and the "display timer count" routine (FIG. 8), the communication 2 is performed during the subroutine "release processing" (FIGS. 10 and 11), and the communication 3 is performed during the subroutine " Damage processing ”(FIG. 13).

【0095】このように、同期信号を通信の時点によっ
て変えることにより、例えばオプションでレリーズ中の
み通信を行ないある特定の制御をするという動作が可能
になり、カメラ機能の拡充が図れる。また、通常のカメ
ラシーケンス中かダメージ処理中かの判断を容易にでき
る。
As described above, by changing the synchronization signal depending on the time of communication, for example, an optional operation of performing communication only during release and performing a specific control can be performed, and the camera function can be expanded. Further, it is possible to easily determine whether the camera sequence is being performed or a damage process is being performed.

【0096】RAM読出しモードの際は、図23(a)
に示すように、同期信号に続いて、モード指定コードC
KDT(4ビット)、SYAD2(4ビット)、SYA
D(8ビット)が外部装置からカメラに通信される。S
YAD2、SYADがRAMの読出しアドレスとなる。
次の入力データ(8ビット)は不定であり、その後、R
AMから読出したデータがカメラから外部装置に通信さ
れる。
In the RAM read mode, FIG.
As shown in the figure, following the synchronization signal, the mode designation code C
KDT (4 bits), SYAD2 (4 bits), SYA
D (8 bits) is communicated from the external device to the camera. S
YAD2 and SYAD are read addresses of the RAM.
The next input data (8 bits) is undefined, and then R
Data read from the AM is communicated from the camera to an external device.

【0097】RAM書込みモードの際は、図23(b)
に示すように、同期信号に続いて、モード指定コードC
KDT、SYAD2、SYAD、書込みデータSYDT
が外部装置からカメラに通信され、SYAD2、SYA
Dで示されるRAMのアドレスにSYDTが書込まれ
る。その後、チェックコードPOFCKが外部装置から
カメラに通信される。これは、チェックコードはCPU
10内のRAMを操作するため、通信が最後まで正常に
行われたかどうかを確認するものである。
In the RAM write mode, FIG.
As shown in the figure, following the synchronization signal, the mode designation code C
KDT, SYAD2, SYAD, write data SYDT
Is communicated from the external device to the camera, and SYAD2, SYA
SYDT is written to the RAM address indicated by D. Thereafter, the check code POFCK is transmitted from the external device to the camera. This is the check code is CPU
In order to operate the RAM in the apparatus 10, it is checked whether or not communication has been normally performed to the end.

【0098】このようなフォーマットによる外部装置と
の通信のフローチャートを図24〜図27に示す。図2
4、図25はサブルーチン『外部装置との通信1』、
『同2』、『同3』をまとめて示すものである。外部装
置との通信1の場合はステップ502 でNに2をセット
し、外部装置との通信2の場合はステップ504 でNに3
をセットし、外部装置との通信3の場合はステップ506
でNに4をセットする。この後、ステップ508 で同期パ
ルスをN回出力する。
FIGS. 24 to 27 show flowcharts of communication with an external device in such a format. FIG.
4. FIG. 25 shows a subroutine "communication 1 with external device",
"Two" and "Third" are shown together. In the case of communication 1 with the external device, 2 is set to N in step 502, and in the case of communication 2 with the external device, 3 is set to N in step 504.
Is set, and in the case of communication 3 with an external device, step 506 is executed.
Sets 4 to N. Thereafter, at step 508, a synchronization pulse is output N times.

【0099】ステップ510 でCPU10をシリアル通信
入力モードとし、ステップ512 でクロックCLKを8個
発生し、外部装置からのビットデータを8個シリアル入
力する。ステップ514 でシリアル入力データをRAMの
CKDT,SYAD2アドレスに書込む。ステップ516
で次のデータをシリアル入力する。ステップ518 でシリ
アル入力データをRAMのSYADアドレスに書込む。
ステップ520 で次のデータをシリアル入力する。ステッ
プ522 でシリアル入力データをRAMのSYDTアドレ
スに書込む。
At step 510, the CPU 10 is set to the serial communication input mode. At step 512, eight clocks CLK are generated, and eight bit data from the external device are serially input. At step 514, the serial input data is written to the CKDT and SYAD2 addresses of the RAM. Step 516
To input the next data serially. At step 518, the serial input data is written to the SYAD address of the RAM.
At step 520, the next data is serially input. At step 522, the serial input data is written to the SYDT address of the RAM.

【0100】ステップ524 でCKDTに基づき読出し
(リード)モードか、書込み(ライト)モードかを判定
する。リードモードの場合は、ステップ526 でSYAD
2,SYADアドレスのデータをシリアルバッファにセ
ットする。ステップ528 でシリアル通信出力モードにセ
ットし、ステップ530 でデータ(図23(a)の読出し
データ)を外部装置にシリアル出力し、その後もとのル
ーチンに戻る。
In step 524, it is determined whether the mode is the read (read) mode or the write (write) mode based on CKDT. In the case of the read mode, SYAD
2. The data of the SYAD address is set in the serial buffer. At step 528, the serial communication output mode is set. At step 530, data (read data of FIG. 23A) is serially output to an external device, and thereafter, the routine returns to the original routine.

【0101】ライトモードの場合は、ステップ532 で次
のデータをシリアル入力し、ステップ534 で入力データ
がチェックコード(POCKF)であるかどうか判定す
る。入力データがチェックコードでない場合は、シリア
ル通信エラーとし、もとのルーチンに戻る。
In the case of the write mode, the next data is serially input in step 532, and it is determined in step 534 whether the input data is a check code (POCKF). If the input data is not a check code, a serial communication error is determined and the process returns to the original routine.

【0102】入力データがチェックコードの場合は、ス
テップ536 でSYAD2が0,1,15のいずれである
かどうか判定する。SYAD2が0,1,15のいずれ
かである場合は標準モードと判定し、ステップ538 でS
YAD2,SYADアドレスにSYDTアドレスのデー
タを書込み、その後もとのルーチンに戻る。
If the input data is a check code, it is determined in step 536 whether SYAD2 is 0, 1, or 15. If SYAD2 is 0, 1, or 15, it is determined that the mode is the standard mode.
The data of the SYDT address is written to the YAD2 and SYAD addresses, and the process returns to the original routine.

【0103】SYAD2が0,1,15のいずれでもな
い場合は、ステップ540 でSYAD2=2かどうか判定
される。SYAD2=2でない場合は、シリアル通信エ
ラーとし、もとのルーチンに戻る。SYAD2=2であ
る場合はユーティリティモードと判定し、ステップ542
でSYAD=0であるかどうか判定する。
If SYAD2 is not 0, 1, or 15, it is determined at step 540 whether SYAD2 = 2. If SYAD2 is not equal to 2, a serial communication error is determined and the process returns to the original routine. If SYAD2 = 2, it is determined that the mode is the utility mode.
It is determined whether or not SYAD = 0.

【0104】SYAD=0の場合はサブルーチンコール
モードと判定し、ステップ544 でRAMバッファのデー
タをレジスタに移す。ステップ546 でサブルーチン『サ
ブルーチンコール』(図28)を実行する。ステップ54
8 でレジスタのデータをRAMバッファに移した後、も
とのルーチンに戻る。ここで、RAMバッファを使用す
るのは、後述する連続通信モードで連続してサブルーチ
ンを実行する場合に、前のサブルーチンの実行直後のレ
ジスタの内容を次のサブルーチン実行時に引きつぐよう
にするためである。すなわち、レジスタの値を引数とし
たサブルーチンを続けて実行できることとなる。
If SYAD = 0, the subroutine call mode is determined, and the data in the RAM buffer is moved to the register in step 544. In step 546, a subroutine "subroutine call" (FIG. 28) is executed. Step 54
After transferring the register data to the RAM buffer in step 8, the process returns to the original routine. Here, the RAM buffer is used so that, when a subroutine is continuously executed in the continuous communication mode described later, the contents of the register immediately after the execution of the previous subroutine are used when the next subroutine is executed. is there. That is, the subroutine using the register value as an argument can be executed continuously.

【0105】SYAD=0でない場合は、ステップ550
でSYAD=1かどうか判定する。SYAD=1の場合
はジャンプモードと判定し、ステップ552 で連続モード
中かどうか判定する。連続モード中の場合は、スタック
が1サブルーチン分(後述する連続モード中の『外部装
置との通信1』(ステップ562 ))増えているので、ス
テップ554 でスタックポインタを1サブルーチン分だけ
戻して、ステップ556に移る。連続モード中でない場合
は、すぐステップ556 に移る。ステップ556 でスタック
にRAMアドレス(BRADR)で示されるデータをセ
ットする。その後、リターン命令があると、スタックに
移されていた(BRADR)の内容をプログラムカウン
タに移すことにより、(BRADR)で示されている番
地にジャンプする。
If SYAD is not 0, step 550
To determine if SYAD = 1. If SYAD = 1, it is determined that the mode is the jump mode. At step 552, it is determined whether the mode is the continuous mode. In the continuous mode, the stack is increased by one subroutine ("communication 1 with external device 1" (step 562) in the continuous mode described later), so the stack pointer is returned by one subroutine in step 554. Move on to step 556. If not in the continuous mode, the process immediately proceeds to step 556. In step 556, data indicated by the RAM address (BRADR) is set in the stack. Thereafter, when there is a return instruction, the contents of (BRADR) transferred to the stack are transferred to the program counter, thereby jumping to the address indicated by (BRADR).

【0106】SYAD=1でない場合は、ステップ558
でSYAD=Eかどうか判定する。SYAD=Eの場合
は連続通信モードと判定し、ステップ560 で連続モード
中かどうか判定する。連続モード中でない場合は、ステ
ップ562 でサブルーチン『外部装置との通信1』を実行
する。ステップ564 でCHECK1端子が“L”かどう
か判定する。CHECK1端子が“L”の場合は、ステ
ップ562 を再度実行する。これにより、カメラと外部装
置とが連続して通信可能となる。すなわち、連続モード
中となる。連続モード中の場合は更に連続モードになる
ことを禁止するため、またはEXT端子3がはずれた
り、外部装置2が通信をやめたりしてCHECK1端子
が“L”ではない場合は、もとのルーチンに戻る。
If SYAD is not 1, step 558
To determine whether SYAD = E. When SYAD = E, it is determined that the communication mode is the continuous communication mode. If not in the continuous mode, a subroutine "communication 1 with external device" is executed in step 562. In step 564, it is determined whether the CHECK1 terminal is "L". If the CHECK1 terminal is "L", step 562 is executed again. This allows the camera and the external device to communicate continuously. That is, it is in the continuous mode. In the continuous mode, if the CHECK terminal 3 is not "L" because the EXT terminal 3 is disconnected or the external device 2 stops communication, the original routine is executed. Return to

【0107】SYAD=Eでない場合は、ステップ566
でSYAD=Dかどうか判定する。SYAD=Dの場合
は連続通信解除モードと判定し、ステップ568 で連続モ
ード中かどうか判定する。連続モード中の場合は、ステ
ップ570 でスタックポインタを1サブルーチン分(連続
モード中の『外部装置との通信1』(ステップ562 ))
だけ戻して、もとのルーチンに戻る。SYAD=Dでな
い場合、または連続モード中でない場合は、すぐにもと
のルーチンに戻る。
If SYAD = E is not satisfied, step 566 is executed.
It is determined whether or not SYAD = D. When SYAD = D, it is determined that the communication mode is the continuous communication release mode. If it is in the continuous mode, the stack pointer is set for one subroutine in step 570 (“communication 1 with external device” in the continuous mode (step 562)).
And return to the original routine. If SYAD = D is not established, or if not in the continuous mode, the routine immediately returns to the original routine.

【0108】図28はサブルーチン『サブルーチンコー
ル』(図26のステップ546 )のフローチャートであ
る。ここでは、ステップ574 に示すようにスタックにR
AMアドレス(BRADR)で示されるデータをセット
し、リターン命令により、直前にスタックにセットされ
た(BRADR)の内容に従ってプログラムカウンタを
(BRADR)で示された番地に変化させることによ
り、(BRADR)で示されたサブルーチンを実行す
る。スタックには、まだ『サブルーチンコール』(ステ
ップ546 )を呼んだ戻り番地が残っているので、(BR
ADR)で示された番地のサブルーチン終了時のリター
ン命令により『サブルーチンコール』(ステップ546 )
の次のステップ548 にプログラムは移る(戻る)。
FIG. 28 is a flowchart of the subroutine "subroutine call" (step 546 in FIG. 26). Here, R is added to the stack as shown in step 574.
By setting data indicated by the AM address (BRADR) and changing the program counter to the address indicated by (BRADR) in accordance with the content of (BRADR) set on the stack immediately before by the return instruction, (BRADRR) Execute the subroutine indicated by. Since the stack still has the return address that called the "subroutine call" (step 546), (BR
A "subroutine call" by a return instruction at the end of the subroutine at the address indicated by (ADR) (step 546)
The program moves to the next step 548 (return).

【0109】次に、以上のようなカメラCPU10のプ
ログラムを利用して種々の機能を実現する外部装置側の
CPU4の動作例を説明する。図29、図30は外部装
置CPU4のサブルーチン『バッテリチェック電圧調
整』のフローチャートである。これは、カメラCPU1
0のサブルーチン『バッテリチェック』で参照する調整
値を出荷前にカメラ毎にE2 −PROM24に書込む機
能である。
Next, an example of the operation of the CPU 4 of the external device which realizes various functions by using the above-described program of the camera CPU 10 will be described. FIGS. 29 and 30 are flowcharts of a subroutine "battery check voltage adjustment" of the external device CPU4. This is the camera CPU1
For each camera before shipping the adjustment value to be referred to in 0 subroutine of "battery check" which is a function of writing to E 2 -PROM24.

【0110】ステップ602 でCHECK1端子を“L”
にし、カメラ側に通信要求を送信する。ステップ604 で
連続通信モードをセットする。すなわち、CKDT=
“ライト”,SYAD2=2,SYAD=Eとする。ス
テップ606 で通信条件を1(N=2)にする。ステップ
608 でカメラにリセットをかけ、カメラCPU10にサ
ブルーチン『パワーオンリセット』を開始させる。ステ
ップ610 でサブルーチン『カメラとの通信』(図32)
を実行する。
In step 602, the CHECK1 terminal is set to "L".
And sends a communication request to the camera. At step 604, the continuous communication mode is set. That is, CKDT =
"Write", SYAD2 = 2, SYAD = E. At step 606, the communication condition is set to 1 (N = 2). Steps
At 608, the camera is reset, and the camera CPU 10 starts a subroutine "power-on reset". Subroutine "communication with camera" at step 610 (FIG. 32)
Execute

【0111】これにより、カメラのCPU10はパワー
オンリセット後の1回目の通信(図4のステップ106 )
で連続通信モードになる。ここで、連続通信モードにし
ないと、カメラ側のプログラムはステップ108 ,110 と
進んで、まだ調整されていない調整値でサブルーチン
『バッテリチェック』を行なうことになる。もし、調整
値が大きい値になっていた場合には、カメラ動作はステ
ップ448 (図20)でロックしてしまう。
Thus, the CPU 10 of the camera performs the first communication after the power-on reset (step 106 in FIG. 4).
To enter the continuous communication mode. Here, if the continuous communication mode is not set, the camera-side program proceeds to steps 108 and 110, and performs a subroutine "battery check" with an adjustment value that has not been adjusted. If the adjustment value is a large value, the camera operation is locked in step 448 (FIG. 20).

【0112】ステップ612 でIFIC40をオンするデ
ータをセットする。ステップ614 で書込みモードをセッ
トする。すなわち、SYAD2=15(IFIC用出力
上位番地),SYAD=“IFIC用出力下位番地”,
SYDT=“IFICオンデータ”,CKDT=“ライ
ト”とする。ステップ616 でサブルーチン『カメラとの
通信』を実行する。
At step 612, data for turning on the IFIC 40 is set. At step 614, the write mode is set. That is, SYAD2 = 15 (output upper address for IFIC), SYAD = “output lower address for IFIC”,
SYDT = “IFIC on data”, CKDT = “write”. In step 616, a subroutine "communication with camera" is executed.

【0113】これにより、IFIC40からは図21に
示したA/D変換のための基準電圧Vrefが出力され
る。ステップ618 でSYAD2,SYADに(BRAD
R)のRAMアドレスを、SYDTにサブルーチン『A
/D変換』の先頭アドレスをセットした後、ステップ62
0 でサブルーチン『カメラとの通信』を実行する。すな
わち、サブルーチン『A/D変換』の先頭アドレスをR
AMアドレス(BRADR)にセットする。ステップ62
2 でサブルーチンコールモードをセットする。すなわ
ち、CKDT=“ライト”,SYAD2=2,SYAD
=0とする。ステップ624 でサブルーチン『カメラとの
通信』を実行する。
Thus, IFIC 40 outputs reference voltage Vref for A / D conversion shown in FIG. In step 618, SYAD2 and SYAD are set to (BRAD
R) RAM address in SYDT
/ D conversion ”, the step 62
0 executes the subroutine "communication with camera". That is, the start address of the subroutine "A / D conversion" is set to R
Set to AM address (BRADR). Step 62
Use 2 to set the subroutine call mode. That is, CKDT = “write”, SYAD2 = 2, SYAD
= 0. In step 624, a subroutine "communication with camera" is executed.

【0114】これにより、サブルーチン『A/D変換』
が実行され、カメラの電源電圧VDDがCPU10でA
/D変換される。ステップ626 で読出しモードをセット
する。すなわち、CKDT=“リード”とする。ステッ
プ628 でSYAD2,SYADにA/D変換値から求め
た調整値(バッテリチェックデータ)をセットする。ス
テップ630 でサブルーチン『カメラとの通信』を実行す
る。
Thus, the subroutine "A / D conversion"
Is executed, and the power supply voltage VDD of the camera is
/ D conversion. In step 626, the read mode is set. That is, CKDT = “read”. In step 628, an adjustment value (battery check data) obtained from the A / D conversion value is set in SYAD2 and SYAD. In step 630, a subroutine "communication with camera" is executed.

【0115】これにより、バッテリチェックデータが一
旦外部装置側に読出される。ステップ632 でSYAD
2,SYADにバッテリチェックデータの書込みRAM
アドレス(EP+3)をセットする。また、ステップ63
0 で読出されたバッテリチェックデータをSYDTにセ
ットする。ステップ636 で書込みモードをセットする。
すなわち、CKDT=“ライト”とする。ステップ638
でサブルーチン『カメラとの通信』を実行する。
As a result, the battery check data is once read out to the external device. SYAD at step 632
2, RAM for writing battery check data to SYAD
Address (EP + 3) is set. Step 63
0 sets the read battery check data in SYDT. At step 636, the write mode is set.
That is, CKDT = “write”. Step 638
To execute the subroutine "communication with camera".

【0116】これにより、E2 −PROM書込み用のR
AMアドレス(EP+3)にバッテリチェックデータが
書込まれる。ステップ640 でSYDTにサブルーチン
『E2 −PROM書込み』の先頭アドレスをセットす
る。また、SYAD2,SYADに(BRADR)のR
AMアドレスをセットする。ステップ644 でサブルーチ
ン『カメラとの通信』を実行する。ステップ646 でサブ
ルーチンコールモードにする。ステップ648 でサブルー
チン『カメラとの通信』を実行する。
Thus, R for writing to the E 2 -PROM is
Battery check data is written to the AM address (EP + 3). To set the starting address of the subroutine "E 2 -PROM writing" to SYDT in step 640. Also, SYAD2 and SYAD have R
Set the AM address. In step 644, a subroutine "communication with camera" is executed. At step 646, the subroutine call mode is set. In step 648, a subroutine "communication with camera" is executed.

【0117】これにより、E2 −PROM24にバッテ
リチェックデータが書込まれる。この後、もとのルーチ
ンに戻る。図31はサブルーチン『AFレンズ駆動調
整』のフローチャートである。上述したカメラCPU1
0のサブルーチン『AF(レンズ繰出し)』ではモータ
がオンしてから1秒経過してもフォーカシングレンズが
動かない場合、異常であると判定していたが、バッテリ
チェックデータと同様に、この判定基準時間を出荷前に
カメラ毎に調整する場合に、サブルーチン『AFレンズ
駆動調整』を実行する。
As a result, the battery check data is written to E 2 -PROM 24. Thereafter, the process returns to the original routine. FIG. 31 is a flowchart of the subroutine "AF lens drive adjustment". Camera CPU 1 described above
In the subroutine “AF (lens extension)” of 0, if the focusing lens does not move even after 1 second from the turning on of the motor, it is determined that the focusing lens is abnormal. When the time is adjusted for each camera before shipment, a subroutine "AF lens drive adjustment" is executed.

【0118】ステップ652 でSYDTにサブルーチン
『AF(レンズ繰出し)』の先頭アドレスをセットす
る。また、SYAD2,SYADに(BRADR)のR
AMアドレスをセットする。ステップ654 でサブルーチ
ン『カメラとの通信』を実行する。ステップ656 でサブ
ルーチンコールモードをセットする。ステップ658 でサ
ブルーチン『カメラとの通信』を実行する。
In step 652, the head address of the subroutine "AF (lens extension)" is set in SYDT. Also, SYAD2 and SYAD have R
Set the AM address. In step 654, a subroutine "communication with camera" is executed. At step 656, a subroutine call mode is set. At step 658, a subroutine "communication with camera" is executed.

【0119】これにより、サブルーチン『AF(レンズ
繰出し)』が実行される。この時、他の測定装置でフォ
ーカシングレンズ駆動の基準とするスイッチ(AFs)
52からレンズ基準位置までにフォトインタラプタ(P
Is)54の出力が何パルス出るかを測定しておく。
Thus, the subroutine "AF (lens extension)" is executed. At this time, a switch (AFs) used as a reference for driving the focusing lens in another measuring device.
From 52 to the lens reference position, a photo interrupter (P
Is) The number of output pulses of 54 is measured.

【0120】ステップ660 で同期信号の数を検出する。
ステップ662 で同期信号の数が4であるかどうか判定す
る。4である場合は、ステップ664 で異常表示を行なっ
て、エンド処理する。すなわち、レンズ駆動異常となっ
たので、調整できない。
At step 660, the number of synchronization signals is detected.
In step 662, it is determined whether the number of synchronization signals is four. If it is 4, an error display is made in step 664, and the end processing is performed. That is, adjustment cannot be performed because a lens drive abnormality has occurred.

【0121】4でない場合は、ステップ666 でSYDT
にAF調整データを、SYAD2,SYADに(EP+
5)のRAMアドレスをセットする。ステップ670 で書
込みモードをセットする。ステップ672 でサブルーチン
『カメラとの通信』を実行する。
If it is not 4, SYDT in step 666
To the SYAD2 and SYAD (EP +
5) Set the RAM address. At step 670, the write mode is set. At step 672, a subroutine "communication with camera" is executed.

【0122】これにより、E2 −PROM書込み用のR
AMアドレス(EP+3)にAF調整データが書込まれ
る。ステップ674 でSYDTにサブルーチン『E2 −P
ROM書込み』の先頭アドレスをセットする。また、S
YAD2,SYADに(BRADR)のRAMアドレス
をセットする。ステップ678 でサブルーチン『カメラと
の通信』を実行する。ステップ680 でサブルーチンコー
ルモードにする。ステップ682 でサブルーチン『カメラ
との通信』を実行する。
Thus, the R for writing to the E 2 -PROM is obtained.
AF adjustment data is written to the AM address (EP + 3). Subroutine to SYDT in step 674 "E 2 -P
ROM write "is set. Also, S
The RAM address of (BRADR) is set in YAD2 and SYAD. At step 678, a subroutine "communication with camera" is executed. At step 680, the subroutine call mode is set. In step 682, a subroutine "communication with camera" is executed.

【0123】これにより、E2 −PROM24にAF調
整データが書込まれる。この後、もとのルーチンに戻
る。図32は図29〜図31に示されるサブルーチン
『カメラとの通信』のフローチャートである。ステップ
673 で同期信号があるかどうか判定する。同期信号があ
る場合は、ステップ675 で同期信号の数が2,3,4の
いずれかであるかどうか判定する。同期信号の数が2,
3,4のいずれでもない場合は、ステップ673に戻る。
同期信号の数が2,3,4のいずれかである場合は、ス
テップ677 でシリアル通信出力モードが設定される。
Thus, the AF adjustment data is written into the E 2 -PROM 24. Thereafter, the process returns to the original routine. FIG. 32 is a flowchart of the subroutine "communication with camera" shown in FIGS. Steps
At 673, it is determined whether there is a synchronization signal. If there is a synchronization signal, it is determined in step 675 whether the number of synchronization signals is 2, 3, or 4. If the number of synchronization signals is 2,
If neither of 3 and 4, the process returns to step 673.
If the number of synchronization signals is one of 2, 3, and 4, the serial communication output mode is set in step 677.

【0124】ステップ679 でCKDT,SYAD2デー
タをシリアルバッファにセットする。ステップ681 でシ
リアルバッファのデータをカメラCPU10からのクロ
ックCLKに同期して、シリアル出力する。ステップ68
3 でSYADデータをシリアルバッファにセットする。
ステップ684 でシリアルバッファのデータをシリアル出
力する。ステップ686 でSYDTデータをシリアルバッ
ファにセットする。読出しモードの場合は、SYDTは
ダミーデータでよい。ステップ688 でシリアルバッファ
のデータをシリアル出力する。
At step 679, CKDT and SYAD2 data are set in the serial buffer. At step 681, the data in the serial buffer is serially output in synchronization with the clock CLK from the camera CPU 10. Step 68
3. Set the SYAD data in the serial buffer.
At step 684, the data in the serial buffer is serially output. At step 686, SYDT data is set in the serial buffer. In the case of the read mode, SYDT may be dummy data. At step 688, the data in the serial buffer is serially output.

【0125】ステップ690 で読出しモード(CKDT=
“リード”)かどうか判定する。読出しモードでない場
合は、ステップ692 でPOFCKデータをシリアルバッ
ファにセットする。ステップ694 でシリアルバッファの
データをシリアル出力する。その後、もとのルーチンに
戻る。
At step 690, the read mode (CKDT =
"Read") is determined. If not in the read mode, in step 692, the POFCK data is set in the serial buffer. At step 694, the data in the serial buffer is serially output. Then, the process returns to the original routine.

【0126】読出しモードである場合は、ステップ696
でシリアル通信入力モードをセットする。ステップ698
でカメラからのデータ(図23(a)の読出しデータ)
シリアル入力する。その後、もとのルーチンに戻る。
If it is the read mode, step 696
To set the serial communication input mode. Step 698
And data from the camera (readout data in FIG. 23 (a))
Serial input. Then, the process returns to the original routine.

【0127】これ以外の調整データ(シャッタ調整デー
タ等)についても、同様に外部装置のCPUをプログラ
ムしておくことにより、カメラ出荷前に各カメラ毎に調
整可能である。これにより、部品等によるカメラのバラ
ツキに無関係に種々の判定を正確に実行できる。
Other adjustment data (shutter adjustment data, etc.) can be adjusted for each camera before shipment by similarly programming the CPU of the external device. As a result, various determinations can be accurately performed irrespective of camera variations due to components and the like.

【0128】次に、撮影モードを拡張するオプション機
器としての外部装置の動作を説明する。一例として、図
33〜図35を参照して、サブルーチン『多重4枚撮
り』を説明する。このプログラムは外部装置により多重
一枚撮影フラグを操作して、カメラCPUのサブルーチ
ン『レリーズ処理』で多重撮影ルーチン(図11のステ
ップ286 〜290 )を何度も実行させるものである。すな
わち、通常は、最初の露光が行われると多重一枚撮影フ
ラグがセットされ、次の露光終了後多重一枚撮影フラグ
がセットされていると、フィルム巻上げが実行される。
そのため、露光終了後にセットされた多重一枚撮影フラ
グを外部装置がクリアすることにより、任意の枚数の多
重撮影が可能となる。
Next, the operation of the external device as an optional device for extending the shooting mode will be described. As an example, the subroutine "Multi-four-shot shooting" will be described with reference to FIGS. This program is to operate the multiple image capturing flag by an external device and to execute the multiple image capturing routine (steps 286 to 290 in FIG. 11) many times in the subroutine "release process" of the camera CPU. That is, normally, when the first exposure is performed, the multiple single shooting flag is set, and when the multiple single shooting flag is set after the end of the next exposure, film winding is performed.
Therefore, the external device clears the multiplex single image capturing flag set after the end of the exposure, so that an arbitrary number of multiplex images can be captured.

【0129】ステップ702 で枚数(多重枚数)カウンタ
をリセットする。ステップ704 でCHECK1端子を
“L”にし、カメラ側に通信要求を出力する。ステップ
706 で通信条件を2(N←3)とし、レリーズ待機状態
とする。
In step 702, the number (multiplex number) counter is reset. In step 704, the CHECK1 terminal is set to "L", and a communication request is output to the camera. Steps
At 706, the communication condition is set to 2 (N ← 3), and the release standby state is set.

【0130】ステップ708 で連続通信モードをセットす
る。ステップ710 でサブルーチン『カメラとの通信』を
実行する。これにより、ユーザがレリーズスイッチを押
した時に実行されるサブルーチン『レリーズ処理』(図
10、図11)においてカメラとの連続通信が開始され
る。この時、カメラは多重露光モードに設定されている
とする。
At step 708, the continuous communication mode is set. At step 710, a subroutine "communication with camera" is executed. Thus, continuous communication with the camera is started in a subroutine "release process" (FIGS. 10 and 11) executed when the user presses the release switch. At this time, it is assumed that the camera is set to the multiple exposure mode.

【0131】ここで、連続通信モードになっているの
で、カメラ内のプログラムは進まず、サブルーチン『レ
リーズ処理』の最初でカメラの状態を自由に変更するこ
とができる。
Here, since the camera is in the continuous communication mode, the program in the camera does not proceed, and the state of the camera can be freely changed at the beginning of the subroutine "release processing".

【0132】ステップ712 で通信条件を1(N←2)に
戻す。ただし、カメラとの連続通信は続行している。ス
テップ714 でRAM読出しモードをセットする。ステッ
プ716 でSYAD2,SYADにRAM読出しアドレス
EP+1をセットする。ステップ718 でサブルーチン
『カメラとの通信』を実行し、RAMからカメラ状態デ
ータを読出す。
At step 712, the communication condition is returned to 1 (N ← 2). However, continuous communication with the camera is continuing. At step 714, the RAM read mode is set. At step 716, the RAM read address EP + 1 is set in SYAD2 and SYAD. In step 718, a subroutine "communication with camera" is executed, and camera state data is read from the RAM.

【0133】ステップ720 で多重一枚撮影フラグ(カメ
ラ状態データの6ビット)をクリアする。ステップ722
でRAM書込みモードをセットする。ステップ723 でS
YAD2,SYADにRAMアドレスEP+1を、SY
DTには多重一枚撮影フラグをリセットしたカメラ状態
データをセットする。ステップ724 でサブルーチン『カ
メラとの通信』を実行する。多重一枚撮影フラグがリセ
ットされたカメラ状態データをRAMに書込む。これに
より、多重4枚露光が可能になる。ステップ726 で連続
通信解除モードをセットする。ステップ728 でサブルー
チン『カメラとの通信』を実行し、カメラのプログラム
をサブルーチン『レリーズ処理』に戻す。この後、カメ
ラとの通信が中断する。ここで、カメラ側では、2段目
レリーズが押されている場合は、多重の一枚目として露
出動作を行ない、レリーズがすでに離された場合は、露
出せずにもとのルーチンにもどる。露出した場合は、多
重一枚撮影フラグがセットされるので確認できる。
At step 720, the multiple single shooting flag (6 bits of the camera status data) is cleared. Step 722
To set the RAM write mode. S in step 723
RAM address EP + 1 is added to YAD2 and SYAD,
In DT, the camera state data in which the multiple single shooting flag is reset is set. In step 724, a subroutine "communication with camera" is executed. The camera state data in which the multiple single shooting flag is reset is written to the RAM. This enables multiple four exposures. At step 726, the continuous communication release mode is set. In step 728, the subroutine "communication with camera" is executed, and the camera program is returned to the subroutine "release processing". Thereafter, communication with the camera is interrupted. Here, on the camera side, when the second-stage release is pressed, the exposure operation is performed as the first multiplex, and when the release is already released, the routine returns to the original routine without exposure. In the case of exposure, the multiplex single image shooting flag is set so that it can be confirmed.

【0134】ステップ730 でサブルーチン『RAMアド
レスEP+1読取り』を実行する。ステップ732 で多重
一枚撮影フラグが“1”(セット)かどうか判定する。
多重一枚撮影フラグが“1”でない場合は、レリーズが
中断された(露出していない)ので、ステップ706 に戻
る。多重一枚撮影フラグが“1”である場合は、露出さ
れたので、ステップ734 で枚数カウンタをインクリメン
トする。
At step 730, the subroutine "read RAM address EP + 1" is executed. At step 732, it is determined whether or not the multiple single shooting flag is "1" (set).
If the multiple single shooting flag is not "1", the release has been interrupted (not exposed), and the flow returns to step 706. If the multiple single shooting flag is "1", the exposure has been performed, and the number counter is incremented in step 734.

【0135】ステップ736 で枚数カウンタが3かどうか
判定する。枚数カウンタが3である場合は、ステップ70
6 に戻る。すなわち、次の『レリーズ処理』で巻上げで
きるようにして戻る。枚数カウンタが3でない場合は、
ステップ738 で連続通信モードをセットする。ステップ
740 でサブルーチン『カメラとの通信』を実行する。こ
こで、連続通信モードにするのは、E2 −PROMの内
容を変更したいためで、連続通信モードにしないと、カ
メラ側のルーチンでE2 −PROMの内容をいつもリフ
レッシュ(図5、ステップ152 )しているため、E2
PROMの内容は変更できない。
In step 736, it is determined whether or not the number counter is 3. If the number counter is 3, step 70
Return to 6. That is, the process returns to the next "release process" so that the film can be wound. If the number counter is not 3,
At step 738, the continuous communication mode is set. Steps
At 740, the subroutine "communication with camera" is executed. Here, for the continuous communication mode, E 2 in order to want to change the contents of -PROM, unless the continuous communication mode, always refresh the contents of the E 2 -PROM in the camera routine (FIG. 5, step 152 ), E 2
The contents of the PROM cannot be changed.

【0136】ステップ742 で多重一枚撮影フラグをリセ
ットする。ステップ746 でRAM書込みモードをセット
する。ここで、SYAD2,SYADにRAM書込みア
ドレスEP+1をセットする。SYDTは多重一枚撮影
フラグをリセットしたカメラ状態データである。ステッ
プ748 でサブルーチン『カメラとの通信』を実行する。
In step 742, the multiplex single-image shooting flag is reset. At step 746, the RAM write mode is set. Here, the RAM write address EP + 1 is set in SYAD2 and SYAD. SYDT is camera state data in which the multiple single shooting flag is reset. In step 748, a subroutine "communication with camera" is executed.

【0137】ステップ750 でSYDTにサブルーチン
『E2 −PROM書込み』の先頭アドレスをセットし、
SYAD2,SYADにBRARAのRAMアドレスを
セットする。ステップ752 でサブルーチン『カメラとの
通信』を実行する。ステップ754 でサブルーチンコール
モードをセットする。ステップ756 でサブルーチン『カ
メラとの通信』を実行する。
[0137] to set the starting address of the subroutine "E 2 -PROM writing" to SYDT in step 750,
The BRARA RAM address is set in SYAD2 and SYAD. In step 752, a subroutine "communication with camera" is executed. At step 754, the subroutine call mode is set. In step 756, a subroutine "communication with camera" is executed.

【0138】ステップ758 で連続通信解除モードをセッ
トする。ステップ760 でサブルーチン『カメラとの通
信』を実行する。ステップ762 で枚数カウンタが4かど
うか判定する。枚数カウンタが4でない場合は、ステッ
プ706 に戻る。枚数カウンタが4である場合は、ステッ
プ764 でCHECK1端子を“H”とし、もとのルーチ
ンに戻る。
At step 758, the continuous communication release mode is set. In step 760, a subroutine "communication with camera" is executed. At step 762, it is determined whether or not the number counter is four. If the number counter is not 4, the process returns to step 706. If the number counter is 4, the CHECK1 terminal is set to "H" in step 764, and the routine returns to the original routine.

【0139】これにより、カメラCPUには多重2枚撮
影プログラムしか内蔵されていない場合でも、外部装置
によりカメラCPUのRAMの内容を制御することによ
り3枚以上の多重撮影が実行できる。
Thus, even when the camera CPU contains only a multiplexed two-image shooting program, three or more multiplexed images can be executed by controlling the contents of the RAM of the camera CPU by an external device.

【0140】なお、この発明は上述した実施例に限定さ
れず、発明の要旨を逸脱しない範囲で種々変形可能であ
る。例えば、外部装置、主に撮影オプション用の外部装
置はアダプタ機器としてではなく、ICカードとして構
成してもよく、むしろ、この方が、小形軽量であるの
で、好ましい。また、CPUは1チップのマイクロコン
ピュータに限定されない。
The present invention is not limited to the above-described embodiment, but can be variously modified without departing from the gist of the invention. For example, the external device, mainly an external device for a photographing option, may be configured not as an adapter device but as an IC card, and rather, this is preferable because it is small and lightweight. Further, the CPU is not limited to a one-chip microcomputer.

【0141】[0141]

【発明の効果】以上説明したようにこの発明によれば、
電源が遮断されてもレンズ駆動の異常状態を記憶してお
くことができ、異常処理中に電源が遮断された場合は、
電源再投入時に異常処理を続行することができるオート
フォーカスカメラを提供することができる。
As described above, according to the present invention,
Even if the power is cut off, the abnormal state of the lens drive can be stored, and if the power is cut off during the error processing,
It is possible to provide an autofocus camera that can continue the abnormality processing when the power is turned on again.

【図面の簡単な説明】[Brief description of the drawings]

【図1】この発明によるカメラの一実施例の概略を示す
ブロック図。
FIG. 1 is a block diagram schematically showing an embodiment of a camera according to the present invention.

【図2】カメラと外部装置との接続を示す図。FIG. 2 is a diagram showing connection between a camera and an external device.

【図3】カメラの詳細なブロック図。FIG. 3 is a detailed block diagram of a camera.

【図4】『パワーオンリセット』ルーチンのフローチャ
ート。
FIG. 4 is a flowchart of a “power-on reset” routine.

【図5】『スタンバイ解除』ルーチンのフローチャート
(その1)。
FIG. 5 is a flowchart (part 1) of a “standby release” routine.

【図6】『スタンバイ解除』ルーチンのフローチャート
(その2)。
FIG. 6 is a flowchart (part 2) of a “standby release” routine.

【図7】『スタンバイ解除』ルーチンのフローチャート
(その3)。
FIG. 7 is a flowchart (part 3) of a “standby release” routine;

【図8】サブルーチン『表示タイマカウント』のフロー
チャート。
FIG. 8 is a flowchart of a subroutine “display timer count”.

【図9】サブルーチン『カメラモード』のフローチャー
ト。
FIG. 9 is a flowchart of a subroutine “camera mode”.

【図10】サブルーチン『レリーズ処理』のフローチャ
ート(その1)。
FIG. 10 is a flowchart (part 1) of a subroutine “release processing”.

【図11】サブルーチン『レリーズ処理』のフローチャ
ート(その2)。
FIG. 11 is a flowchart (part 2) of a subroutine “release process”;

【図12】サブルーチン『AF(レンズ繰出し)』のフ
ローチャート。
FIG. 12 is a flowchart of a subroutine “AF (lens extension)”.

【図13】サブルーチン『ダメージ処理』のフローチャ
ート。
FIG. 13 is a flowchart of a subroutine “damage processing”.

【図14】サブルーチン『一駒巻上げ』のフローチャー
ト。
FIG. 14 is a flowchart of a subroutine “winding one frame”.

【図15】サブルーチン『E2 ーPRM読出し』のフロ
ーチャート。
FIG. 15 is a flowchart of a subroutine "E2-PRM reading".

【図16】各RAMアドレスに格納される内容を示す
図。
FIG. 16 is a view showing contents stored in each RAM address.

【図17】カメラ状態データの各ビットの内容を示す
図。
FIG. 17 is a diagram showing the contents of each bit of camera status data.

【図18】異常データの各ビットの内容を示す図。FIG. 18 is a diagram showing the contents of each bit of abnormal data.

【図19】サブルーチン『E2 ーPRM書込み』のフロ
ーチャート。
FIG. 19 is a flowchart of a subroutine “E2-PRM writing”.

【図20】サブルーチン『バッテリチェック』のフロー
チャート。
FIG. 20 is a flowchart of a subroutine “battery check”.

【図21】バッテリチェックのための回路接続を示すブ
ロック図。
FIG. 21 is a block diagram showing circuit connections for battery check.

【図22】カメラの通信モードの種類を示す図。FIG. 22 is a diagram showing types of communication modes of the camera.

【図23】RAM読出しモード、RAM書込みモードの
際のカメラと外部装置との通信フォーマットを示す図。
FIG. 23 is a view showing a communication format between a camera and an external device in a RAM read mode and a RAM write mode.

【図24】サブルーチン『外部装置との通信1,2,
3』のフローチャート(その1)。
FIG. 24 shows a subroutine “communications 1, 2, 2,
3 "(Part 1).

【図25】サブルーチン『外部装置との通信1,2,
3』のフローチャート(その2)。
FIG. 25 shows a subroutine “Communications 1, 2, 2 with external devices”.
3 "(part 2).

【図26】サブルーチン『外部装置との通信1,2,
3』のフローチャート(その3)。
FIG. 26 illustrates a subroutine “Communications 1, 2, 2, 3
3 "(part 3).

【図27】サブルーチン『外部装置との通信1,2,
3』のフローチャート(その4)。
FIG. 27 shows a subroutine “Communications 1, 2, 2, 3
3 "(part 4).

【図28】サブルーチン『サブルーチンコール』のフロ
ーチャート。
FIG. 28 is a flowchart of a subroutine “subroutine call”.

【図29】サブルーチン『バッテリチェック電圧調整』
のフローチャート(その1)。
FIG. 29 shows a subroutine “battery check voltage adjustment”.
Flowchart (No. 1).

【図30】サブルーチン『バッテリチェック電圧調整』
のフローチャート(その2)。
FIG. 30 shows a subroutine “battery check voltage adjustment”.
Flowchart (No. 2).

【図31】サブルーチン『AFレンズ駆動調整』のフロ
ーチャート。
FIG. 31 is a flowchart of a subroutine “AF lens drive adjustment”.

【図32】サブルーチン『カメラとの通信』のフローチ
ャート。
FIG. 32 is a flowchart of a subroutine “communication with camera”.

【図33】サブルーチン『多重4枚撮り』のフローチャ
ート(その1)。
FIG. 33 is a flowchart (No. 1) of a subroutine “Multi-four-shot shooting”.

【図34】サブルーチン『多重4枚撮り』のフローチャ
ート(その2)。
FIG. 34 is a flowchart (part 2) of a subroutine “Multi-four shots”.

【図35】サブルーチン『多重4枚撮り』のフローチャ
ート(その3)。
FIG. 35 is a flowchart (part 3) of a subroutine “Multi-four shots”;

【符号の説明】[Explanation of symbols]

1…カメラ、2…外部装置、3…外部端子、4,10…
CPU、22…リセット回路、24…E2 ーPRM、2
8…シリアルライン、30…AFセンサ、34…操作ス
イッチ、40…インターフェース、42…測光ユニッ
ト、44…シャッタモータ、46…巻上げモータ、48
…ズームモータ、54,58…フォトインタラプタ。
DESCRIPTION OF SYMBOLS 1 ... Camera, 2 ... External device, 3 ... External terminal, 4, 10 ...
CPU, 22 reset circuit, 24 E2 -PRM, 2
8 Serial line, 30 AF sensor, 34 Operation switch, 40 Interface, 42 Photometry unit, 44 Shutter motor, 46 Winding motor, 48
... zoom motors, 54, 58 ... photo interrupters.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 撮影レンズの焦点調節量を検出する手段
と、 上記焦点調節量に基づいて上記撮影レンズを駆動する手
段と、 上記撮影レンズの駆動に伴ってパルスを発生させるパル
ス発生手段と、 上記パルスが所定の時間発生しなかったときは異常と判
断する異常判断手段と、カメラの電源が遮断された場合でも記憶状態を保持する
電気的に書換え可能な不揮発性記憶素子で構成され、
記異常判断に基づいて異常状態を記憶する記憶手段と、 上記異常判断手段によって異常状態と判断された際に、
上記駆動手段による駆動を停止するとともに外部装置と
の通信を実行可能とする異常処理手段とを具備するオー
トフォーカスカメラ。
1. A means for detecting a focus adjustment amount of a photographic lens; a means for driving the photographic lens based on the focus adjustment amount; a pulse generation means for generating a pulse in accordance with the driving of the photographic lens; Abnormality determining means for determining that an abnormality has occurred when the pulse has not been generated for a predetermined period of time, and retaining a stored state even when the power of the camera is cut off
A storage unit configured by an electrically rewritable nonvolatile storage element and storing an abnormal state based on the abnormality determination; and when the abnormality determination unit determines that the state is abnormal,
Stop driving by the above-mentioned driving means and
An auto-focus camera, comprising: an abnormality processing unit that can execute communication of the camera.
JP16066995A 1988-03-29 1995-06-27 Auto focus camera Expired - Lifetime JP2749286B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16066995A JP2749286B2 (en) 1988-03-29 1995-06-27 Auto focus camera

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
JP7310488 1988-03-29
JP63-73104 1988-03-29
JP16066995A JP2749286B2 (en) 1988-03-29 1995-06-27 Auto focus camera

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP63201333A Division JP2608589B2 (en) 1988-03-29 1988-08-12 camera

Publications (2)

Publication Number Publication Date
JPH07318789A JPH07318789A (en) 1995-12-08
JP2749286B2 true JP2749286B2 (en) 1998-05-13

Family

ID=26414239

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16066995A Expired - Lifetime JP2749286B2 (en) 1988-03-29 1995-06-27 Auto focus camera

Country Status (1)

Country Link
JP (1) JP2749286B2 (en)

Also Published As

Publication number Publication date
JPH07318789A (en) 1995-12-08

Similar Documents

Publication Publication Date Title
JPS63138886A (en) Still camera system
JP2007184761A (en) Imaging apparatus, control method therefor, and computer program
JP2608589B2 (en) camera
US6519419B2 (en) Method of controlling power source of camera
JPH0734405Y2 (en) Camera lens storage device
JP2794631B2 (en) Camera with power zoom function and interchangeable camera and interchangeable lens with power zoom function
JP2749286B2 (en) Auto focus camera
JP2982960B2 (en) Camera with self-check function
JPH01180532A (en) Camera
JPH10319490A (en) Camera with liquid crystal finder
JP2997803B2 (en) Camera with self-check function
JP2608589C (en)
JP3093607B2 (en) Cameras and devices for cameras
JP2829920B2 (en) Cameras and interchangeable lenses with interchangeable lenses
JPS61130932A (en) Camera
JPH0445432A (en) Focusing device for camera
JPH0723775Y2 (en) Film data reader
JPH05113599A (en) Camera both for silver-salt photograph and electronic still photograph
JP2636296B2 (en) Strobe device
JPH012031A (en) fully automatic camera
JP2635008B2 (en) Camera with strobe device
JPS62178226A (en) Waterproof camera
JPH02247627A (en) Alarming device for camera
JP2911953B2 (en) Auto exposure camera
JP2954861B2 (en) Automatic focusing device

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 19980113

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090220

Year of fee payment: 11

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090220

Year of fee payment: 11