JPH0581006B2 - - Google Patents

Info

Publication number
JPH0581006B2
JPH0581006B2 JP62004572A JP457287A JPH0581006B2 JP H0581006 B2 JPH0581006 B2 JP H0581006B2 JP 62004572 A JP62004572 A JP 62004572A JP 457287 A JP457287 A JP 457287A JP H0581006 B2 JPH0581006 B2 JP H0581006B2
Authority
JP
Japan
Prior art keywords
lens
focus
dep
amount
depth
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 - Fee Related
Application number
JP62004572A
Other languages
Japanese (ja)
Other versions
JPS63172228A (en
Inventor
Akira Akashi
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP62004572A priority Critical patent/JPS63172228A/en
Priority to US07/141,713 priority patent/US4792819A/en
Publication of JPS63172228A publication Critical patent/JPS63172228A/en
Publication of JPH0581006B2 publication Critical patent/JPH0581006B2/ja
Granted legal-status Critical Current

Links

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は異なる位置に位置する2つの被写体と
もにピントが合つた状態で撮影を行わせる自動焦
点調節装置を有するカメラに関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a camera having an automatic focus adjustment device for photographing two objects located at different positions in a state where both objects are in focus.

〔従来技術〕[Prior art]

異なる位置に被写体A,Bが位置する場合、被
写体Aに対して合焦とするレンズ位置と、被写体
Bに対して合焦するレンズ位置を所定の比で内分
する中間位置を求め、この中間位置にレンズを移
動させると共に被写体A,Bに対してそれぞれ合
焦とするレンズ位置間のデフオーカス量を最小錯
乱円で割ることにて絞りを求め、この絞りにて上
記被写体A,Bを共にその深度内となし、異なる
位置の被写体A,B共にピントが合つた状態を保
証させた自動焦点調節装置を有するカメラを本願
出願人が特願昭61−236841号として提案してい
る。
When subjects A and B are located at different positions, find an intermediate position that internally divides the lens position that focuses on subject A and the lens position that focuses on subject B by a predetermined ratio, and then The aperture is determined by moving the lens to the desired position and dividing the amount of defocus between the lens positions to focus on subjects A and B by the circle of least confusion. The applicant of the present invention has proposed a camera having an automatic focus adjustment device that ensures that objects A and B at different positions are in focus within the depth of field in Japanese Patent Application No. 61-236841.

該形式のレンズ位置調節方式では上記の如く被
写体A,Bに対するそれぞれのレンズ位置間のデ
フオーカス量に基づいて該デフオーカス量を所定
の比で内分するレンズ位置を求めている関係上被
写体Aに対して合焦状態とするレンズ位置及び被
写体Bに対して合焦状態とするレンズ位置が存在
しない場合にはレンズを上記内分位置へ移行させ
ることが出来なくなり、両被写体をともにピント
が合つた状態とする撮影目的を達成し得ない。
In this type of lens position adjustment method, as mentioned above, based on the amount of defocus between the respective lens positions for subjects A and B, the lens position that divides the amount of defocus internally by a predetermined ratio is determined. If there is no lens position to bring the subject B into focus and a lens position to bring subject B into focus, the lens cannot be moved to the internal position, and both subjects are in focus. The purpose of shooting cannot be achieved.

例えば被写体Aに対して合焦となるレンズ位置
にて被写体Bに対して焦点検知して得られたデフ
オーカス量だけレンズを駆動した際に上記デフオ
ーカス量分の駆動が終了する以前に無限側の限界
位置にレンズが突き当つた様な場合においては被
写体Aに対して合焦とするレンズの位置と被写体
Bを合焦とすべくレンズを移動した位置(無限位
置)との間のデフオーカス量と焦点検知した結果
のデフオーカス量とが異なることとなる。従つ
て、か様な場合レンズを本来の移行位置(焦点検
知結果のデフオーカス量を所定の比で内分する位
置)へ移行させることが出来ず、上記所望の撮影
目的を達成し得ない。
For example, when the lens is driven by the amount of def focus obtained by detecting focus on object B at the lens position where object A is in focus, the limit on the infinity side is reached before the driving for the amount of def focus is completed. In the case where the lens hits a certain position, the amount of defocus and focus between the position of the lens to focus on subject A and the position (infinity position) where the lens is moved to focus on subject B. The detected amount of defocus will be different. Therefore, in such a case, the lens cannot be moved to the original transition position (a position where the defocus amount as a result of focus detection is internally divided by a predetermined ratio), and the above-mentioned desired photographic purpose cannot be achieved.

上記の問題を解消する方法として被写体Aに対
して合焦とするレンズ状態で被写体Bに対するデ
フオーカス量の検知を行つた際にレンズが無限端
や、至近端に突き当る様なデフオーカス量が求め
られた状態では上記中間位置算出や絞り値の算出
動作を禁止して、制御不能状態となつたことを指
示させることが考えられる。
To solve the above problem, when detecting the amount of defocus for object B with the lens in focus on object A, find the amount of defocus so that the lens hits the infinity end or the closest end. In such a state, it is conceivable to prohibit the calculation of the intermediate position and the aperture value, and to indicate that the control has become uncontrollable.

しかしながら、上記デフオーカス量がレンズの
停止位置から移動しレンズが無限端に突き当つた
状態となつても合焦とすることが出来ない様な被
写体にあつては、そのレンズを使用する限り合焦
状態となることが不可能であり、この様な被写体
を対象とする限り制御不能指示を行つたとしても
撮影者は撮影状況を改善することが出来ない。一
方、上記の様な被写体に対してはレンズを無限端
に移行させた状態が最良の合焦状態であり、か様
な場合には、無限端位置を被写体の合焦位置と見
做して処理を行つてもほぼ両被写体ともにピント
が合つた状態とするレンズ位置及び絞り制御をす
ることが出来る。又、逆にレンズが至近端に突き
当るようなデフオーカス量が検知された場合には
撮影者が移動する等の動作をすれば撮影状況を改
善することが出来、この様な場合には制御不能指
示を行つて撮影者が移動する等の動作を行わせ、
再度被写体Bに対するデフオーカス量の検知動作
を撮影者に行わせることを指示した方が望まし
い。
However, in the case of a subject that cannot be brought into focus even if the above-mentioned defocus amount moves from the lens stop position and the lens reaches the infinity end, as long as the lens is used, it will not be possible to bring it into focus. Therefore, as long as such a subject is to be photographed, the photographer cannot improve the photographing situation even if an uncontrollable instruction is issued. On the other hand, for the above-mentioned subjects, the best focus is when the lens is moved to the infinity end, and in such cases, the infinity end position is considered to be the in-focus position of the subject. Even after processing, the lens position and aperture can be controlled so that almost both objects are in focus. Conversely, if the amount of defocus that causes the lens to hit the close end is detected, the photographer can take actions such as moving to improve the shooting situation. Instruct the photographer to move or perform other actions,
It is preferable to instruct the photographer to perform the operation of detecting the amount of defocus for subject B again.

〔目的〕〔the purpose〕

本発明は上記の事項に鑑みなされたものでその
構成として、 第1の被写体に対して焦点検出回路にて焦点検
出を行なわせ、該焦点検出結果に応じてレンズを
レンズ駆動回路により前記第1の被写体に対して
合焦とする第1の位置まで移行させ、レンズが該
第1の位置に位置している状態で第2の被写体に
対して前記焦点検出回路にて焦点検出を行なわ
せ、該焦点検出結果に応じてレンズを前記レンズ
駆動回路により前記第2の被写体に対して合焦と
する第2の位置まで移行させるとともに、前記第
1の位置と第2の位置との間のレンズ移動量に相
応して第1の被写体と第2の被写体に対する焦点
状態がほぼ等しくなる中間位置を演算手段にて演
算し、レンズを前記中間位置へレンズ駆動回路に
より移行させるレンズ位置制御装置を備えるとと
もに、前記第1の位置から第2の位置へのレンズ
移行に際してレンズが前記第2の位置へ到達する
以前にレンズの至近端に到達したか否かを検知す
る検知手段と、該検知手段にて至近端への到達が
検知された際に第1と第2の被写体に対する焦点
状態をほぼ等しくすることが不可であると判定す
る判定手段を設け、 上記の処理によつても異なる位置にある2つの
被写体に対してともにピントを合わせることが出
来ない状況であることを知らせしめることを可能
にしたものである。
The present invention has been made in view of the above-mentioned matters, and has a configuration in which a focus detection circuit performs focus detection on a first object, and a lens is driven by a lens drive circuit according to the focus detection result. to a first position where the lens is in focus, and with the lens in the first position, the focus detection circuit performs focus detection on the second subject; In accordance with the focus detection result, the lens driving circuit moves the lens to a second position where the second subject is brought into focus, and the lens is moved between the first position and the second position. A lens position control device is provided, which uses a calculation means to calculate an intermediate position at which the focus states of the first object and the second object are approximately equal in accordance with the amount of movement, and causes a lens drive circuit to move the lens to the intermediate position. and a detection means for detecting whether or not the lens has reached the closest end of the lens before reaching the second position when the lens moves from the first position to the second position; and the detection means A determination means is provided for determining that it is impossible to make the focus states of the first and second objects almost equal when the arrival at the closest end is detected, This makes it possible to notify the user that it is impossible to focus on two subjects at the same time.

〔実施例〕〔Example〕

第1図は本発明に係るオートフオーカス装置を
備えたカメラの実施例を示す回路図である。図に
おいてPRSはカメラの制御装置で、例えば、内
部にROM,RAM,A/D変換機能を持つ1チ
ツプのマイクロ・コンピユーターであり、ROM
に格納された後述のプログラムに従つて、自動露
出制御機能、自動焦点検出機能、フイルムの巻き
上げ・巻戻し等のカメラの動作を行つている。
FIG. 1 is a circuit diagram showing an embodiment of a camera equipped with an autofocus device according to the present invention. In the figure, PRS is a camera control device, for example, a one-chip microcomputer with internal ROM, RAM, and A/D conversion functions.
Camera operations such as automatic exposure control function, automatic focus detection function, and film winding/rewinding are performed according to programs stored in the camera, which will be described later.

マイクロ・コンピユーターPRSは通信用信号
SO,SI,SCLKを用いて、周辺回路およびレン
ズと通信し、各々の回路やレンズの動作を制御す
る。
Microcomputer PRS is a communication signal
SO, SI, and SCLK are used to communicate with peripheral circuits and lenses, and to control the operation of each circuit and lens.

SOはPRSから出力されるデータ信号、SIは
PRSに入力されるデータ信号、SCLKは信号SO,
SIの同期信号である。
SO is the data signal output from PRS, SI is
The data signal input to PRS, SCLK is the signal SO,
This is the SI synchronization signal.

LCMはレンズ通信バツフア回路であり、カメ
ラが動作中のときはレンズ用電源VLをレンズに
与え、マイクロ・コンピユーターPRSからの信
号CLCMが高電位のレベル(以下、“H”と略
し、低電位は‘L'と略して記す)のときは、カメ
ラとレンズ間通信のバツフアとなる。
LCM is a lens communication buffer circuit. When the camera is in operation, the lens power supply VL is applied to the lens, and the signal CLCM from the microcomputer PRS is at a high potential level (hereinafter abbreviated as "H"; low potential is (abbreviated as 'L'), there is a communication buffer between the camera and the lens.

マイクロ・コンピユーターPRSが信号CLCM
を‘H'にして、SCLK信号に同期して所定のデー
タをSO信号として送出すると、回路LCMが指定
されたカメラ・レンズ間接点を介して、SCLK信
号、SO信号の各々のバツフア信号LCK,DCLを
レンズへ出力する。それと同時にレンズ(一点鎖
線で囲まれた部分)からの信号DLCのバツフア
信号をSI信号として出力し、コンピユーター
PRSはSCLK信号に同期してSI信号としてのレン
ズのデータを入力する。
Microcomputer PRS signal CLCM
When set to 'H' and sends predetermined data as an SO signal in synchronization with the SCLK signal, the circuit LCM transmits the buffer signals LCK, SCLK and SO signals through the specified camera-lens interface. Output DCL to lens. At the same time, the buffer signal of the signal DLC from the lens (the part surrounded by the dashed line) is output as an SI signal, and the computer
PRS inputs lens data as an SI signal in synchronization with the SCLK signal.

SDRは焦点検出用のラインセンサ装置SNSの
駆動回路であり、コンピユーターPRSからの信
号CSDRが‘H'のとき選択されて、SO,SI,
SCLK信号によりコンピユーターPRSにて制御さ
れる。
SDR is a drive circuit for the line sensor device SNS for focus detection, and is selected when the signal CSDR from the computer PRS is 'H'.
Controlled by computer PRS by SCLK signal.

SNSは例えば一対のCCDラインセンサCCD1
CCD2を含むセンサ装置である。φ1,φ2はコ
ンピユーターPRSからのクロツクCKを受け、駆
動回路SDRにて生成されるCCD駆動用のクロツ
ク、SHはラインセンサCCD1,CCD2に蓄積され
た電荷を転送部に転送させる信号、CLRはライ
ンセンサCCD1,CCD2の蓄積電荷をクリアさせる
クリア信号でありこれらの各信号はコンピユータ
ーPRSにて制御される駆動回路SDRにて形成さ
れる。
For example, SNS is a pair of CCD line sensors CCD 1 ,
This is a sensor device including CCD 2 . φ1 and φ2 are CCD driving clocks generated by the drive circuit SDR in response to the clock CK from the computer PRS, SH is a signal for transferring the charges accumulated in the line sensors CCD 1 and CCD 2 to the transfer section, and CLR is a clear signal for clearing the accumulated charges of line sensors CCD 1 and CCD 2 , and each of these signals is formed by a drive circuit SDR controlled by a computer PRS.

センサ装置SNSの出力信号OSはクロツクφ1,
φ2に同期して時系列で出力されるセンサCCD1
CCD2の各絵素に蓄積された像信号であり、
CCD1,CCD2に各ビツトごとに出力され回路
SDR内の増幅回路で増幅された後、AOS信号と
してコンピユーターPRSに入力される。コンピ
ユーターPRSはAOS信号をアナログ入力端子か
ら入力し、CK信号に同期して、内部のA/D変
換機能でA/D変換後RAMの所定のアドレスに
順次格納する。
The output signal OS of the sensor device SNS is clock φ1,
Sensor CCD 1 outputs in time series in synchronization with φ2,
It is an image signal accumulated in each picture element of CCD 2 ,
Each bit is output to CCD 1 and CCD 2 and sent to the circuit.
After being amplified by the amplifier circuit in the SDR, it is input to the computer PRS as an AOS signal. The computer PRS inputs the AOS signal from the analog input terminal, and in synchronization with the CK signal, converts it from A/D using its internal A/D conversion function and sequentially stores it at a predetermined address in the RAM.

同じくSNSの出力信号であるAGC信号は、装
置SNS内の蓄積制御用センサの出力であり、回
路SDRに入力されて、センサCCD1,CCD2の蓄
積時間制御に用いられる。
The AGC signal, which is also an output signal of the SNS, is the output of the storage control sensor in the device SNS, is input to the circuit SDR, and is used to control the storage time of the sensors CCD 1 and CCD 2 .

SPCは撮影レンズを介して光を受光する測光セ
ンサであり、その出力SSPCはコンピユーター
PRSのアナログ入力端子に入力され、A/D変
換後、自動露出制御(AE)に用いられる。
SPC is a photometric sensor that receives light through a photographic lens, and its output SSPC is sent to a computer.
It is input to the analog input terminal of PRS, and after A/D conversion, it is used for automatic exposure control (AE).

DDRはスイツチ・センスおよび表示用回路で
あり、コンピユーターPRSからの信号CDDRが
‘H'のとき選択されて、SO,SI,SCLKの各信
号によりコンピユーターPRSとの通信制御がな
される。即ち、コンピユーターPRSから送られ
てくるデータに基づいてカメラの表示を切り替え
たり、レリーズボタンに連動するスイツチSW1
SW2をはじめ各種操作部材に連動してオン・オフ
するスイツチ群SWSのスイツチ状態をコンピユ
ーターPRSに連絡する。
DDR is a switch sense and display circuit, and is selected when the signal CDDR from the computer PRS is 'H', and communication with the computer PRS is controlled by the SO, SI, and SCLK signals. In other words, the camera display is switched based on the data sent from the computer PRS, and the switch SW 1 is linked to the release button.
The switch status of the switch group SWS, which is turned on and off in conjunction with various operating members including SW 2 , is communicated to the computer PRS.

MDR1,MDR2はフイルム給送及びシヤツ
ターチヤージ用モーターMTR1,MTR2の駆
動回路で、信号M1F,M1R,M2F,M2R
でモーターの正転・逆転を実行する。
MDR1 and MDR2 are drive circuits for film feeding and shutter charge motors MTR1 and MTR2, and signals M1F, M1R, M2F, M2R
Executes forward/reverse rotation of the motor.

MG1,MG2は各々シヤツター先幕・後幕走
行開始用マグネツトで、信号SMG1,SMG2、
増幅トランジスタTR1,TR2で通電され、コ
ンピユーターPRSによりシヤツター制御が行わ
れる。
MG1 and MG2 are the magnets for starting the shutter front and rear curtains, respectively, and the signals SMG1, SMG2,
The amplifier transistors TR1 and TR2 are energized, and the computer PRS performs shutter control.

尚、スイツチ・センスおよび表示用回路DDR、
モーター駆動回路MDR1,MDR2、シヤツタ
ー制御は、本発明と直接関わりがないので、詳し
い説明は省略する。
In addition, switch sense and display circuit DDR,
Since the motor drive circuits MDR1, MDR2 and shutter control are not directly related to the present invention, detailed explanations thereof will be omitted.

同期信号LCKに同期してレンズ内制御回路
LPRSに入力される信号DCLは、カメラからレン
ズに対する命令のデータであり、命令に対するレ
ンズの動作が予め決められている。
In-lens control circuit synchronized with synchronization signal LCK
The signal DCL input to the LPRS is data of a command from the camera to the lens, and the operation of the lens in response to the command is determined in advance.

制御回路LPRSは、所定の手続きに従つて入力
命令を解析し、焦点調節や絞り制御の動作や、出
力DLCからのレンズの各種パラメータ(開放F
ナンバー、焦点距離、デフオーカス量対繰り出し
量の係数等)の出力を行う。
The control circuit LPRS analyzes input commands according to a predetermined procedure, performs focus adjustment and aperture control operations, and outputs various lens parameters (aperture f/) from the output DLC.
number, focal length, coefficient of defocus amount vs. extension amount, etc.).

実施例では、全体繰り出しの単レンズの例を示
しており、カメラから焦点調節の命令が送られた
場合には、同時に送られてくる駆動量・方向に従
つて、焦点調節用モーターLMTRに対して信号
LMF,LMRを送出し、モーターLMTRを駆動
して、光学系を光軸方向移動させて焦点調節を行
う。光学系の移動量はエンコーダー回路ENCの
信号SENCでモニターして、所定の移動が完了し
た時点で、信号LMF,LMRを‘L'にしてモータ
ーLMTRを制動する。
The example shows an example of a single lens that extends entirely, and when a focus adjustment command is sent from the camera, the focus adjustment motor LMTR is activated according to the drive amount and direction sent at the same time. signal
The LMF and LMR are sent out, the motor LMTR is driven, and the optical system is moved along the optical axis to adjust the focus. The amount of movement of the optical system is monitored by the signal SENC of the encoder circuit ENC, and when the predetermined movement is completed, the signals LMF and LMR are set to 'L' to brake the motor LMTR.

カメラから絞り制御の命令が送られた場合に
は、同時に送られてくる絞り段数に従つて、絞り
機構に連動する公知のステツピング・モーター
DMTRを駆動する。尚、ステツピング・モータ
ーはオープン制御が可能なため、動作をモニター
するためのエンコーダーを必要としない。
When an aperture control command is sent from the camera, a well-known stepping motor operates in conjunction with the aperture mechanism according to the number of aperture stages sent at the same time.
Drives DMTR. Furthermore, since the stepping motor can be controlled in an open manner, it does not require an encoder to monitor its operation.

尚、上記回路LPRSにはレンズの焦点距離情報
(ズームレンズの場合にはズーム状態に応じた焦
点距離情報)等の上記パロメーターを所定のアド
レスに格納しているメモリーが設けられている。
又、該回路LPRSには上記モニター信号SENCと
してのパルスをカウントするカウンターが設けら
れ、更に後述のレンズ駆動に際しデフオーカス量
に応じた値に対応するパルス数をカウント、その
カウント値がレンズ駆動前のカウント値から上記
デフオーカス量に応じた値分だけ上記パルス数の
カウントにて変化した時、即ちレンズ駆動により
変化したカウント値がデフオーカス量に応じた値
と一致した時に信号LMF,LMRをLとなしてモ
ーターLMTRを停止させる制御回路を有してい
る。又該回路は上記の如くモーター制御が上記カ
ウント値の一致にて停止した時にレンズ停止信号
を形成し、又レンズ駆動によるカウント値の変化
分がデフオーカス量に応じた値となる以前にレン
ズが駆動を停止した状態となつたことを検知し
て、この際にレンズ駆動不能信号を形成する信号
形成回路が更に設けられている。上記レンズ駆動
不能信号は例えば上記カウント値の変化分がデフ
オーカス量に応じた値となつていない状態でモニ
ター信号SENCが所定時間以上形成されていない
か否かを判定し、上記モニター信号が斯様な条件
下で所定時間以上形成されていない時にレンズ駆
動不能信号を形成する。
The circuit LPRS is provided with a memory that stores the parameters such as lens focal length information (focal length information depending on the zoom state in the case of a zoom lens) at a predetermined address.
In addition, the circuit LPRS is provided with a counter that counts the pulses as the monitor signal SENC, and further counts the number of pulses corresponding to the amount of defocus when driving the lens, which will be described later. When the count value changes by a value corresponding to the above-mentioned defocus amount by counting the above-mentioned pulse number, that is, when the count value changed by lens driving matches the value according to the defocus amount, the signals LMF and LMR are set to L. It has a control circuit that stops the motor LMTR. In addition, as described above, this circuit forms a lens stop signal when the motor control stops when the above count values match, and the lens is driven before the change in the count value due to lens drive reaches a value corresponding to the defocus amount. A signal forming circuit is further provided for detecting that the lens is in a stopped state and forming a lens drive disabling signal at this time. The lens drive failure signal is generated by determining, for example, whether or not the monitor signal SENC has been generated for a predetermined period of time or longer in a state where the change in the count value has not reached a value corresponding to the defocus amount. A lens drive disabling signal is generated when the signal is not generated for a predetermined period or more under certain conditions.

又、上記表示器は合焦及び焦点検出不能表示用
又はNG表示用LDE,更には後述のDEP1,DPE2
表示を行うセグメント等の表示素子を有している
ものとする。
In addition, the above display is an LDE for displaying focus and focus detection failure or NG display, and furthermore, DEP 1 and DPE 2 described later.
It is assumed that the device has a display element such as a segment that performs display.

以上のような構成によるカメラの動作について
第2図を用いて説明する。
The operation of the camera configured as above will be explained using FIG. 2.

不図示の電源スイツチをオンとするとマイク
ロ・コンピユーターPRSへの給電がなされ、コ
ンピユーターPRSは格納プログラムを実行する。
When a power switch (not shown) is turned on, power is supplied to the microcomputer PRS, and the computer PRS executes the stored program.

第2図aは上記プログラムの全体プローを示す
フローチヤートである。格納プログラムの実行が
開始されるとステツプ1から順次各ステツプが実
行される。
FIG. 2a is a flowchart showing the entire procedure of the above program. When execution of the stored program is started, each step is executed sequentially from step 1.

ステツプ1:デイプスモードか否か判定され
る。
Step 1: It is determined whether depth mode is selected.

該判定はコンピユーターPRSから信号CDDR
をHとなし、回路DDRを指定し、入力スイツチ
群SWSに設けられているモード選択スイツチの
設定状態をSI信号としてコンピユーターPRSに
入力し、モード選択スイツチの設定状態を判別す
ることにて行われる。
This judgment is made using the signal CDDR from the computer PRS.
is H, designates the circuit DDR, inputs the setting state of the mode selection switch provided in the input switch group SWS to the computer PRS as an SI signal, and determines the setting state of the mode selection switch. .

モードが通常モードに設定されている時にはス
テツプ2へ移行する。
If the mode is set to normal mode, the process moves to step 2.

ステツプ2:シヤツターボタンの第1段階操作
にてオンとなるスイツチSW1の状態検知を行う。
Step 2: The state of switch SW 1 , which is turned on by the first step operation of the shutter button, is detected.

該スイツチSW1の状態判別動作はスイツチ群
SWSと同様にして行われる。
The operation to determine the status of switch SW 1 is based on the switch group.
This is done in the same way as SWS.

スイツチSW1がオンの時にはステツプ3,4を
実行後、再度ステツプ1に戻り、又スイツチSW1
がオフの時にはステツプ5にて全フラツグを0と
なし、ステツプ6にてレンズ停止命令を出した後
再度ステツプ1へ移行する。
When switch SW 1 is on, steps 3 and 4 are executed, the process returns to step 1 again, and switch SW 1 is turned on.
When the lens is off, all flags are set to 0 in step 5, a lens stop command is issued in step 6, and the process returns to step 1.

従つて、モードが通常モードに設定され、かつ
シヤツターボタンが操作されていない状態ではス
テツプ1→2→5→6を繰り返すこととなる。
Therefore, when the mode is set to normal mode and the shutter button is not operated, steps 1→2→5→6 are repeated.

今、シヤツターボタンが操作されていない状態
でモードがデイプスモードに設定されたとする。
Suppose now that the mode is set to depth mode with the shutter button not being operated.

この場合には上記ステツプ1→2→5→6の繰
り返し中のステツプ1にてモードがデイプスへ移
行したことが検知されるのでステツプは7へ移行
する。
In this case, during the repetition of steps 1→2→5→6, it is detected in step 1 that the mode has shifted to depth, so the step shifts to step 7.

ステツプ7:レリーズ動作を禁止する。 Step 7: Prohibit release operation.

ステツプ8:フラツグDEP1を除く全フラツグ
を0にセツトしフラツグDEP1を1にセツトする。
Step 8: Set all flags except flag DEP 1 to 0, and set flag DEP 1 to 1.

ステツプ9:スイツチSW1の状態を判定し、ス
イツチSW1がオフの時にはステツプ10以後へ、又
スイツチSW1がオンの時にはステツプ17へ移行す
る。
Step 9: Determine the state of switch SW 1 , and if switch SW 1 is off, proceed to step 10 and subsequent steps; if switch SW 1 is on, proceed to step 17.

今スイツチSW1がオフであつたとする。この場
合にはステツプ10にてレンズ停止指令を出し、ス
テツプ12にてフラツグDEPDNの設定状態を判定
する。
Assume that switch SW 1 is now off. In this case, a lens stop command is issued in step 10, and the setting state of the flag DEPDN is determined in step 12.

ステツプ8にてフラツグDEP1以外のフラツグ
は0に設定されているため、ステツプ13へ移行
し、フラツグDEPJF,DEPOKを0にセツトしス
テツプ14にて再度設定モードが判定され、デイプ
スモードのまま保持されていればステツプ15へ又
デイプスモードが解除されていればステツプ16へ
移行する。ステツプ15では内部タイマーの経過時
間が所定値を越えたか否かの判定がなされる。尚
このタイマーはデイプスモードの設定がなされて
から計時動作を開始するものとする。
Since the flags other than flag DEP 1 are set to 0 in step 8, the process moves to step 13, where flags DEPJF and DEPOK are set to 0, and the setting mode is determined again in step 14, and the depth mode is maintained. If the depth mode is released, the process moves to step 15. If the depth mode is released, the process moves to step 16. In step 15, it is determined whether the elapsed time of the internal timer exceeds a predetermined value. It is assumed that this timer starts its timekeeping operation after the depth mode is set.

タイマーの計時が所定時間を越えていない時に
は再度ステツプ8へ移行し、又所定時間を越えた
時にはステツプ16へ移行する。
If the time measured by the timer has not exceeded the predetermined time, the process goes to step 8 again, and if the time has exceeded the predetermined time, the process goes to step 16.

上記ステツプ9〜16までにて一度デイプスモー
ドが設定されてから所定時間が経過しない限り、
ステツプ9〜15が繰り返えし行われることとな
り、この所定時間内にスイツチSW1がオンとなる
とステツプは17へ移行する。又、上記所定時間以
内にスイツチSW1をオンとしない場合又は、デイ
プスモードを解除した場合にはステツプ16へ移行
し全フラツグを0にセツトした後再度ステツプは
1へ戻る。
Unless the predetermined time has elapsed after the depth mode is set in steps 9 to 16 above,
Steps 9 to 15 are repeated, and if the switch SW 1 is turned on within this predetermined time, the process moves to step 17. If the switch SW 1 is not turned on within the predetermined time, or if the depth mode is canceled, the process proceeds to step 16, where all flags are set to 0, and the process returns to step 1 again.

従つて、一度デイプスモードを設定しても所定
時間内にシヤツターボタンを操作しない場合には
デイプスモードが解除され通常モードへ復帰する
こととなる。
Therefore, even if the depth mode is set once, if the shutter button is not operated within a predetermined time, the depth mode will be canceled and the mode will return to the normal mode.

今、デイプスモードが設定されてから所定時間
以内にシヤツターボタンの第1段階操作がなされ
たものとする。この場合には上述の如くステツプ
は17へ移行し測光サブルーチンが実行される。該
測光サブルーチンでは撮影レンズを介して光を測
光する測光センサSPCの出力SSPCをコンピユー
ターPRSに入力し、内部のA/D変換機能にて
デジタル化し、該デジタル値をメモリーに記憶す
る。
Assume that the first step of the shutter button operation is performed within a predetermined time after the depth mode is set. In this case, as described above, the process moves to step 17 and the photometry subroutine is executed. In this photometry subroutine, the output SSPC of the photometry sensor SPC that measures light through the photographing lens is input to the computer PRS, digitized by the internal A/D conversion function, and the digital value is stored in the memory.

該測光サブルーチンが行われた後ステツプは18
移行へ移行する。
After the photometry subroutine is executed, the steps are 18.
Migrate to Migration.

ステツプ18:上記タイマーをリセツトし、初期
状態から計時動作を再開する。
Step 18: Reset the above timer and restart timing operation from the initial state.

ステツプ19:フラツグDEPJFのセツト状態を
検知する。
Step 19: Detect the set state of flag DEPJF.

今、ステツプ8にてフラツグDEP1以外は0に
セツトされているためステツプ20へ移行する。
Now, in step 8, flags other than DEP 1 are set to 0, so the process moves to step 20.

該ステツプ20のAF制御サブルーチンは第2図
bのステツプ100以後に記載されている。
The AF control subroutine of step 20 is described after step 100 in FIG. 2b.

以下該AF制御サブルーチンについてデイプス
モード下の初回の動作について説明する。
The first operation of the AF control subroutine under depth mode will be described below.

ステツプ200:フラツグPRMVのセツト状態を
検知する。該フラツグも0にセツトされているた
め、ステツプ201へ移行する。
Step 200: Detect the set state of flag PRMV. Since this flag is also set to 0, the process moves to step 201.

ステツプ201:フラツグDEPMVのセツト状態
を検知する。このフラツグも0にセツトされてお
り、ステツプは204へ移行し、デイプスモードか
否かの判別がなされる。今上記の如くデイプスモ
ードであるため、ステツプは205へ移行する。
Step 201: Detect the set state of flag DEPMV. This flag is also set to 0, and the step moves to 204, where it is determined whether or not the depth mode is set. Since the current mode is depth mode as described above, the step shifts to 205.

ステツプ205:フラツグDEP1のセツト状態を検
知する。該フラツグDEP1はステツプ8にて1に
セツトされているため、ステツプは206へ移行す
る。
Step 205: Detect the set state of flag DEP 1 . Since the flag DEP 1 was set to 1 in step 8, the step moves to 206.

ステツプ206は焦点検出サブルーチンであり、
該サブルーチンは第2図cに示したステツプ300
以下に記載されている。次に該サブルーチンにつ
き述べる。
Step 206 is a focus detection subroutine,
The subroutine starts at step 300 shown in FIG. 2c.
Described below. Next, this subroutine will be described.

ステツプ300:像信号入力サブルーチンを実行
する。
Step 300: Execute the image signal input subroutine.

該像信号入力サブルーチンではまずコンピユー
ターPRSにてCSDRをHとなし駆動回路SDRを
選択し、SO信号を該駆動回路SDRに伝える。こ
の時のSO信号は蓄積開始命令であり、この命令
に応じて駆動回路SDRはCLR信号をラインセン
サ装置SNSに伝えCCDラインセンサの像蓄積信
号をクリアし、その後像に対する蓄積動作を行わ
せる。ラインセンサ装置SNSのCCDラインセン
サCCD1,CCD2には撮影レンズを介して入射する
像光束がそれぞれ入射しており各センサCCD1
CCD2上の像位置が焦点状態に応じて決定される。
詳述すると、被写体に対して合焦状態では各セン
サCCD1とCCD2上の同一位置に同一像パターンが
投射され、前ピン又は後ピン状態ではCCD1
CCD2上の像パターンがそのピントずれ方向及び
ずれ量に応じて対称的にずれた位置に投射され
る。従つて、上記CCD1とCCD2上の像パターン間
の位置ずれ量及び方向を検知することにてピント
ずれ方向及びずれ量が検知される。
In the image signal input subroutine, first, the computer PRS sets CSDR to H, selects the drive circuit SDR, and transmits the SO signal to the drive circuit SDR. The SO signal at this time is an accumulation start command, and in response to this command, the drive circuit SDR sends a CLR signal to the line sensor device SNS to clear the image accumulation signal of the CCD line sensor, and then performs an accumulation operation on the image. Image light beams incident through the photographing lens are incident on the CCD line sensors CCD 1 and CCD 2 of the line sensor device SNS , respectively.
The image position on CCD 2 is determined according to the focus state.
To be more specific, when the object is in focus, the same image pattern is projected at the same position on each sensor CCD 1 and CCD 2 , and when the subject is in focus or in the rear focus state, the same image pattern is projected on CCD 1 and CCD 2 .
The image pattern on the CCD 2 is projected at symmetrically shifted positions depending on the direction and amount of focus shift. Therefore, by detecting the amount and direction of positional deviation between the image patterns on the CCD 1 and CCD 2 , the direction and amount of out-of-focus can be detected.

上記の如くして焦点状態に応じた位置に投射さ
れた像パターンを上記像信号クリア後各CCD1
CCD2にて所定時間蓄積し、その後、駆動回路
SDRから信号SH及びクロツクφ1,φ2がセン
サ装置SNSに供給される。尚、上記像パターン
の蓄積時間はSNS内の蓄積制御用センサの出力
AGCに基づいて決定されるものである。
After clearing the image signal, the image pattern projected to the position according to the focus state as described above is transmitted to each CCD 1 ,
The CCD 2 accumulates data for a predetermined time, and then the drive circuit
A signal SH and clocks φ1 and φ2 are supplied from the SDR to the sensor device SNS. The accumulation time of the above image pattern is the output of the accumulation control sensor in the SNS.
This is determined based on AGC.

上記の如くしてセンサ装置SNSへ信号SH及び
クロツクφ1,φ2が供給されると、センサ装置
SNS、出力端から各センサCCD1,CCD2の各絵
素に蓄積された像信号が出力OSとして順次時系
列にて送出され、駆動回路SDR内の増巾回路で
増巾され信号AOSとしてコンピユーターPRSに
順次入力する。コンピユーターPRSは上記信号
AOSを内部のA/D変換機能にて順次デジタル
値に変換し所定のRAMに格納する。
When the signal SH and the clocks φ1 and φ2 are supplied to the sensor device SNS as described above, the sensor device
The image signals accumulated in each pixel of each sensor CCD 1 and CCD 2 from the output terminal of SNS are sent out sequentially in time series as output OS, amplified by the amplification circuit in the drive circuit SDR, and sent to the computer as signal AOS. Input into PRS sequentially. Computer PRS is the above signal
The AOS is sequentially converted into digital values using the internal A/D conversion function and stored in a predetermined RAM.

以上の動作にてセンサCCD1,CCD2上の像パタ
ーンに応じた各センサごとの像信号がデジタル値
としてRAMに記憶され像信号入力サブルーチン
を終了しステツプ301へ移行する。
With the above operations, the image signal for each sensor corresponding to the image pattern on the sensors CCD 1 and CCD 2 is stored in the RAM as a digital value, and the image signal input subroutine is ended and the process moves to step 301.

ステツプ301:デフオーカス量計算サブルーチ
ンを実行する。このサブルーチンでは上記像信号
入力サブルーチンにて求められたセンサCCD1
CCD2上の像パターンに応じたデジタル値を基に
合焦までのずれ量並びにずれ方向をデフオーカス
量DEFとして算出する。該デフオーカス量の具
体的な算出方法は本願と直接関係がないので、そ
の詳細な説明は省略するが、上記の如くセンサ
CCD1とCCD2の像パターンの一致度が焦点状態に
よつて決定されるので、該パターンに対応した上
記各センサのデジタル値を比較処理し、そのデー
ターの一致度を求め合焦状態からのずれ量及び方
向、即ちデフオーカス量DEFを求めるものであ
る。又、このサブルーチンではセンサCCD1
CCD2の像パターンに応じたデジタル値からコン
トラストCNTをも求めており、このコントラス
ト検知も公知である。その詳細な説明は省略す
る。
Step 301: Execute the differential focus amount calculation subroutine. In this subroutine, the sensor CCD 1 obtained in the above image signal input subroutine and
Based on digital values corresponding to the image pattern on the CCD 2 , the amount and direction of deviation until in-focus is calculated as the defocus amount DEF. Since the specific method for calculating the amount of defocus is not directly related to this application, a detailed explanation thereof will be omitted.
Since the degree of coincidence between the image patterns of CCD 1 and CCD 2 is determined by the focus state, the digital values of each of the above-mentioned sensors corresponding to the pattern are compared and processed, and the degree of coincidence of the data is determined and calculated from the focus state. This is to obtain the amount and direction of deviation, that is, the differential focus amount DEF. Also, in this subroutine, the sensors CCD 1 ,
Contrast CNT is also determined from digital values corresponding to the image pattern of CCD 2 , and this contrast detection is also known. A detailed explanation thereof will be omitted.

ステツプ302:フラツグJF及びAFNGに0セツ
トする。
Step 302: Set flags JF and AFNG to 0.

ステツプ303:コントラストCNTと一定値
LCLVCを比較し、CNT<LCLVCの時、即ち、
低コントラストの時にはステツプ304にてフラツ
グAFNGに1をセツトし、焦点検出サブルーチ
ンを終了してステツプ207へ移行する。
Step 303: Contrast CNT and constant value
Compare LCLVC, and when CNT<LCLVC, that is,
When the contrast is low, the flag AFNG is set to 1 in step 304, the focus detection subroutine is ended, and the process moves to step 207.

又、CNT>LCLVCの時、即ちコントラストが
十分にあつた時にはステツプ305へ移行し、算出
デフオーカス量DEFが合焦と見做せる一定デフ
オーカス量JFFLD以内か否かの判定がなされ、
DEF<JFFLDの時にはステツプ306にてフラツグ
JFを1にセツトし焦点検出サブルーチンを終了
してステツプ207へ移行する。又、上記の判定に
てDEF>JFFLDの時にはフラツグJFを1にセツ
トすることなしに焦点検出サブルーチンを終了し
てステツプ207へ移行する。
Further, when CNT>LCLVC, that is, when the contrast is sufficient, the process moves to step 305, where it is determined whether or not the calculated differential focus amount DEF is within a constant differential focus amount JFFLD that can be considered to be in focus.
When DEF<JFFLD, flag is set in step 306.
JF is set to 1, the focus detection subroutine is ended, and the process moves to step 207. If the above judgment indicates that DEF>JFFLD, the focus detection subroutine is ended without setting the flag JF to 1, and the process proceeds to step 207.

以上の焦点検出サブルーチンではコントラスト
が低い時にはフラツグAFNGを1にセツトし、
又コントラストが十分な時でデフオーカス量が合
焦と見做せる時にはフラツグJFを1にセツトし、
又デフオーカス量が合焦と見做せる範囲よりも大
の時にはフラツグJFを1にセツトすることなし
にリターンする。
In the above focus detection subroutine, when the contrast is low, the flag AFNG is set to 1,
Also, when the contrast is sufficient and the amount of defocus is considered to be in focus, set the flag JF to 1,
Also, when the amount of defocus is larger than the range that can be considered to be in focus, the program returns without setting the flag JF to 1.

上記焦点検出サブルーチンにて焦点状態の検出
及び判定がなされた後ステツプ207にて表示サブ
ルーチンが実行される。該表示サブルーチンでは
フラツグAFNGが1にセツトされている時には
コンピユーターPRSにてCDDR信号をHとなし、
回路DDRを指定し、又SO信号としての表示信号
を回路DDRに伝え、表示器DSPに設けられた焦
点検出不能表示用LEDを点灯させる。又フラツ
グJFが1にセツトされている時には同様にして
合焦表示用LEDを点灯させる。
After the focus state is detected and determined in the focus detection subroutine, a display subroutine is executed in step 207. In this display subroutine, when the flag AFNG is set to 1, the computer PRS sets the CDDR signal to H,
The circuit DDR is designated, and a display signal as an SO signal is transmitted to the circuit DDR, and an LED for indicating that the focus cannot be detected provided on the display device DSP is turned on. Also, when the flag JF is set to 1, the focus display LED is lit in the same way.

表示サブルーチンにて焦点状態の表示を行つた
後ステツプは208へ移行する。
After displaying the focus state in the display subroutine, the step moves to 208.

ステツプ208:フラツグJFのセツト状態を判別
する。
Step 208: Determine the set state of flag JF.

フラツグJFが1にセツトされている時には、
ステツプ209にてフラツグDEP1のセツト状態が判
定される。今DEP1は1にセツトされているため、
ステツプ210を行いフラツグDEPJFを1にセツト
した後にリターンし、再度ステツプ9へ移行す
る。
When flag JF is set to 1,
At step 209, the set state of flag DEP 1 is determined. Since DEP 1 is currently set to 1,
After executing step 210 and setting the flag DEPJF to 1, the program returns and moves to step 9 again.

又、フラツグJFが0の時にはステツプ211にて
フラツグAFNGのセツト状態が判定されAFNG
が1にセツトされている時にはリターンし再度ス
テツプ9へ移行する。
Also, when flag JF is 0, the set state of flag AFNG is determined in step 211, and AFNG is set.
When is set to 1, the process returns and goes to step 9 again.

又、フラツグJF及びAFNGが共に0の時には
ステツプ212以後のステツプが実行される。
Further, when both flags JF and AFNG are 0, steps after step 212 are executed.

ステツプ212:レンズ駆動量計算サブルーチン
を(FP計算サブルーチンと称す。)実行する。該
サブルーチンは第2図dに示されるステツプ400
以後に記載される。
Step 212: Execute a lens drive amount calculation subroutine (referred to as FP calculation subroutine). The subroutine includes step 400 shown in FIG. 2d.
It will be described later.

ステツプ400:レンズから「デフオーカス量対
くり出し量の係数S」を入力する。この入力動作
はコンピユーターPRSにて信号CLCMをHとな
し回路LCMを指定し、該回路LCMを介してレン
ズ内の回路LPRSを指定する。又、信号SDを上
記回路LCMを介してDCLとして回路LPRSに伝
える。この際の信号SOは係数Sを読み出す命令
であり、回路LPRSは該信号SOにより内部の
RAMに格納されていた上記係数Sを信号DLCと
して回路LCMに伝え、該回路LCMは上記信号
DLCをSI信号としてコンピユーターPRSに入力
し、係数Sがコンピユーターに入力される。
Step 400: Input the "coefficient S of the amount of defocus versus the amount of projection" from the lens. This input operation causes the computer PRS to set the signal CLCM to H, designating the circuit LCM, and designating the circuit LPRS in the lens via the circuit LCM. Further, the signal SD is transmitted to the circuit LPRS as DCL via the circuit LCM. The signal SO at this time is a command to read the coefficient S, and the circuit LPRS uses the signal SO to read out the coefficient S.
The coefficient S stored in the RAM is transmitted to the circuit LCM as a signal DLC, and the circuit LCM receives the above signal
The DLC is input to the computer PRS as an SI signal, and the coefficient S is input to the computer.

ステツプ401:レンズから「エンコーダー1パ
ルス当たりのくり出し量PTM」を入力する。該
PTHの入力動作は上記係数Sと同様にして行わ
れる。
Step 401: Input the "protrusion amount PTM per encoder pulse" from the lens. Applicable
The input operation of PTH is performed in the same manner as the coefficient S described above.

ステツプ402:上記各読み出し動作にて入力さ
れた係数S及びPTHと算出デフオーカス量DEF
との演算DEF*S/FPHを行う。
Step 402: Coefficient S and PTH input in each read operation above and calculated defocus amount DEF
Perform the calculation DEF*S/FPH with.

上記の如くFPHはエンコーダー1パルス当た
りのくり出し量であり、該エンコーダーENCは
レンズLNSの移動量を検知して、単位あたりの
移動量ごとに1パルスを出力する、例えばパルス
板にて構成されている。
As mentioned above, FPH is the amount of output per encoder pulse, and the encoder ENC is composed of, for example, a pulse plate, which detects the amount of movement of the lens LNS and outputs one pulse for each unit of movement. There is.

又係数Sはデフオーカス量対くり出し量の係数
であり、DEF*Sはデフオーカス量に応じたく
り出し量、即ちデフオーカスに応じたレンズの移
動量を示す。従つて、DEF*S/FPHはデフオ
ーカス量に応じた上記エンコーダーENCからの
パルス数を示すこととなり、このパルス数FP分
だけレンズが移動することにて算出デフオーカス
分のレンズが駆動されることとなる。
Further, the coefficient S is a coefficient of the amount of defocus versus the amount of protrusion, and DEF*S indicates the amount of protrusion corresponding to the amount of defocus, that is, the amount of movement of the lens in response to the defocus amount. Therefore, DEF*S/FPH indicates the number of pulses from the encoder ENC that corresponds to the amount of defocus, and by moving the lens by the number of pulses FP, the lens is driven by the amount of the calculated defocus. Become.

上記FP計算サブルーチンにてデフオーカス量
に応じたパルス数FPを求めた後ステツプは213へ
移行する。
After determining the number of pulses FP corresponding to the amount of defocus in the above FP calculation subroutine, the step moves to 213.

該ステツプ213にてレンズ駆動サブルーチンが
実行される。該サブルーチンではコンピユーター
PRSにてCLCM信号をHとなし、上記の如くし
て回路LPRSを指定すると共に上記パルス数FP
を信号SOとして回路LPRSに伝える。回路LPRS
では上記FPに応じて信号LMF又はLMRをHと
なし、モーターLMTRを駆動する。
At step 213, a lens drive subroutine is executed. In this subroutine, the computer
Set the CLCM signal to H at PRS, specify the circuit LPRS as described above, and specify the number of pulses FP as described above.
is transmitted to the circuit LPRS as a signal SO. circuit LPRS
Then, the signal LMF or LMR is set to H in accordance with the above FP to drive the motor LMTR.

尚、上記FPはデフオーカス量に応じて決定さ
れており、その合焦までのずれ方向、即ちレンズ
の駆動方向情報も含んでおり、この駆動方向情報
に応じて信号LMF又はLMRがHにセツトされレ
ンズが合焦方向へ駆動される。
Note that the above FP is determined according to the amount of defocus, and also includes information on the direction of deviation until focusing, that is, the driving direction of the lens, and the signal LMF or LMR is set to H according to this driving direction information. The lens is driven in the focusing direction.

該ステツプ213にてレンズの駆動を開始した後
ステツプは214へ移行しフラツグPRMVを1にセ
ツトした後AFサブルーチンを終了しリターンし
ステツプ9へ戻る。
After starting to drive the lens in step 213, the step moves to 214, sets the flag PRMV to 1, ends the AF subroutine, and returns to step 9.

今、デイプスモード時の初回のスイツチSW1
オン動作時における上記初回のAF制御サブルー
チンにて上記合焦判定がなされると、上記の如く
して合焦表示がなされた後にステツプ9へ戻るこ
ととなる。この状態でスイツチSW1がオンに保持
されていれば、再度ステツプ17に測光サブルーチ
ンが行われ、ステツプ18にてタイマーのリセツト
ステツプ19にてフラツグDEPJFのセツト状態の
判定がなされる。この時フラツグDEPJFは1に
セツトされているため、ステツプは21へ移行しフ
ラツグDEPOKのセツト状態が判別される。該フ
ラツグDEPOKは初期状態では0にセツトされて
いるためステツプは22移行へ進む。
Now, when the focus is determined in the first AF control subroutine when switch SW 1 is turned on for the first time in the depth mode, the process returns to step 9 after the focus is displayed as described above. Become. If the switch SW 1 is kept on in this state, the photometry subroutine is performed again in step 17, the timer is reset in step 18, and the set state of the flag DEPJF is determined in step 19. At this time, the flag DEPJF is set to 1, so the step moves to 21, and the set state of the flag DEPOK is determined. Since the flag DEPOK is initially set to 0, the step advances to step 22.

従つて、デイプスモードの初回のスイツチSW1
のオン動作におけるAF制御サブルーチンにて、
いきなり合焦判定がなされた時には合焦表示がな
された後ステツプ22へ移行する。
Therefore, the initial switch SW 1 in depth mode
In the AF control subroutine during the on operation of
When the focus is suddenly determined, the focus is displayed and then the process moves to step 22.

又、デイプスモードの初回のスイツチSW1のオ
ンにて焦点検出不能と判定がなされた時にはステ
ツプ9→17→18→19→20がスイツチSW1のオンの
限り繰り返し実行され、焦点検出動作が繰り返さ
れる。
Further, when it is determined that focus detection is impossible when switch SW 1 is turned on for the first time in depth mode, steps 9→17→18→19→20 are repeatedly executed as long as switch SW 1 is turned on, and the focus detection operation is repeated. .

又、デイプスモードの初回のスイツチSW1のオ
ン時のAF制御サブルーチンにて合焦までのデフ
オーカス量に基づくレンズ駆動指示がなされた場
合にも初回のAF制御サブルーチンが実行された
後スイツチSW1がオンに保持されていれば再度ス
テツプ9→17→18→19→20が繰り返される。上記
ステツプの繰り返し中でのステツプ20における
AF制御サブルーチンではステツプ200のフラツグ
PRMV検知にて1が検知されるので、ステツプ
202が実行されレンズが停止したか否かの判定が
なされる。
Also, if a lens drive instruction is given based on the amount of defocus until focusing in the AF control subroutine when switch SW 1 is turned on for the first time in depth mode, switch SW 1 will be turned on after the initial AF control subroutine is executed. If it is held, steps 9→17→18→19→20 are repeated again. At step 20 while repeating the above steps
In the AF control subroutine, the flag at step 200
Since 1 is detected by PRMV detection, step
202 is executed to determine whether the lens has stopped.

このレンズ停止の判定動作について述べる。本
実施例ではレンズ駆動に際し、上記の如くレンズ
の移動量を表わすパルス数FPが回路LPRSに入
力され、かつレンズLMSの移動に応じてエンコ
ーダーENCからパルスが送出され、このエンコ
ーダーからのパルス数が回路LPRS内のカウンタ
ーにてカウントされ、上記入力パルス数FPと一
致した時に回路LPRSは信号LMF,LMRをLと
なしモーターLHTRを停止させる様制御してい
る。
The operation for determining whether the lens has stopped will be described. In this embodiment, when driving the lens, the number of pulses FP representing the amount of movement of the lens is input to the circuit LPRS as described above, and pulses are sent out from the encoder ENC in accordance with the movement of the lens LMS, and the number of pulses from this encoder is It is counted by a counter in the circuit LPRS, and when it matches the input pulse number FP, the circuit LPRS sets the signals LMF and LMR to L and controls the motor LHTR to stop.

尚上記エンコーダーからのパルスのカウントは
そのレンズの駆動方向に応じてアツプ又はダウン
しカウントされるものとする。この様にしてレン
ズ駆動制御がなされるので上記入力パルス数FP
とエンコーダーからのパルスが一致してモーター
LHTRに対して停止動作が行われたことが回路
LPRS内で判定出来、この回路では上述のレンズ
駆動制御がなされない時にレンズ停止信号を形成
している。
It is assumed that the pulses from the encoder are counted up or down depending on the driving direction of the lens. Since lens drive control is performed in this way, the above input pulse number FP
The pulses from the encoder and the motor match
The circuit indicates that a stop operation has been performed on the LHTR.
This can be determined within the LPRS, and this circuit generates a lens stop signal when the lens drive control described above is not performed.

よつて、コンピユーターPRSは上記の如くし
て回路LPRSを指定し、このレンズ停止信号を読
み出すことにてステツプ202にてレンズが停止し
たか否かの判定を行つている。
Therefore, the computer PRS specifies the circuit LPRS as described above and reads out this lens stop signal to determine whether or not the lens has stopped in step 202.

尚、レンズ駆動中にレンズが例えば無限端位置
に突き当つて停止した場合には上記カウンターに
てカウントされたエンコーダーENCからのパル
ス数が上記パルス数FPと一致することなく、レ
ンズが停止状態となる。従つて、この様な場合に
はカウンターとパルス数FPが一致していない状
態であつてもエンコーダーENCからのパルスが
発生しなくなり、回路LPRSでは上記状態下でエ
ンコーダーENCからパルスが所定時間以上発生
していないことを検知すると信号LMF,LMRを
Lとなしモーターを停止させると共にレンズ駆動
不能信号を形成し回路内部のRAMに該信号を格
納する様構成されており、正常動作時と異常動作
時のレンズ停止を判別させているものである。
In addition, if the lens hits the infinite end position and stops while driving the lens, the number of pulses from the encoder ENC counted by the counter above will not match the number of pulses FP above, and the lens will stop. Become. Therefore, in such a case, even if the counter and the number of pulses FP do not match, the encoder ENC will not generate pulses, and in the circuit LPRS, under the above conditions, the encoder ENC will not generate pulses for more than a predetermined time. When it detects that the lens is not being driven, the signals LMF and LMR are set to L, the motor is stopped, and a lens drive disabling signal is generated.This signal is stored in the RAM inside the circuit.During normal operation and abnormal operation This is used to determine whether the lens has stopped.

上記ステツプ202にてレンズ停止信号が検知出
来ない時、即ちレンズがまだ駆動中であると判定
された時には直ちにAF制御サブルーチンを終了
し再度ステツプ9へ戻る。
If the lens stop signal cannot be detected in step 202, that is, if it is determined that the lens is still being driven, the AF control subroutine is immediately terminated and the process returns to step 9 again.

よつて、デフオーカス量に応じてレンズが駆動
されている途中では、上記の繰り返しステツプと
してはステツプ9→17→18→19→20(200→202)
が繰り返されることとなる。
Therefore, while the lens is being driven according to the amount of defocus, the above repeating steps are steps 9→17→18→19→20 (200→202).
will be repeated.

上記の如くしてレンズ駆動がなされている過程
にてレンズの駆動量、即ちエンコーダーENCか
らのパルス数が上記FP計算サブルーチンにて求
められたパルス数FPと一致した時には、これら
のパルス数の一致検知を行つている回路LPRSに
て出力LMF及びLMRがLにされ、モーター
LMTRが停止しレンズがデフオーカス量だけ駆
動されることとなる。従つて上記ステツプの繰り
返し中にレンズがデフオーカス量だけ駆動される
とステツプ202にてレンズが停止したと判定され
るため、ステツプ203にてフラツグPRMVに0が
セツトされ以後前述と同様にステツプ204→205→
206が実行される。
While the lens is being driven as described above, when the amount of lens drive, that is, the number of pulses from the encoder ENC, matches the number of pulses FP found in the FP calculation subroutine above, the number of pulses matches. The output LMF and LMR are set to L in the detection circuit LPRS, and the motor
The LMTR will stop and the lens will be driven by the defocus amount. Therefore, if the lens is driven by the defocus amount while repeating the above steps, it is determined in step 202 that the lens has stopped, so the flag PRMV is set to 0 in step 203, and thereafter, as described above, steps 204→ 205→
206 is executed.

この時、上述の如くレンズはデフオーカス量分
駆動されているため、上記ステツプ206にて焦点
検出動作がなされると合焦と判定されることとな
り、以後ステツプ208→209→210へ移行する。
At this time, since the lens has been driven by the amount of defocus as described above, when the focus detection operation is performed in step 206, it is determined that the lens is in focus, and the process then moves to steps 208→209→210.

従つて、デイプスモードで初回のスイツチSW1
のオン動作にてレンズ駆動がなされた時にはレン
ズが被写体に対して合焦となるまで移行し、一度
合焦となると、上記の合焦判定がなされた時の動
作と同様にしてステツプ22へ移行する。
Therefore, the first switch SW 1 in depth mode
When the lens is driven by the ON operation, the lens moves until it is in focus on the subject, and once it is in focus, it moves to step 22 in the same way as the operation when the above focus judgment is made. do.

又、上記の焦点検出不能時も上記の如くAF制
御サブルーチンが繰り返されるので、焦点検出不
能状態を脱した場合にはレンズが合焦位置まで駆
動され、その後ステツプは22へ進むこととなる。
Furthermore, since the AF control subroutine is repeated as described above even when the focus cannot be detected, when the focus is no longer detected, the lens is driven to the in-focus position, and then the process proceeds to step 22.

以上、デイプスモードで初回のスイツチSW1
オン時のデイプス処理動作をまとめると被写体に
対して一度合焦状態となし合焦後ステツプ22へ移
行する。
To summarize the depth processing operation when the switch SW 1 is turned on for the first time in the depth mode, the subject is once brought into focus and then the process moves to step 22 after the object is out of focus.

以上の如くして被写体に対して合焦状態とした
後ステツプ22へ移行すると、該ステツプにてフラ
ツグDEP1のセツト状態が判定される。フラツグ
DEP1は前述の如く1にセツトされているにで、
ステツプは23に移行する。
After bringing the subject into focus as described above, the process moves to step 22, where the set state of the flag DEP 1 is determined. Flagg
Since DEP 1 is set to 1 as mentioned above,
The step moves to 23.

ステツプ23:DEP1表示を行う。 Step 23: Display DEP 1 .

この表示はコンピユーターPRSにて信号
CDDRをHとなし、回路DDRを指定し、SO信号
としてのDEP1表示信号を回路DDRに伝え、該回
路DDRにて表示器のDSP内のクセグメントにて
DEP1表示を行わせる。これにて撮影者は1回目
のデイプス処理が終了したことを知らせしめるこ
ととなる。
This display is signaled by computer PRS.
Set CDDR to H, specify the circuit DDR, transmit the DEP 1 display signal as an SO signal to the circuit DDR, and use the circuit DDR to send the signal to the segment in the DSP of the display.
Display DEP 1 . This will notify the photographer that the first depth process has been completed.

この後ステツプは24へ移行し、フラツグDEP1
に0をセツトし、DEP2に1をセツトし、その後
ステツプ25にてフラツグDEPOKを1にセツト
し、再度ステツプ9へ移行する。
After this, the step moves to 24, and the flag DEP 1
is set to 0, DEP 2 is set to 1, then the flag DEPOK is set to 1 in step 25, and the process returns to step 9.

この後スイツチSW1がオン状態に保持されてい
ればステツプは17→18→19→21へ移行する。この
時フラツグDEPOKはステツプ25にて1にセツト
されているので、ステツプ21の後再度ステツプ9
へ移行する。従つて1回目のデイプス処理終了後
スイツチSW1がオンの限りステツプ9→17→18→
19→21が繰り返され、レンズは最初に合焦した位
置に保持され続ける。この状態からシヤツタボタ
ンの操作を解除してスイツチSW1をオフとする
と、上記ステツプ9→17→18→19→21の繰り返し
に変えてステツプは12以後へ移行する。ステツプ
12以後の処理は上述の如くフラツグDEPJF,
DEPOKに0をセツトすると共にモードがデイプ
スに保持されているか、又は1回目のデイプス処
理終了後スイツチSW1がオフとなつてから所定時
間経過したかの判別がなされ、モードが通常モー
ドに戻された場合又は所定時間経過するまでスイ
ツチSW1をオフのままにした場合にはステツプ16
を介してステツプ1へ戻り、デイプスモードがキ
ヤンセルされる。
After this, if the switch SW 1 is kept in the on state, the steps shift from 17 to 18 to 19 to 21. At this time, the flag DEPOK was set to 1 in step 25, so after step 21, step 9 is executed again.
Move to. Therefore, as long as switch SW 1 is on after the first depth processing is completed, steps 9 → 17 → 18 →
Steps 19→21 are repeated, and the lens continues to be held at the initially focused position. When the shutter button is released from this state and switch SW 1 is turned off, steps 9→17→18→19→21 are repeated and the steps proceed from step 12 onwards. step
Processing after 12 is as described above, flag DEPJF,
DEPOK is set to 0, and it is determined whether the mode is held at depth or whether a predetermined time has elapsed since switch SW 1 was turned off after the first depth processing, and the mode is returned to normal mode. or if switch SW 1 is left off until the predetermined time has elapsed, proceed to step 16.
The process returns to step 1 via , and the depth mode is canceled.

又、モードをデイプスに保持し、かつ上記時間
以内に再度レリーズボタンが操作されスイツチ
SW1がオンとなるとステツプは再度17へ移行し2
回目のデイプス処理が開始される。
Also, if the mode is held at depth and the release button is operated again within the above time, the switch will be released.
When SW 1 is turned on, the step moves to 17 again and goes to 2.
The second depth processing is started.

以下2回目のデイプス処理について説明する。 The second depth processing will be explained below.

上記の如くしてステツプ17へ移行し、測光サブ
ルーチンが実行され、ステツプ18にてタイマーが
リセツトされ時間計時を再開し、ステツプ19へ移
行する。この時点では上記スイツチSW1のオフの
間のステツプ13にてフラツグDEPJFが0にセツ
トされているため、ステツプ19に次いでステツプ
20のAF制御サブルーチンが実行される。
As described above, the process moves to step 17, where the photometry subroutine is executed, and at step 18, the timer is reset to restart time measurement, and the process moves to step 19. At this point, the flag DEPJF has been set to 0 in step 13 while switch SW 1 is off, so step 19 is followed by step 19.
Twenty AF control subroutines are executed.

該AFサブルーチンでは上述の如くステツプ200
が行われる。
In the AF subroutine, step 200 is performed as described above.
will be held.

この時点ではフラツグPRMVは0にセツトさ
れており、ステツプは200から201へ移行する。こ
の時フラツグDEPMVも0にセツトされているの
で、ステツプは204へ移行し、モードがデイプス
か否かの判定がなされ、今モードはデイプスに設
定されているので、ステツプは205へ移行する。
2回目のデイプス処理開始以前にフラツグDEP1
は上述の如くステツプ24にて0にセツトされてい
るため、ステツプは215へ移行する。
At this point, the flag PRMV is set to 0, and the step moves from 200 to 201. At this time, since the flag DEPMV is also set to 0, the step moves to 204, where it is determined whether the mode is depth, and since the mode is currently set to depth, the step moves to 205.
Flag DEP 1 before starting the second depth processing
is set to 0 in step 24 as described above, so the step moves to 215.

ステツプ215:フラツグDEP2のセツト状態を判
別する。この時フラツグDEP2は上記ステツプ24
にて1にセツトされているため、ステツプは第2
図eのステツプ216へ移行し、上述の焦点検出サ
ブルーチンを実行しデイプスモードにおける2回
目のスイツチSW1のオン時点での被写体に対する
焦点状態を判定する。
Step 215: Determine the set state of flag DEP 2 . At this time, flag DEP 2 is set to step 24 above.
The step is set to 1 in the second step.
The process moves to step 216 in FIG. e, and the above-described focus detection subroutine is executed to determine the focus state for the subject at the time when switch SW 1 is turned on for the second time in the depth mode.

この焦点状態の判定結果としてフラツグ
AFNGが1にセツトされている時、即ちコント
ラストが低く焦点検出不能の時にはステツプ217
にてこれが検知されステツプ218へ移行する。
A flag is displayed as a result of determining this focus state.
When AFNG is set to 1, that is, when the contrast is low and focus cannot be detected, step 217
This is detected and the process moves to step 218.

ステツプ218:NG表示サブルーチンを実行す
る。このサブルーチンは上記表示ルーチンと同様
にして焦点検出不能表示用LEDを点灯させた後
AF制御サブルーチンを終了する。
Step 218: Execute the NG display subroutine. This subroutine lights up the focus detection failure display LED in the same way as the display routine above.
End the AF control subroutine.

又、上記ステツプ216での焦点検出サブルーチ
ンにてフラツグAFNGが1にセツトされない場
合、即ちコントラストが十分あると判定された時
にはステツプ217に次いでステツプ219へ進む。
If the flag AFNG is not set to 1 in the focus detection subroutine in step 216, that is, if it is determined that the contrast is sufficient, the process advances to step 219 following step 217.

ステツプ219:上記焦点検出サブルーチンにて
求められたデフオーカス量DEFが一定値dcより
も大か否かの判定を行う。この判定結果として|
DEF|>dcの時には、上記ステツプ218へ移行し
焦点検出不能表示がなされAF制御サブルーチン
を終了する。
Step 219: It is determined whether the differential focus amount DEF obtained in the focus detection subroutine is greater than a constant value dc. As a result of this judgment |
When DEF |

従つて、2回目のデイプス処理において、コン
トラストが低いことの検知又はデフオーカス量が
大であることが検知された時には直ちにAF制御
サブルーチンを終了し再度ステツプ9へ移行す
る。
Therefore, in the second depth processing, when it is detected that the contrast is low or that the amount of defocus is large, the AF control subroutine is immediately terminated and the process returns to step 9.

この状態でスイツチSW1がオンのまま保持され
ていれば、ステツプは再度9→17→18→19→20へ
移行し以後上記の焦点検出結果が異なる結果とな
るまで、このステツプを繰り返され、焦点検出サ
ブルーチンにてコントラストが十分高いこと及び
デフオーカス量が|DEF|<dcであることの判
別がなされるとステツプ220へ移行する。
If switch SW 1 is kept on in this state, the steps will move from 9 to 17 to 18 to 19 to 20 again, and this step will be repeated until the above focus detection results are different. When it is determined in the focus detection subroutine that the contrast is sufficiently high and that the defocus amount is |DEF|<dc, the process moves to step 220.

尚、初回のステツプ216時における焦点検出結
果がコントラストが十分であり、かつ|DEF|
<dcであると判定された時には上記の焦点検出
動作を繰り返すことなく直ちにステツプ220へ移
行させる。
Note that the focus detection result at the first step 216 has sufficient contrast and |DEF|
When it is determined that <dc, the process immediately proceeds to step 220 without repeating the focus detection operation described above.

尚、2回目のデイプス処理において、デフオー
カス量が所定値よりも大の時にデイプス処理を進
ませない理由は、第1回目のデイプス処理におけ
る被写体と2回目の処理における被写体が極めて
離れている場合、両被写体共に合焦状態となる様
なデイプス処理自体精度良く行われず、実質上デ
イプスモードでの処理が不可能であるためであ
る。
The reason why depth processing is not advanced in the second depth processing when the defocus amount is larger than a predetermined value is that if the subject in the first depth processing and the subject in the second processing are extremely far apart, This is because depth processing in which both objects are brought into focus is not performed with high precision, and processing in depth mode is virtually impossible.

上記の如くしてステツプ220へ移行するとステ
ツプ220にてレンズの焦点距離情報がメモリー
LSTFLに入力される。
When the process moves to step 220 as described above, the focal length information of the lens is stored in the memory at step 220.
Input to LSTFL.

この焦点距離情報の入力処理としてはコンピユ
ーターPRSにて信号CLCMをHとなし、上述の
如く回路LCMを介して回路LPRSを指定し、該
回路内に格納されている焦点距離情報を読み出す
ことにて実行される。
To input this focal length information, set the signal CLCM to H in the computer PRS, specify the circuit LPRS via the circuit LCM as described above, and read out the focal length information stored in the circuit. executed.

尚、レンズがズームレンズの場合にはその設定
ズーム状態に応じた焦点距離情報が読み出される
こととなる。
Note that if the lens is a zoom lens, focal length information corresponding to its set zoom state will be read out.

この様にしてステツプ220にて焦点距離情報を
読み出した後ステツプ221へ移行する。
After reading the focal length information in step 220 in this manner, the process moves to step 221.

ステツプ221:算出されたデフオーカス量から
1回目及び2回目のデイプス処理が行われた時の
両被写体を共にピントが合つた状態とする絞り値
を求める。
Step 221: An aperture value that brings both subjects into focus when the first and second depth processing is performed is determined from the calculated amount of defocus.

即ち、第3図の如く、1回目のデイプス処理に
おける被写体Aに対してレンズをDEP1に位置さ
せた時合焦状態とすることが出来たとすると、1
回目のデイプス処理にてレンズはDEP1の位置へ
移行している。
That is, as shown in Fig. 3, if the lens can be brought into focus when the lens is positioned at DEP 1 for subject A in the first depth processing, then 1
During the second depth processing, the lens moved to the DEP 1 position.

この状態でレンズをDEP2の位置へ移行させた
時に合焦状態となる被写体Bに対して上記2回目
のデイプス処理を実行すると2回目のデイプス処
理時の被写体Bに対するレンズ位置DEP1からの
デフオーカスDEFが上記焦点検出動作にて検知
され、このデフオーカス量がレンズ位置DEP1
DEP2間のデフオーカス量となる。
In this state, if you perform the second depth processing on subject B, which will be in focus when the lens is moved to the DEP 2 position, the second depth processing will result in the defocus from lens position DEP 1 for subject B during the second depth processing. DEF is detected by the focus detection operation described above, and this amount of focus is determined as the lens position DEP 1 .
Defocus amount between DEP 2 .

本発明でのデイプス処理は上記の如く2つの異
なる被写体間のデフオーカス量を7/17に至近側に 内分する位置DEP3にレンズを移動させ、この位
置で、DEP3とDEP2間のデフオーカス量、即ち
|DEP|×7/17を最小錯乱円0.035mmで割つた値を 制御絞りとして採用している。詳述すると一般的
に上記の様にレンズをDEP1に位置させた時、合
焦となる被写体AとレンズをDEP2に位置させた
時合焦となる被写体Bが存在する場合、位置
DEP1とDEP2を内分する位置DEP3にレンズを移
行させ、レンズ移行後のレンズ位置DEP3を一方
の被写体に対する本来の合焦位置DEP1又はDEP2
との間のデフオーカス量DEF′を最小錯乱円で割
ることにて、レンズをDEP3に位置させたまま、
本来位置DEP1及びDEP2で合焦となる2つの被写
体A,B共にピントを合つた状態とする被写体深
度を満足する絞り値が得られる。
As described above, the depth processing in the present invention involves moving the lens to position DEP 3 , which internally divides the amount of defocus between two different subjects to 7/17 toward the closest side, and at this position, changing the amount of defocus between DEP 3 and DEP 2 . The value obtained by dividing the amount, that is, |DEP|×7/17 by the circle of least confusion 0.035 mm, is adopted as the control aperture. To explain in detail, in general, as mentioned above, if there is a subject A that will be in focus when the lens is positioned at DEP 1 and a subject B that will be in focus when the lens is positioned at DEP 2 , the position
Move the lens to the position DEP 3 that internally divides DEP 1 and DEP 2 , and change the lens position DEP 3 after the lens shift to the original focusing position DEP 1 or DEP 2 for one subject.
While keeping the lens at DEP 3 , by dividing the defocus amount DEF′ between the
An aperture value that satisfies the depth of field that brings the two subjects A and B into focus at their original positions DEP 1 and DEP 2 can be obtained.

従つて、本願では、この原理を利用して上記演
算にて|DEF|×7/17×1/0.035を行い、レンズを 上記DEP3に移行した時至近側の被写体DEP2を十
分にピント合つた状態とする絞りを求めている。
尚、この時の絞りは無限側の位置DEP1に対して
は深度内にカバーしていないが、通常レンズの特
性を考慮すると、無限側の被写体に対しては上記
深度が本来カバーしていなくとも十分にピントが
合つた状態となるため、本願では内分点(DEP3
を至近側に7/17の位置として設定している。
Therefore, in this application , using this principle, the above calculation is performed as |DEF | I'm looking for an aperture that creates a taut condition.
Note that the aperture at this time does not cover the depth for the position DEP 1 on the infinity side, but considering the characteristics of normal lenses, the above depth does not originally cover the subject on the infinity side. In this application, the internal division point (DEP 3 )
is set as the 7/17 position on the closest side.

この様にして両被写体を共にピントが合つた状
態とする絞り値|DEF|×7/17×1/0.035をステツ プ221に求め、これをメモリーLSTFNOに記憶さ
せステツプ222へ移行する。
In this way, the aperture value |DEF|×7/17×1/0.035 that brings both subjects into focus is determined in step 221, stored in the memory LSTFNO, and the process proceeds to step 222.

ステツプ222:上記ステツプ216での焦点検出サ
ブルーチン結果としてフラツグJFが1にセツト
されているか否かを判別する。
Step 222: It is determined whether flag JF is set to 1 as a result of the focus detection subroutine in step 216.

この結果フラツグJFが1にセツトされている
場合にはステツプ223へ移行しフラツグDEPJF,
DEP2JFに1をセツトし、AF制御サブルーチン
を終了する。
As a result, if the flag JF is set to 1, the process moves to step 223 and the flags DEPJF and
DEP 2 Set JF to 1 and end the AF control subroutine.

このステツプ222,223にて2回目のデイプス処
理でフラツグJFの1のセツトが検知される様な
被写体はデイプスの1回目の被写体とほぼ同一位
置にある被写体を2回目のデイプス処理の被写体
とした場合であり、その以外の場合はステツプ
223へ移行する。
In steps 222 and 223, for objects for which the setting of flag JF to 1 is detected in the second depth processing, the object in the second depth processing is set to approximately the same position as the subject in the first depth processing. , otherwise the step
Move to 223.

今、第1回目と2回目の被写体位置が異なつて
おり、ステツプ223へ移行したものとする。
It is now assumed that the subject positions in the first and second shots are different, and the process has proceeded to step 223.

このステツプ223は上記EP計算サブルーチンを
実行させるもので、これにより2回目のデイプス
処理における被写体までのデフオーカス量に応じ
たパルス数FPが求められステツプは224以後へ移
行する。
This step 223 executes the above EP calculation subroutine, whereby the number of pulses FP corresponding to the amount of defocus up to the subject in the second depth processing is determined, and the step moves on to steps 224 and thereafter.

ステツプ224:フラツグDEPMVに1をセツト
する。
Step 224: Set the flag DEPMV to 1.

ステツプ225:レンズの現在位置を表わすカウ
ント値FCNTを入力する。
Step 225: Input count value FCNT representing the current position of the lens.

上述の如く回路LPRSにはエンコーダーENCか
らのレンズ駆動量を表わすパルスを入力してお
り、レンズの駆動制御にあたつては、このパルス
をカウントし、上記の如くデフオーカス量に応じ
たパルス数FPと一致したか否かの検知を行つて
いる。よつて、上記エンコーダーENCからのパ
ルスは回路LPRSにてカウントされ、所定の値を
示しており、このカウント値がコンピユーター
PRSに現在のレンズ位置を表わすカウント値
FCNTとして入力される。又、この回路LPRSの
上記カウント値はコンピユーターPRSにて信号
CLCMをHとなすことにて上述した動作で回路
LPRSが指定され、この時のSD信号として上記
カウント値が要求され、該カウント値が信号SIと
してコンピユーターに入力されるものである。
As mentioned above, the circuit LPRS inputs pulses representing the lens drive amount from the encoder ENC, and when controlling the lens drive, these pulses are counted and the number of pulses FP is determined according to the defocus amount as described above. It is detected whether or not it matches. Therefore, the pulses from the encoder ENC are counted by the circuit LPRS and indicate a predetermined value, and this count value is sent to the computer.
Count value indicating the current lens position in PRS
Entered as FCNT. Also, the above count value of this circuit LPRS is sent as a signal by computer PRS.
By setting CLCM to H, the circuit operates as described above.
LPRS is designated, the above count value is requested as the SD signal at this time, and the count value is input to the computer as the signal SI.

ステツプ226:上記デフオーカス量に基づいて
上述のレンズ駆動サブルーチンと同様にしてレン
ズの合焦方向に駆動される。即ち、1回目のデイ
プス処理でのレンズ位置から、2回目のデイプス
処理で求められたデフオーカス分レンズ駆動され
る。
Step 226: The lens is driven in the focusing direction based on the above-mentioned defocus amount in the same manner as in the above-mentioned lens driving subroutine. That is, the lens is driven from the lens position in the first depth process by the amount of defocus determined in the second depth process.

ステツプ227:上記ステツプ223にて求められた
上記デフオーカス量に応じたパルス数FPをメモ
リーDEPFPに入力する。
Step 227: The number of pulses FP corresponding to the above-mentioned differential focus amount obtained in the above-mentioned step 223 is input into the memory DEPFP.

ステツプ228:レンズ駆動前に入力されたレン
ズの現在のカウント値FCNTと上記メモリーに
入力されたデフオーカス量に応じたパルス数FP
とを加算しメモリーSTLPOSに入力する。
Step 228: The current count value FCNT of the lens inputted before lens driving and the number of pulses FP according to the amount of defocus inputted to the above memory.
and input into memory STLPOS.

これにてメモリーSTLPOSにはレンズの移動
すべき位置情報が設定される。
With this, the position information to which the lens should be moved is set in the memory STLPOS.

即ち、第3図の如く、1回目のデイプス処理に
てレンズがDEP1の位置にあり、この時のカウン
ト値がN1であつたとする。そして、2回目のデ
イプス処理にてレンズを位置DEP2に移行させる
ことにて2回目のデイプス処理における被写体に
対して合焦とすることが出来る様な場合、DEP1
からDEP2までのレンズ駆動量FPが上記のステツ
プ223にて求められ、このパルス数FPとしてN2
が得られたとする。
That is, as shown in FIG. 3, assume that the lens is at the DEP 1 position in the first depth processing, and the count value at this time is N 1 . Then, in the case where it is possible to focus on the subject in the second depth processing by moving the lens to position DEP 2 in the second depth processing, DEP 1
The lens driving amount FP from DEP 2 to
Suppose that we obtain

この場合、上記メモリーSTLPOSにはN2+N1
が記憶される。この値N1+N2はレンズがDEP1
にある時の上記カウンター値N1に対してレンズ
がDEP1からDEP2へ移行した時のカウント値を示
し、レンズの移動すべき目的位置でのカウント値
となる。
In this case, the above memory STLPOS has N 2 + N 1
is memorized. This value N 1 + N 2 means that the lens has DEP 1
It shows the count value when the lens moves from DEP 1 to DEP 2 with respect to the counter value N 1 when it is at , and becomes the count value at the target position to which the lens should move.

以上のステツプ228を実行数AF制御サブルーチ
ンを終了しステツプ9へ戻る。
The above step 228 ends the execution number AF control subroutine and returns to step 9.

この状態でスイツチSW1がオンのまま保持され
ていればステツプ9に次いで17,18,19が行われ
る。この時上記2回目のデイプス処理時のAF制
御サブルーチンでの合焦判定がなされていないと
するとステツプは20へ移行し、AF制御サブルー
チンが再度実行される。
If switch SW 1 is kept on in this state, steps 17, 18, and 19 are performed after step 9. At this time, assuming that focus determination has not been made in the AF control subroutine during the second depth processing, the process moves to step 20, and the AF control subroutine is executed again.

この再度のAF制御サブルーチンにあたつては
フラツグPRMVが0にセツトされ、かつ前回の
AF制御サブルーチンのステツプ224にてフラツグ
DEPMVが1にセツトされているため、ステツプ
は200→201→229へ移行し上述のステツプ202と同
様にしてレンズが停止した否かの判定がなされレ
ンズが停止していない時にはリターンする。
In this second AF control subroutine, the flag PRMV is set to 0, and the previous AF control subroutine is set to 0.
Flagged at step 224 of the AF control subroutine
Since DEPMV is set to 1, the steps proceed from 200 to 201 to 229, and in the same manner as step 202 described above, it is determined whether the lens has stopped or not, and if the lens has not stopped, the process returns.

従つて、レンズが停止していない限り、上記ス
テツプ9→17→18→19→20(200→201→229)が繰
り返されレンズの停止が確認されることにてステ
ツプは230へ移行する。
Therefore, unless the lens has stopped, the steps 9→17→18→19→20 (200→201→229) are repeated, and when it is confirmed that the lens has stopped, the process moves to step 230.

ステツプ230:該ステツプは上記ステツプ225と
同様であり、2回目のデイプス処理後レンズが停
止した状態でのカウント値FCNTを入力する。
Step 230: This step is the same as step 225 above, and the count value FCNT is input when the lens is stopped after the second depth processing.

従つて、今、2回目のデイプス処理でのステツ
プ223にて求めたパルス数FPがN2であつたとす
ると、本来、エンコーダーENCからN2個のパル
スが送られるまでレンズが駆動されることとなる
ので、この状態でのカウント値はレンズ駆動前の
1回目のデイプス処理終了時のレンズ位置DEP1
(第3図)でのカウンターのカウント値をN1とす
るとN1+N2となる。このステツプ後ステツプは
231へ移行する。
Therefore, if the number of pulses FP found in step 223 in the second depth processing is N 2 , the lens would normally be driven until N 2 pulses are sent from the encoder ENC. Therefore, the count value in this state is the lens position DEP 1 at the end of the first depth processing before the lens is driven.
Letting the count value of the counter in (Fig. 3) be N 1 , it becomes N 1 +N 2 . The steps after this step are
Move to 231.

ステツプ231:ステツプ228で求めたメモリー
STLPOSに格納された値に対してステツプ230で
得られた現在のレンズ位置を表わすカウント値を
引く。上述の如くメモリーSTLPOSの値は1回
目のデイプス処理終了後に2回目のデイプス処理
にて求めたデフオーカス分レンズを駆動した時の
予定のレンズ位置を表わしており、上記の如く1
回目のデイプス処理終了時のカウント値をN1
し、その位置からのデフオーカス量に相応するパ
ルスがN2であつた時にはN1+N2となつている。
そして、上記減算結果としては本来上記デフオー
カス量分レンズ駆動がなされるとゼロとなる。
Step 231: Memory obtained in step 228
The count value representing the current lens position obtained in step 230 is subtracted from the value stored in STLPOS. As mentioned above, the value of the memory STLPOS represents the scheduled lens position when the lens is driven by the amount of defocus determined in the second depth processing after the first depth processing is completed.
Let the count value at the end of the depth processing for the second time be N1 , and when the pulse corresponding to the amount of defocus from that position is N2 , it becomes N1 + N2 .
The result of the subtraction becomes zero when the lens is driven by the amount of defocus.

ステツプ232:上記レンズ駆動不能信号の検知
を行う。この検知動作は上述のレンズ停止信号の
検知動作と同様に行われる。
Step 232: Detect the lens drive failure signal. This detection operation is performed in the same manner as the lens stop signal detection operation described above.

今、ステツプ232にてレンズが駆動不能で停止
したのではないと判定されたとするとステツプは
233へ移行する。
Now, if it is determined in step 232 that the lens has not stopped due to inability to drive, then the step is
Move to 233.

ステツプ233:上記ステツプ231にて求めた演算
結果の絶対値が4以上であるか否かの判定を行
う。上述の如くレンズが正確に2回目のデイプス
処理で求められたデフオーカス分駆動されていれ
ば、ステツプ231での演算結果はゼロとなるが、
上記デフオーカス分駆動されていない時、又はデ
フオーカス分駆動後モーターが停止してもイナシ
ヤー等にてレンズがオーバーランした時、その駆
動量が予定量よりも少なければ少ない程、又はオ
ーバーラン量が大きければ大きい程上記演算結果
が大となる。
Step 233: It is determined whether the absolute value of the calculation result obtained in step 231 is 4 or more. As mentioned above, if the lens is driven by the exact amount of focus determined in the second depth process, the calculation result in step 231 will be zero.
When the lens is not driven by the amount of the above-mentioned defocus, or when the lens overruns due to inertia even if the motor stops after being driven by the defocus amount, the smaller the amount of drive is than the planned amount, or the larger the amount of overrun. The larger the value, the larger the above calculation result becomes.

従つて、このステツプでは上記演算結果が4以
下の時にはデフオーカス量駆動され、ステツプ
228にて求めた予定のレンズ位置までレンズが駆
動されたものと見做し、ステツプ234,235にてフ
ラツグDEPMVに0を、又DEPJFに1をセツト
しAF制御サブルーチンを終了する。
Therefore, in this step, when the above calculation result is 4 or less, the differential focus amount is driven, and the step
It is assumed that the lens has been driven to the scheduled lens position determined in step 228, and the flag DEPMV is set to 0 and the flag DEPJF is set to 1 in steps 234 and 235, and the AF control subroutine is ended.

又、上記ステツプ233にてステツプ231での演算
結果が4以上の時には上記レンズ駆動にて、いま
だ予定のレンズ位置まで移行していないと見做し
ステツプ236にて再度レンズ駆動指示を行わせ、
レンズを駆動した後リターンしAF制御サブルー
チンを終了する。
Also, in step 233, if the calculation result in step 231 is 4 or more, it is assumed that the lens has not yet moved to the scheduled lens position, and the lens drive instruction is issued again in step 236.
After driving the lens, return and end the AF control subroutine.

今上記ステツプ233にて、いまだに予定のレン
ズ位置までレンズが駆動されていないと判定さ
れ、ステツプ236にてレンズの再駆動がなされた
後AF制御サブルーチンを終了、ステツプ9へ移
行したものとする。
Assume that it is determined in step 233 that the lens has not yet been driven to the expected lens position, and after the lens is driven again in step 236, the AF control subroutine is terminated and the process proceeds to step 9.

この時スイツチSW1がオン状態に保持されてい
るとすると再度ステツプ17→18→19→20(200→
201→229)がレンズが停止するまで実行され、レ
ンズ停止が確認されると上記ステツプ230→231→
232→233が再度実行される。従つて、再駆動の結
果ステツプ233にてステツプ231での演算結果が4
以下となり、ステツプ228にて求めた予定位置ま
でレンズが移行していると判定された時にはステ
ツプ234,235が実行され、それ以外の場合は上記
の動作がステツプ233にてレンズがステツプ228に
て求めた予定位置まで移動したとの判定がなされ
るまで繰り返し実行される。従つて、これらのス
テツプ200→201→229→230→231→232→233→236
にてレンズを確実に2回目のデイプス処理にて求
めた予定のレンズ移行位置まで移行させることが
保証されることとなる。上記の動作はレンズがス
テツプ232にて駆動不能状態となつていないと判
定された場合の動作であるが、ステツプ232にて
レンズが例えば無限位置等の限界位置に移行して
レンズ駆動が不能状態となつていると判定された
場合にはステツプ232に次いでステツプ237が実行
される。
At this time, if switch SW 1 is held in the on state, steps 17→18→19→20 (200→
Steps 201→229) are executed until the lens stops, and once the lens stops, the above steps 230→231→
232→233 is executed again. Therefore, in step 233 as a result of re-driving, the calculation result in step 231 is 4.
If it is determined that the lens has moved to the scheduled position determined in step 228, steps 234 and 235 are executed; otherwise, the above operation is performed in step 233, and the lens is moved to the scheduled position determined in step 228. This process is repeated until it is determined that the process has moved to the calculated scheduled position. Therefore, these steps 200→201→229→230→231→232→233→236
This ensures that the lens is reliably moved to the scheduled lens transfer position determined in the second depth process. The above operation is an operation when it is determined in step 232 that the lens is not in a drive-incapable state, but in step 232, the lens has moved to a limit position such as the infinite position, and the lens drive has become disabled. If it is determined that this is the case, step 237 is executed following step 232.

ステツプ237:このステツプではレンズが無限
端位置に突き当たつてレンズ駆動不能となつたか
否かを判定するステツプである。
Step 237: In this step, it is determined whether the lens has hit the infinite end position and the lens cannot be driven.

上記判定方法としては、上記の如くデフオーカ
ス量DEFはレンズの駆動方向情報をも含んでい
るため、DEFに基づいて算出される上記パルス
数FPにもその駆動方向を表わす情報として例え
ば正負の符号が付されており、この符号を該ステ
ツプで検知することにてレンズが無限側へ駆動中
であつたか否かの判定を行つている。
As for the above judgment method, since the defocus amount DEF also includes lens drive direction information as mentioned above, the above pulse number FP calculated based on DEF also has a positive or negative sign as information representing the drive direction. By detecting this code at the step, it is determined whether the lens is being driven toward infinity.

このステツプにてレンズが無限方向に駆動中駆
動不能状態となつた時、即無限端に突き当つてレ
ンズが停止したと判定された時にはステツプは
234へ移行、以後上記レンズ駆動が正しく行われ
た場合と同様に処理される。
In this step, when the lens becomes unable to drive while being driven in the infinity direction, and it is judged that the lens has stopped immediately after hitting the infinity end, the step is stopped.
The process moves to step 234, and thereafter the process is performed in the same way as when the above lens driving is performed correctly.

又、ステツプ237にてレンズ駆動方向が至近側
であつたと判定された時、即ちレンズが至近端で
停止していると判定された時にはステツプ238に
てフラツグDEP1に1をDEP2,DEP3,DEPDN
に0をセツトし、ステツプ239にて表示器DSPに
てNG表示を行わせた後AFサブルーチンを終了
する。
Furthermore, when it is determined in step 237 that the lens driving direction is on the near side, that is, when it is determined that the lens is stopped at the close end, the flag DEP 1 is set to 1 in step 238. 3 , DEPDN
After setting 0 to 0 and displaying NG on the display device DSP in step 239, the AF subroutine is ended.

従つて、2回目のデイプス処理中でのレンズ駆
動でレンズが至近端に突き当たりレンズ駆動が不
能となつた時には、即ち、デイプス処理を行つて
も所望の撮影が行われない時にはそれ以上のデイ
プス処理を行わせず上記NG表示にて撮影者にデ
イプス処理が不能であることを知らせしめ撮影者
にデイプス処理を初回からやり直すことを指示す
る。
Therefore, if the lens hits the close end when driving the lens during the second depth processing and the lens cannot be driven, that is, if the desired image cannot be taken even after depth processing, the lens cannot be driven at a greater depth. The processing is not performed, and the above-mentioned NG display is displayed to inform the photographer that the depth processing is impossible, and to instruct the photographer to start the depth processing again from the first time.

尚、無限端でレンズが停止した状態において、
2回目のデイプス処理でのレンズ駆動が正常に行
われたと見做す理由としては、レンズにとつては
無限端以上の無限状態は存在せず、デイプス処理
を中止して、再度デイプス処理をやり直させても
それ以上の改善は望めないので、この場合にはレ
ンズの無限端での位置で合焦となる被写体が2回
目のデイプス処理時点での被写体と見做し、以後
のデイプス処理を続行させるためである。
In addition, when the lens is stopped at the infinite end,
The reason why the lens is considered to have been driven normally during the second depth processing is that there is no infinite state beyond the infinite edge for the lens, so the depth processing must be stopped and then repeated again. In this case, the subject that is in focus at the infinite end of the lens is considered to be the subject at the time of the second depth processing, and subsequent depth processing is continued. This is to make it happen.

又、以上の2回目のデイプス処理におけるレン
ズ駆動に際して、レンズを予定位置までサーボ
(クローズループ)制御する理由としては、本願
のデイプスモードでは、2回目のデイプス処理に
て求められたレンズ位置へ移行させた後この位置
から2回目のデイプス処理にて求められたデフオ
ーカス量を10/17×7/17に内分する位置を求め、レン ズを上記内分位置へ移行させる処理を行つている
ため2回目のデイプス処理でのレンズ位置を正確
な上記デフオーカス量だけ駆動しなければならな
いためである。
Furthermore, when driving the lens in the second depth processing, the reason why the lens is servo (closed loop) controlled to the predetermined position is that in the depth mode of the present application, the lens is moved to the position determined in the second depth processing. After that, from this position, we find a position to internally divide the defocus amount obtained in the second depth process into 10/17 x 7/17, and process to move the lens to the above internally divided position, so this is the second time. This is because the lens position in the depth processing must be driven by the exact amount of defocus described above.

又、この様に2回目のデイプス処理にてレンズ
をサーボ制御しているので2回目のデイプス処理
にてレンズを駆動中にスイツチSW1がオフとなつ
ても、常に正しいレンズ位置へレンズを移行させ
ることが出来る。即ち、2回目のデイプス処理に
おけるレンズ駆動中にスイツチSW1がオフとなる
とステツプが9から10へ移行し、その時点でレン
ズが停止する。又、この後スイツチSW1がオフの
間ステツプは9〜15を繰り返し、再度スイツチ
SW1をオンとするとステツプは7→17→18→19→
20へ移行する。この時フラツグDEPMVは1にセ
ツトされたまま保持されるので、再度のスイツチ
SW1のオンにてステツプ20へ移行し、AF制御サ
ブルーチンが実行された時にはステツプ200→201
→229→230へ移行し上述の処理が再開される。
尚、ステツプ10のレンズ停止命令によるレンズ停
止がなされた時にもレンズ停止信号が形成される
ものとする。よつて、スイツチSW1の再度のオン
後のステツプ230に進みこのステツプにてレンズ
の位置(SW1オフ時でのレンズ停止位置)を表わ
すカウント値がFCNTとして入力され、その位
置とステツプ228にて求めた予定位置との差分だ
け上記の如くしてレンズ移動がなされる。よつ
て、2回目のデイプス処理でのレンズ移動中に誤
つてスイツチSW1をオフとしても再度スイツチ
SW1をオンとなせば、予定位置までのレンズ駆動
処理が再開され、常に正しいレンズ位置にレンズ
が移行することとなる。
Also, since the lens is servo-controlled during the second depth processing, even if switch SW 1 is turned off while the lens is being driven during the second depth processing, the lens will always be moved to the correct lens position. I can do it. That is, when the switch SW 1 is turned off during lens driving in the second depth processing, the step shifts from step 9 to step 10, and at that point the lens stops. Also, after this, while switch SW 1 is off, repeat steps 9 to 15 and turn on the switch again.
When SW 1 is turned on, the steps are 7→17→18→19→
Move to 20. At this time, the flag DEPMV remains set to 1, so the switch is not activated again.
When SW 1 is turned on, the process moves to step 20, and when the AF control subroutine is executed, steps 200→201
→ 229 → 230 and the above-mentioned processing is restarted.
It is assumed that the lens stop signal is also generated when the lens is stopped by the lens stop command in step 10. Therefore, after switch SW 1 is turned on again, the process proceeds to step 230, where the count value representing the lens position (lens stop position when SW 1 is off) is input as FCNT, and that position and step 228 are entered. The lens is moved as described above by the difference from the planned position determined by the following steps. Therefore, even if you accidentally turn off switch SW 1 while moving the lens during the second depth processing, you will have to turn it off again.
When SW 1 is turned on, the lens driving process to the scheduled position is restarted, and the lens is always moved to the correct lens position.

以上の動作にてレンズが予定位置まで移行する
と上記の如くステツプ234,235を行つた後AFサ
ブルーチンを終了し、ステツプ9へ移行する。
When the lens moves to the expected position through the above operations, steps 234 and 235 are performed as described above, the AF subroutine is ended, and the process moves to step 9.

この状態でスイツチSW1がオンとなつていると
ステツプは9→17→18→19へ移行する。この時ス
テツプ235にてフラツグDEPJFに1がセツトされ
ているため、ステツプは19→21へ進み、又この時
フラツグDEPOKは0にセツトされているので、
ステツプは21から22へ進む。又、この時フラツグ
DEP1及びDEP2は2回目のデイプス処理移行時に
上述のステツプ24にてDEP1=0、DEP2=1にセ
ツトされているので、ステツプは22→26→27→28
へ進み、表示器DSPにて2回目のデイプス処理
が終了したことを示すDEP2表示を行い、DEP2
0を、又DEP3に1をセツトし、ステツプ25にて
フラツグDEPOKに1をセツト、再度ステツプ9
へ移行する。この状態でスイツチSW1がオンのま
ま保持されていれば以後ステツプ9→17→18→19
→21→9が繰り返されることとなり、レンズは2
回目のデイプス処理にて求められた位置に保持さ
れ、以上により2回目のデイプス処理を終了す
る。
If switch SW 1 is turned on in this state, the steps shift from 9 to 17 to 18 to 19. At this time, since the flag DEPJF is set to 1 in step 235, the step advances from 19 to 21, and since the flag DEPOK is set to 0 at this time,
Steps go from 21 to 22. Also, at this time flag
Since DEP 1 and DEP 2 are set to DEP 1 = 0 and DEP 2 = 1 in step 24 described above at the time of the second depth processing transition, the steps are 22 → 26 → 27 → 28.
Proceed to step 25, display DEP 2 on the display DSP to indicate that the second depth processing has been completed, set DEP 2 to 0, set DEP 3 to 1, and set the flag DEPOK to 1 in step 25. , step 9 again
Move to. If switch SW 1 is kept on in this state, then step 9 → 17 → 18 → 19
→21→9 will be repeated, and the lens will be 2
It is held at the position determined in the second depth process, and the second depth process is thus completed.

この後スイツチSW1をオフ後再度スイツチSW1
をオンとするとステツプは9→17→18→19へ移行
する。この時上記の如くスイツチSW1のオフが行
われているのでステツプ13での処理がなされてお
り、フラツグDEDJF,DEDOKは0にセツトさ
れている。従つて、ステツプは19→20へ移行し、
再度AF制御サブルーチンを実行する。
After this, turn off switch SW 1 and then turn switch SW 1 again.
When turned on, the steps shift from 9 to 17 to 18 to 19. At this time, since the switch SW 1 is turned off as described above, the process at step 13 is carried out, and the flags DEDJF and DEDOK are set to 0. Therefore, the step moves from 19 to 20,
Execute the AF control subroutine again.

尚、この時点では上記ステツプ234にてフラツ
グDEPMVに0がセツトされているのでAF制御
サブルーチンではステツプ200→201→204→205へ
移行する、又上記ステツプ24,28にてフラツグ
DEP1=0、DEP2=0、DEP3=1に設定されて
いるため、ステツプ205に次いでステツプ205→
240へ移行し、ステツプ240を実行する。
At this point, the flag DEPMV is set to 0 in step 234, so the AF control subroutine moves to steps 200→201→204→205, and the flag is set in steps 24 and 28.
Since DEP 1 = 0, DEP 2 = 0, and DEP 3 = 1, step 205 is followed by step 205→
Move to 240 and execute step 240.

ステツプ240:フラツグDEP2JFの状態を判定
する。このフラツグは上記2回目のデイプス処理
中にステツプ223が実行された時、即ち1回目と
2回目のデイプス処理時の被写体がほぼ同一位置
にある時のみ1にセツトされるものである。
Step 240: Determine the state of flag DEP2JF. This flag is set to 1 only when step 223 is executed during the second depth processing, that is, when the subject during the first and second depth processing is approximately at the same position.

従つて異なる位置の被写体に対する1回目と2
回目のデイプス処理がなされた場合にはステツプ
241へ移行する。
Therefore, the first and second shots for subjects in different positions
If the depth processing is done for the second time, the step
Move to 241.

今、ステツプは241へ移行したものとする。 It is assumed that the step has now moved to 241.

ステツプ241:ステツプ227にてメモリー
DEPFPに入力されたパルス数FP、即ち、2回目
のデイプス処理時に求めたレンズ移行位置までの
デフオーカス量に応じたパルス数と、上記ステツ
プ233〜235にてレンズを予定位置まで駆動した時
のステツプ231で求められたパルス数との減算を
行う。即ち、例えば第3図の如く1回目のデイプ
ス処理時のレンズ位置DEP1を表わすカウント値
をN1として2回目のデイプス処理時のデフオー
カス量に応じたパルス数FPをN2とすると、上記
ステツプ228にて求められた2回目のデイプス処
理で予定されるレンズ移行位置DEP2を表わすカ
ウント値はN1+N2となる。
Step 241: Memory at step 227
The number of pulses FP input to DEPFP, that is, the number of pulses corresponding to the amount of defocus to the lens transition position obtained during the second depth processing, and the step when the lens is driven to the planned position in steps 233 to 235 above. Perform subtraction with the number of pulses found in step 231. That is, for example, as shown in FIG. 3, if the count value representing the lens position DEP 1 during the first depth processing is N1 , and the number of pulses FP corresponding to the amount of defocus during the second depth processing is N2 , then the above steps are performed. The count value representing the lens transition position DEP 2 scheduled for the second depth processing determined in step 228 is N 1 +N 2 .

又、ステツプ230〜236では上記の如く該予定レ
ンズ位置とレンズの現在位置とが4パルス以内と
なるまで駆動されるので、2回目のデイプス処理
にて実際移行したレンズ位置DEP2を表わすカウ
ント値は第4図の如くN1+N2±α、4≧α≧−
4となり、予定レンズ位置と±α内の誤差を有す
る。
In addition, in steps 230 to 236, as described above, the lens is driven until the planned lens position and the current position of the lens are within 4 pulses, so the count value representing the actual lens position DEP 2 in the second depth processing is As shown in Figure 4, N 1 +N 2 ±α, 4≧α≧−
4, and has an error within ±α from the planned lens position.

そして、上記ステツプ231では予定位置(N1
N2)−レンズ移行位置(N1+N2±α)を行つて
おり、この±αが求められる。
Then, in step 231 above, the planned position (N 1 +
N 2 )−lens transition position (N 1 +N 2 ±α), and this ±α is obtained.

よつて、このステツプ241では1回目のデイプ
ス処理にて求めたデフオーカス量に応じたパルス
数N2と上記±αとの引き算を行つているので、
1回目のデイプス処理後のレンズ位置DEP1から
2回目のデイプス処理後の実際のレンズ位置との
間の実際のレンズ移動量N2±αが求められ、こ
れがメモリーDEP2FPに入力される。
Therefore, in this step 241, the number of pulses N2 corresponding to the amount of defocus obtained in the first depth processing is subtracted from the above ±α.
The actual lens movement amount N 2 ±α between the lens position DEP 1 after the first depth processing and the actual lens position after the second depth processing is determined, and this is input into the memory DEP 2 FP.

この様に実際のレンズ位置DEP1とDEP2間の間
隔を求めているため、上記の如く無限端でレンズ
が停止されている様な場合でも正確に実際のレン
ズ位置DEP1とDEP2間の移動量検知が出来ること
となる。
Since the distance between the actual lens positions DEP 1 and DEP 2 is calculated in this way, even if the lens is stopped at the infinite end as described above, the distance between the actual lens positions DEP 1 and DEP 2 can be accurately calculated. This allows the amount of movement to be detected.

該ステツプ241にてDEP1とDEP2のレンズ位置
の移動量を求めた後にステツプ242にて2回目の
デイプス処理において求めたDEP1からDEP2まで
のデフオーカス量DEFの符号判定を行う。上記
の如くデフオーカス量DEFはその駆動方向を表
わす情報も含んでおり、上記DEFの符号を判定
することに位置DEP1から位置DEP2へ移行する方
向の判定がなされる。尚、本実施例では正を至近
側への駆動方向を示す符号とし負を無限側への駆
動方向を示す符号とする。
After the amount of movement of the lens positions DEP 1 and DEP 2 is determined in step 241, the sign of the defocus amount DEF from DEP 1 to DEP 2 determined in the second depth processing is determined in step 242. As described above, the defocus amount DEF also includes information representing its driving direction, and the direction of movement from the position DEP 1 to the position DEP 2 is determined by determining the sign of the DEF. In this embodiment, a positive sign indicates the driving direction toward the closest side, and a negative sign indicates the driving direction toward the infinite side.

今レンズ位置が第4図に示した関係にあるとす
ると、レンズはDEP1からDEP2への移動時至近方
向に駆動されるので、デフオーカス量DEFが正
を示しており、この時にはステツプ243へ移行す
る。
Assuming that the lens positions are now in the relationship shown in FIG. 4, the lens is driven in the close-up direction when moving from DEP 1 to DEP 2 , so the defocus amount DEF is positive, and in this case, the process proceeds to step 243. Transition.

ステツプ243:上記ステツプ241に求めたDEP1
とDEP2間の移動量を表わすパルス数を−7/17に内 分するパルス数を求める。
Step 243: DEP 1 obtained in step 241 above
Find the number of pulses that internally divides the number of pulses representing the amount of movement between and DEP 2 into -7/17.

これにて第4図の如くDEP2からDEP3まで移動
量に相当するパルス数が求められる。
As a result, the number of pulses corresponding to the amount of movement from DEP 2 to DEP 3 is determined as shown in FIG.

又、ステツプ242にて無限方向への駆動であつ
たことが検知された時はステツプ243に代わつて
ステツプ244が実行される。
Further, when it is detected in step 242 that the drive is in the infinite direction, step 244 is executed instead of step 243.

斯様な状態ではDEP1とDEP2の関係は第5図の
通りである。
In such a state, the relationship between DEP 1 and DEP 2 is as shown in FIG.

従つてステツプ244ではDEP1とDEP2の間を10/17 に内分するパルス数を求め、このパルス数が
DEP2からDEP3までのレンズ移動量を表わすパル
ス数となる。
Therefore, in step 244, the number of pulses that divides the distance between DEP 1 and DEP 2 into 10/17 is determined, and this number of pulses is
This is the number of pulses representing the amount of lens movement from DEP 2 to DEP 3 .

この様にすることにてレンズの2回目のデイプ
ス処理にて至近又は無限のいずれの方向に駆動さ
れた場合でも至近側を7とし無限側を10に内分す
るレンズ位置DEP3へのDEP2から移動パルス数を
求めることが出来、上述の本願のレンズ位置
DEP3への移行が可能となる。
By doing this, in the second depth processing of the lens, when the lens is driven in either the near or infinity direction, the lens position DEP 3 will be set to DEP 3 , with the near side being 7 and the infinity side being divided into 10. The number of moving pulses can be calculated from the above lens position of the present application.
Migration to DEP 3 is now possible.

この様にステツプ243、又は244にて位置DEP2
からDEP3へ移行させるまでに必要なエンコーダ
ーからのパルス数を求めた後ステツプは224以後
へ進む。
In this way, in step 243 or 244 position DEP 2
After determining the number of pulses from the encoder necessary to shift from DEP 3 to DEP 3, the steps proceed to 224 and subsequent steps.

従つて、この後、上記2回目のデイプス処理時
のレンズ駆動と同様にしてレンズが上記ステツプ
243,244にて求められたパルス数だけDEP2の位
置から移動し上記位置DEP3へ移行するとステツ
プ234,235にてフラツグDEPMVに0が又
DEPJFに1がセツトされる。
Therefore, after this, the lens is driven in the above steps in the same way as the lens drive during the second depth processing.
After moving from the position DEP 2 by the number of pulses determined in steps 243 and 244 and moving to the above position DEP 3 , the flag DEPMV is set to 0 again in steps 234 and 235.
DEPJF is set to 1.

即ち、該第3回目のデイプス処理において実行
されるステツプ227ではメモリーDEPFPに上記ス
テツプ243,244にて求められた位置DEP2から
DEP3までの移動量パルス数であり、ステツプ228
ではDEP3のレンズ位置を表わすカウント値がメ
モリーSTLPOSに記憶されることとなる。
That is, in step 227 executed in the third depth processing, the data from the position DEP 2 obtained in steps 243 and 244 is stored in the memory DEPFP.
DEP is the number of movement pulses up to 3 , and is the number of pulses for step 228.
Then, the count value representing the lens position of DEP 3 will be stored in the memory STLPOS.

従つて、上記ステツプ244又は243を行つた後上
記の各ステツプ224〜228を実行し、ステツプ9へ
移行し、以後スイツチSW1がオンに保持されてい
る限り、上記2回目のデイプス処理のレンズ駆動
と同様のステツプ9→17→18→19→20(200→201
→229)又は20(200→201→229→230→231→232→
233→236)又は20(200→201→229→230→231→
232→237)が繰り返し実行されメモリー
STLPOSに記憶されたカウント値(DEP3の位
置)に対して±4以内のカウント位置となるまで
レンズが駆動され上記DEP3に対して±4パルス
範囲内の位置までレンズが移行すると上記の如く
ステツプ234,235にてフラツグDEPMVが0に
DEPJFが1にセツトされ3回目のデイプス処理
でのレンズ駆動を終了する。
Therefore, after performing step 244 or 243, each of the steps 224 to 228 described above is executed, and the process proceeds to step 9. From then on, as long as switch SW 1 is kept on, the lens of the second depth processing is applied. The same steps as driving 9→17→18→19→20 (200→201
→229) or 20 (200→201→229→230→231→232→
233→236) or 20(200→201→229→230→231→
232 → 237) is executed repeatedly and the memory is
The lens is driven until it reaches a count position within ±4 of the count value stored in STLPOS (position of DEP 3 ), and when the lens moves to a position within ±4 pulse range of DEP 3 , as shown above. Flag DEPMV becomes 0 at steps 234 and 235.
DEPJF is set to 1 and lens driving in the third depth process is completed.

尚、該3回目のデイプス処理時のレンズ駆動に
あつても予定レンズ位置までのサーボ(クロー
ズ)制御であり、レンズ駆動中にスイツチSW1
一度オフとしても、予定位置までレンズは駆動さ
れると共にレンズが至近側の限界位置まで移行し
て駆動不能となつた時には以後にデイプス処理を
進ませずにNG表示を行わせ、又、レンズが無限
位置で停止した時にはレンズをその位置に保持さ
せて以後のデイプス処理を行わせるものである。
Furthermore, even when the lens is driven during the third depth processing, servo (close) control is used to reach the scheduled lens position, and even if switch SW 1 is turned off once while the lens is being driven, the lens will still be driven to the scheduled position. At the same time, if the lens moves to the limit position on the close side and becomes unable to drive, the depth processing will not proceed and an NG display will be performed, and if the lens stops at the infinite position, the lens will be held at that position. This is used to perform the subsequent depth processing.

この様にして3回目のデイプス処理でのレンズ
駆動を終了した後ステツプは9→17→18→19と進
み、19にて上記フラツグDEPJFの1が検知され
ステツプは21以後に進み、フラツグDEPOK,
DEP1,DEP2,DEP3のセツト状態が検知される。
この時点ではフラツグDEPOK,DEP1,DEP2
0にセツトされDEP3が1にセツトされているた
め、ステツプ21→22→26→29→30に進む。ステツ
プ30ではフラツグDEP3に0をセツトし、
DEPDNに1をセツトし、その後ステツプ31へ進
み第2図fに示したDAV計算サブルーチンを実
行する。
After completing the lens driving in the third depth processing in this way, the steps progress from 9 to 17 to 18 to 19. At 19, the flag DEPJF of 1 is detected, and the step advances to 21 and thereafter, and the flags DEPOK,
The set state of DEP 1 , DEP 2 , and DEP 3 is detected.
At this point, flags DEPOK, DEP 1 and DEP 2 are set to 0 and DEP 3 is set to 1, so the process proceeds to steps 21→22→26→29→30. In step 30, set the flag DEP 3 to 0,
After setting DEPDN to 1, the program proceeds to step 31 and executes the DAV calculation subroutine shown in FIG. 2f.

該DAV計算サブルーチンではまずステツプ500
を実行する。
In the DAV calculation subroutine, step 500 is first executed.
Execute.

ステツプ500:レンズの焦点距離情報がメモリ
ーNWFLに入力される。この焦点距離情報の検
出は上述のステツプ220と同様にして行われる。
Step 500: Lens focal length information is entered into memory NWFL. Detection of this focal length information is performed in a manner similar to step 220 described above.

ステツプ501:ステツプ221にて求めた1回目デ
イプス処理時にレンズをDEP1へ移行することに
より合焦状態となる被写体A及び2回目のデイプ
ス処理時にレンズをDEP2へ移行することにて合
焦状態となる被写体B共にピントが合つた状態と
するための深度を保証する絞り値、即ち、ステツ
プ221にてメモリーLSTFNOに入力されている絞
り値(LSTFNOAVと称す。)と上記メモリー
LSTFLに記憶されている焦点距離情報(f1と称
す。)とメモリーNWFLに記憶されている焦点距
離情報(foと称す。)との演算LSTFNOAV×
(fo/f12を行い、これを制御絞りAVdepとする。
Step 501: Subject A is brought into focus by shifting the lens to DEP 1 during the first depth processing determined in step 221, and brought into focus by shifting the lens to DEP 2 during the second depth processing. The aperture value that guarantees the depth to bring both subject B into focus, that is, the aperture value input into the memory LSTFNO in step 221 (referred to as LSTFNOAV) and the memory mentioned above.
Calculation of focal length information (referred to as f 1 ) stored in LSTFL and focal length information (referred to as f o ) stored in memory NWFL LSTFNOAV×
(f o /f 1 ) 2 is performed and this is set as the control aperture AVdep.

この演算は上記デイプス処理中にレンズのズー
ム比を可変し焦点距離情報が変化しても両被写体
共にピントが合つた状態とする深度の絞りを供給
出来る様にするためである。
This calculation is performed in order to be able to supply an aperture with a depth that keeps both objects in focus even if the zoom ratio of the lens is varied during the depth processing and the focal length information changes.

上記絞り値LSTFNOAVは焦点距離がf1の時の
デフオーカス量に基づいて求めた値である一方、
デフオーカス量は焦点距離との関係で焦点距離が
2倍となると4倍変化する特性を有する。
The above aperture value LSTFNOAV is a value determined based on the amount of defocus when the focal length is f1 ,
The amount of defocus has a characteristic that in relation to the focal length, it changes four times when the focal length doubles.

即ち焦点距離f1の状態でレンズ位置DEP1で焦
点検出した時のデフオーカス量がDEFだとする
と、この同一被写体を焦点距離2f1の状態で検出
した時のデフオーカス量としている4DEFとな
り、上記絞り値LSTFNOAVも焦点距離が2倍
変化すると4倍変化する。
In other words, if DEF is the amount of def focus when focus is detected at lens position DEP 1 with focal length f 1 , then 4DEF is the amount of def focus when this same subject is detected at focal length 2 f 1 , and the above aperture value LSTFNOAV Also, if the focal length changes by a factor of 2, it changes by a factor of 4.

従つて、上記絞り値LSTFNOAVを求めた時
の焦点距離と撮影時の焦点距離がズーム操作等に
よつて変化した時に、上記絞り値LSTFNOAV
で絞り制御を行つても両被写体ともにピントが合
つた状態での深度を保証出来なくなる。
Therefore, when the focal length at which the above-mentioned aperture value LSTFNOAV was calculated and the focal length at the time of shooting change due to zoom operation, etc., the above-mentioned aperture value LSTFNOAV
Even if you perform aperture control with , it is no longer possible to guarantee the depth of field when both subjects are in focus.

従つて本願ではLSTFNOAV×(fo/f12を制御絞 り値AVdepとなし、焦点距離がLSTFNOAVを
求めた時に比して2倍変化した時にその絞りを4
倍変化させ、ズーム操作によらず常に両被写体共
にピントが合つた状態を保証する絞り値を求めて
いる。
Therefore, in this application, LSTFNOAV×(f o /f 1 ) 2 is set as the control aperture value AVdep, and when the focal length changes twice compared to when calculating LSTFNOAV, the aperture is set to 4.
We are looking for an aperture value that guarantees that both subjects are always in focus, regardless of zoom operations.

このステツプ501に次いでステツプは502へ進
む。
After this step 501, the step proceeds to 502.

ステツプ502:このステツプではカメラに装着
しているレンズがズームレンズか固定焦点のレン
ズかの判別を行う。
Step 502: In this step, it is determined whether the lens attached to the camera is a zoom lens or a fixed focus lens.

この判別動作は上述の焦点距離情報のレンズか
らカメラへの伝達と同様にコンピユーターPRS
にて回路LPRSを指定し、該回路内のRAMに記
憶されているズームレンズ情報又は固定焦点レン
ズ情報を読み出しコンピユーターPRSに入力し
この入力情報に基づいて上記の判定がなされる。
尚、上記ズームレンズ又は固定焦点レンズ情報は
レンズごとに決めるため、ズームレンズには上記
ズームレンズ情報が、又固定焦点レンズには固定
焦点レンズ情報がレンズのRAMに記憶されてい
る。
This discrimination operation is performed by the computer PRS in the same way as the above-mentioned transmission of focal length information from the lens to the camera.
The circuit LPRS is designated at , and the zoom lens information or fixed focus lens information stored in the RAM in the circuit is read out and input to the computer PRS, and the above determination is made based on this input information.
Note that since the zoom lens or fixed focus lens information is determined for each lens, the zoom lens information is stored in the RAM of the lens for the zoom lens, and the fixed focus lens information for the fixed focus lens is stored in the RAM of the lens.

このステツプにて装着レンズがズームレンズで
あると判定された場合にはステツプ503が実行さ
れ上記絞り値AVdepに対して一定値AVZMが加算
され補正制御絞り値AVdep′が求められる。この
一定値AVZMを加算することにて絞り値としては
上記算出絞り値AVdepよりもすこし絞り込み側
の絞り値、即ちより深度の深い絞り値となる。
If it is determined in this step that the attached lens is a zoom lens, step 503 is executed and a constant value AV ZM is added to the aperture value AVdep to obtain a correction control aperture value AVdep'. By adding this constant value AV ZM , the aperture value becomes an aperture value that is slightly closer to the aperture value than the calculated aperture value AVdep, that is, an aperture value that has a deeper aperture depth.

この加算処理は上記算出絞り値AVdepに対す
る誤差を吸収させるためである。即ち、上記
AVdepを求めるにあたり、種々な誤差要因があ
つたとしても実際の制御絞りをより深度の深い絞
り値とすることにて上記誤差分の補正を行つてい
る。
This addition process is to absorb the error with respect to the calculated aperture value AVdep. That is, the above
In determining AVdep, even if there are various error factors, the above-mentioned error is corrected by setting the actual control aperture to a deeper aperture value.

又、ステツプ502にて固定焦点レンズが装着さ
れていると判定された場合にはステツプ503に代
わつてステツプ504が実行される。
Further, if it is determined in step 502 that a fixed focus lens is attached, step 504 is executed instead of step 503.

このステツプ504では上記絞り値AVdepに対し
て一定値AVSNGを加算し補正制御絞り値
AVdep′を求めている。この加算処理も上記ズー
ムレンズと同様な誤差補正が目的である。
In this step 504, a constant value AV SNG is added to the above aperture value AVdep to determine the correction control aperture value.
We are looking for AVdep′. This addition process also has the purpose of error correction similar to that of the zoom lens described above.

尚、一定値はAVSNG<AVZMの関係となつてお
る。この関係にAVSNG及びAVZMを設定した理由
はズームレンズの方が固定焦点レンズよりも多く
誤差要因を含むため、その補正量を大とするため
である。
Note that the constant value is in the relationship AV SNG < AV ZM . The reason why AV SNG and AV ZM are set in this relationship is that zoom lenses include more error factors than fixed focus lenses, so the amount of correction for them is increased.

上記のステツプにて補正制御絞りAVdep′を求
めた後にステツプは505へ移行する。
After determining the correction control aperture AVdep' in the above step, the step moves to 505.

ステツプ505: J≦(4・log AVdep′/log2 +1)<(J+1) ……(1) を満足する整数Jを求める。 Step 505: Find an integer J that satisfies J≦(4·log AVdep′/log 2 +1)<(J+1) (1).

Jはアペツクス値の2倍の値であり、このJを
求めることにてアペツクス値の1/2段精度のアペ
ツクス絞り値が得られる。
J is a value twice the apex value, and by determining this J, an apex aperture value with an accuracy of 1/2 stop of the apex value can be obtained.

即ち、上記(1)式は (21/4J-1≦AVdep′ <(21/4J ……(2) を変形した式であり、かつAVdep′に正確に対応
したJを求めるためには (21/4J=AVdep′ ……(3) にてJを求めれば良い。この場合Jは整数のみで
なく少数までも含んだ値となり、上記(2)式に基づ
いて(1)にてJを求めれば上記(3)式で求めたJの少
数部は切り上げられる。
In other words, the above formula (1) is a modified formula of (2 1/4 ) J-1 ≦AVdep′ < (2 1/4 ) J ……(2), and J that exactly corresponds to AVdep′ is To find it, J can be found using (2 1/4 ) J = AVdep′...(3). In this case, J is a value that includes not only integers but also decimals, and if J is calculated in (1) based on the above equation (2), the decimal part of J calculated using the above equation (3) will be rounded up.

従つて、式(1)にて求めた絞り値JはAVdep′の
アペツクス値の2倍の値で、かつ1/2段精度で切 り上げられた値となり、より絞り込み側の絞り値
を示し、このステツプ処理で更に誤差吸収用の補
正がなされる。この後ステツプは506へ移行しス
テツプ506で求めたJに対して2J/4なる演算処理し
アペツクス1/2段ごとの絞り値の実数に変換され る。
Therefore, the aperture value J obtained using formula (1) is twice the apex value of AVdep' and is rounded up with 1/2 stop precision, indicating the aperture value on the narrower side. Further correction for error absorption is performed in the step processing. Thereafter, the process proceeds to step 506, where the J obtained in step 506 is processed by 2 J/4 and converted into a real number of aperture value for each 1/2 stop apex.

尚ステツプ505での処理は上記の誤差吸収の目
的の他にカメラの絞りの機械的な制御段数に合わ
せるためであり、アペツクスの1/2段の絞り値を 求めているのでカメラの該機械的な制御段数とし
ては、1/8,1/4,1/3、等の1/2n段精度のも
のが使 用可能となる。
In addition to the purpose of the above-mentioned error absorption, the processing in step 505 is to match the mechanically controlled number of stages of the aperture of the camera, and since an aperture value of 1/2 stage of the apex is obtained, As the number of control stages, 1/2 n stage precision such as 1/8, 1/4, 1/3, etc. can be used.

上述の如くしてDAV計算サブルーチンを終了
するとステツプは32へ移行しDAV表示サブルー
チンを行なう。このサブルーチンは表示器DSP
にて上記DAV計算サブルーチンにて求めた絞り
の実数を表示するルーチンであり、その表示動作
は上述の如く表示動作と同様に行われる。
When the DAV calculation subroutine is completed as described above, the process moves to step 32 to perform the DAV display subroutine. This subroutine is
This is a routine for displaying the real number of apertures obtained in the DAV calculation subroutine described above, and the display operation is performed in the same way as the display operation as described above.

又、ステツプ32が行われるとステツプ33へ移行
しレリーズ動作を許容し、ステツプ25へ移行しフ
ラグDEPOKに1をセツトしステツプ9へ戻る。
従つて、この状態でスイツチSW1がオンのまま保
持されていれば、以後ステツプは9→17→18→19
→21を繰り返す。又、この状態でスイツチSW1
オフとなつてもステツプは9→10→12→14→15を
繰り返し、再度スイツチSW1がオンとなつても上
記ステツプ9→17→18→19→21が繰り返される。
従つて全てのデイプス処理が終了した後にスイツ
チSW1が誤まつてオフとなつてもデイプス処理結
果はそのまま維持されることとなる。
When step 32 is performed, the process moves to step 33 to permit the release operation, moves to step 25, sets the flag DEPOK to 1, and returns to step 9.
Therefore, if switch SW 1 is kept on in this state, the steps will be 9→17→18→19.
→Repeat step 21. Also, in this state, even if switch SW 1 is turned off, steps 9→10→12→14→15 are repeated, and even if switch SW 1 is turned on again, steps 9→17→18→19→21 are repeated. Repeated.
Therefore, even if the switch SW1 is accidentally turned off after all depth processing is completed, the depth processing results will be maintained as they are.

この状態でシヤツターボタンの第2段操作を行
うと、割込み処理にてステツプ3のAE制御サブ
ルーチンにおけるレリーズ動作処理がなされ、絞
りが上記演算にて求めた絞り値Jに応じた信号が
コンピユーターPRSのSO信号として回路LCMを
介して回路LPRSに伝わり、ステツプモーター
DMTRを駆動し、該モーターに連動する絞りが
上記Jに応じて絞り込まれかつシヤツターレリー
ズ動作がなされ、その際のシヤツター秒時がステ
ツプ17での測光値と上記Jで決定される絞り値に
基づき決定されたシヤツター値にて制御されるこ
ととなる。
When the second step of the shutter button is operated in this state, the release operation process in the AE control subroutine in step 3 is performed in the interrupt process, and the aperture signal is sent to the computer PRS according to the aperture value J determined by the above calculation. It is transmitted to the circuit LPRS through the circuit LCM as the SO signal of the step motor
The DMTR is driven, and the aperture linked to the motor is stopped down in accordance with J above, and the shutter release operation is performed. The shutter value will be controlled based on the shutter value determined based on the above.

以上の動作にてデイプスモードでは異なる位置
にある被写体間を至近側に7、無限側に10に内分
するピント位置にレンズを合わせ、かつその絞り
として両被写体ともにピントが合つた状態を保証
する深度の絞りにて撮影がなされることとなる。
With the above operation, in depth mode, the lens is set to a focus position that divides subjects at different positions into 7 on the close side and 10 on the infinity side, and the aperture is used to ensure that both subjects are in focus. Photographs will be taken at an aperture of .

尚、上記2回目及び3回目のデイプス処理にあ
つては2回目のデイプス処理で求めたデフオーカ
ス量に応じて決定されるパルス数に基づきレンズ
の実駆動量を求め、この実駆動量のよつてレンズ
を駆動しているので、デイプス中にズーム比を変
化させても、又レンズが無限端に突き当つた場合
でも、上述の如く両被写体の7/17の内分点にレン ズを正確に移行させることが出来ることとなる。
In addition, in the case of the second and third depth processing described above, the actual driving amount of the lens is determined based on the number of pulses determined according to the amount of defocus obtained in the second depth processing, and the method of this actual driving amount is calculated. Since the lens is driven, even if the zoom ratio changes during depth, or even if the lens hits the infinity end, the lens will accurately move to the 7/17 internal dividing point of both subjects as described above. This means that it is possible to do so.

又、デイプスモードでは3回目のデイプス処理
が終了するまでスイツチSW2のオンによるレリー
ズ動作への移行が禁止されており、これにてデイ
プスモード中に誤まつてレリーズボタンの第2段
操作を行つても以後のデイプス処理を実行するこ
とが出来、デイプスモードが終了するまでシヤツ
ターボタンを誤操作しても、そのモードの維持が
なされるものである。
In addition, in depth mode, transition to release operation by turning on switch SW 2 is prohibited until the third depth processing is completed, so even if you accidentally operate the second step of the release button while in depth mode. Subsequent depth processing can be executed, and even if the shutter button is erroneously operated until the depth mode ends, the mode is maintained.

又、実施例ではエンコーダーENCからのパル
スをカウントするカウンターは入力パルスをアツ
プ、ダウンカウントし常にレンズ駆動後のレンズ
位置を表わす値を示し、更にデフオーカス量のレ
ンズ駆動に際しては、レンズ駆動前のカウント値
からのカウント値の変化分がデフオーカス量に応
じた値となつたか否かの判定を行つてレンズ駆動
量をデフオーカス量となる様制御を行つている
が、その他の方法にてレンズ駆動量制御を行つて
も良い。
In addition, in the embodiment, the counter that counts the pulses from the encoder ENC counts up and down the input pulses, and always indicates the value representing the lens position after the lens is driven.Furthermore, when driving the lens by the amount of defocus, the counter counts the input pulses up and down, and when driving the lens by the amount of defocus, the counter counts the pulses before the lens is driven. Although the lens drive amount is controlled to be the defocus amount by determining whether the change in the count value from the value has reached a value corresponding to the defocus amount, other methods can be used to control the lens drive amount. You may do so.

又、レンズの無限端又は至近端位置への突き当
りを検知する方法とて各限界端にリミツトスイツ
チを設けても良い。
Further, a limit switch may be provided at each limit end as a method of detecting when the lens hits the infinite end or the closest end position.

又、2回目のデフオーカス量に基づいてレンズ
を駆動した際にレンズの限界端に突き当るか否か
の判定方法としては算出デフオーカス量と現在の
レンズ位置とレンズの限界端までの距離との比較
を行つても良い、この場合にはレンズの現在位置
情報として絶対値情報がレンズから検知される様
にする必要がある。
Also, a method for determining whether or not the lens will hit the limit edge when the lens is driven based on the second defocus amount is to compare the calculated defocus amount, the current lens position, and the distance to the lens limit edge. In this case, absolute value information must be detected from the lens as current position information of the lens.

〔効果〕〔effect〕

以上の如く本発明にあつては、2回目のデイプ
ス処理においてレンズが至近側に突き当つた状態
となつた時には以後のデイプス処理をキヤンセル
すると共に警告指示し、レンズが無限側に突き当
つた状態となつた時には通常のデイプス処理を許
容したものであるので、異なる被写体ともにピン
トが合つた状態とするデイプス処理に好適なカメ
ラを提供することが出来るものである。
As described above, in the present invention, when the lens hits the close side during the second depth processing, the subsequent depth processing is canceled and a warning is issued, and the state where the lens hits the infinity side is canceled. When this occurs, normal depth processing is allowed, so it is possible to provide a camera suitable for depth processing in which different subjects are brought into focus.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は、本発明のカメラの一実施例を示す回
路図、第2図a〜第2図fは第1図実施例のコン
ピユーターPRSに内蔵されるプログラムを示す
説明図、第3図、第4図、第5図は第1図実施例
の動作を説明するための説明図である。 PRS……コンピユーター、LRRS……制御回
路、LCM……バツフアー回路、DMTR……絞り
制御用モータ。
FIG. 1 is a circuit diagram showing an embodiment of the camera of the present invention, FIGS. 2a to 2f are explanatory diagrams showing programs built in the computer PRS of the embodiment of FIG. 1, and FIG. FIGS. 4 and 5 are explanatory diagrams for explaining the operation of the embodiment shown in FIG. PRS...computer, LRRS...control circuit, LCM...buffer circuit, DMTR...aperture control motor.

Claims (1)

【特許請求の範囲】[Claims] 1 第1の被写体に対して焦点検出回路にて焦点
検出を行なわせ、該焦点検出結果に応じてレンズ
をレンズ駆動回路により前記第1の被写体に対し
て合焦とする第1の位置まで移行させ、レンズが
該第1の位置に位置している状態で第2の被写体
に対して前記焦点検出回路にて焦点検出を行なわ
せ、該焦点検出結果に応じてレンズを前記レンズ
駆動回路により前記第2の被写体に対して合焦と
する第2の位置まで移行させるとともに、前記第
1の位置と第2の位置との間のレンズ移動量に相
応して第1の被写体と第2の被写体に対する焦点
状態がほぼ等しくなる中間位置を演算手段にて演
算し、レンズを前記中間位置へレンズ駆動回路に
より移行させるレンズ位置制御装置を備えるとと
もに、前記第1の位置から第2の位置へのレンズ
移行に際してレンズが前記第2の位置へ到達する
以前にレンズの至近端に到達したか否かを検知す
る検知手段と、該検知手段にて至近端への到達が
検知された際に第1と第2の被写体に対する焦点
状態をほぼ等しくすることが不可であると判定す
る判定手段を設けたことを特徴とするカメラ。
1. A focus detection circuit performs focus detection on a first object, and according to the focus detection result, a lens drive circuit moves the lens to a first position where the first object is in focus. the focus detection circuit performs focus detection on the second subject with the lens located at the first position, and the lens is moved by the lens drive circuit according to the focus detection result. The second subject is moved to a second position where the second subject is in focus, and the first subject and the second subject are moved in accordance with the amount of lens movement between the first position and the second position. a lens position control device for calculating an intermediate position where the focal states of the lenses are substantially equal to each other using a calculation means, and moving the lens to the intermediate position by a lens drive circuit, and moving the lens from the first position to the second position. a detection means for detecting whether or not the lens has reached the closest end before the lens reaches the second position during the transition; 1. A camera comprising a determination means for determining that it is impossible to make the focal states of the first and second subjects substantially equal.
JP62004572A 1987-01-12 1987-01-12 Camera with focusing device Granted JPS63172228A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP62004572A JPS63172228A (en) 1987-01-12 1987-01-12 Camera with focusing device
US07/141,713 US4792819A (en) 1987-01-12 1988-01-07 Camera having automatic focusing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62004572A JPS63172228A (en) 1987-01-12 1987-01-12 Camera with focusing device

Publications (2)

Publication Number Publication Date
JPS63172228A JPS63172228A (en) 1988-07-15
JPH0581006B2 true JPH0581006B2 (en) 1993-11-11

Family

ID=11587749

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62004572A Granted JPS63172228A (en) 1987-01-12 1987-01-12 Camera with focusing device

Country Status (1)

Country Link
JP (1) JPS63172228A (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101102631B1 (en) * 2010-06-18 2012-01-04 한국전력공사 Cable Tray Device

Also Published As

Publication number Publication date
JPS63172228A (en) 1988-07-15

Similar Documents

Publication Publication Date Title
JP2597961B2 (en) Automatic focusing device
JPH01285908A (en) Automatic focusing device for camera
JPH02254432A (en) Automatic focusing camera
US4792819A (en) Camera having automatic focusing device
JPH0617935B2 (en) Automatic focus adjustment device
US4801962A (en) Camera incorporating automatic focusing apparatus
US4792821A (en) Auto-focus apparatus in a camera
US4845521A (en) Camera with automatic focusing apparatus
JPH0581006B2 (en)
US4825238A (en) Focus detecting device
JP2832006B2 (en) Automatic focusing device
JP2974637B2 (en) Automatic focusing device
JPH05346536A (en) Focal point detecting device
US5053799A (en) Camera having auto-focusing device
JPH0731340B2 (en) Camera with focus adjustment device
JPS63172250A (en) Camera with focusing device
JPS63172231A (en) Auto-focusing device
JPS63172248A (en) Camera with auto-focusing device
JP2762513B2 (en) Automatic focusing device
JP3486464B2 (en) Automatic focusing device
JPH0478832A (en) Focus detecting device
JPS63172258A (en) Camera having focusing device
JPS63172224A (en) Auto-focusing device
JPH0760208B2 (en) camera
JP2941891B2 (en) Automatic focusing device

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees