JPH0382913A - Signal processing circuit for encoder - Google Patents

Signal processing circuit for encoder

Info

Publication number
JPH0382913A
JPH0382913A JP21990889A JP21990889A JPH0382913A JP H0382913 A JPH0382913 A JP H0382913A JP 21990889 A JP21990889 A JP 21990889A JP 21990889 A JP21990889 A JP 21990889A JP H0382913 A JPH0382913 A JP H0382913A
Authority
JP
Japan
Prior art keywords
signal
sine wave
encoder
generating
circuit
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.)
Pending
Application number
JP21990889A
Other languages
Japanese (ja)
Inventor
Katsuhiko Nakamura
勝彦 中村
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.)
Shinmaywa Industries Ltd
Original Assignee
Shin Meiva Industry Ltd
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 Shin Meiva Industry Ltd filed Critical Shin Meiva Industry Ltd
Priority to JP21990889A priority Critical patent/JPH0382913A/en
Publication of JPH0382913A publication Critical patent/JPH0382913A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To make it possible to detect a position highly accurately by providing a reference sine-wave-signal generating means, a correcting-data generating means, a correcting means, a multiplying means and a detecting means. CONSTITUTION:Mainly, an up/down counter 45 and a ROM 42 constitute a reference sine-wave-signal generating means. A RAM 49 constitutes a correcting- data generating means. An adding circuit 50 constitutes a correcting means. Furthermore, multiplying circuits 41a and 41b constitute a multiplying means. A subtracting circuit 43, a comparator 44, a zero-cross-pulse generating circuit 46, a latch circuit 47 and the like constitute a detecting means. The relative position of a movable part is detected based on a correction reference signal obtained by correcting a reference sine wave signal. Therefore, the relative position of the movable part can be accurately obtained even if the sine wave signal from an encoder is deviated from an accurate sine wave. The correcting signal data means generates the correction data in response to a temporary position when the deviating amount is changed in response to the value of the relative position and in response to the second parameter when the deviating amount is changed in response to the second parameter.

Description

【発明の詳細な説明】 (産業上の利用分野) この発明は、位置検出装置としてのエンコーダの信号処
理回路に関する。
DETAILED DESCRIPTION OF THE INVENTION (Field of Industrial Application) The present invention relates to a signal processing circuit for an encoder as a position detection device.

(従来の技術) 位置検出装置としてのエンコーダには、いわゆるレゾル
バや特開昭62−8015号公報に開示されているエン
コーダなどのように、正弦波2相出力信号が得られるタ
イプがある。このようなタイプのエンコーダは、2つの
正弦波信号の値の紹合せに従って位置の検出を行なうの
で、原理的に高精度な位置検出を行えるという利点があ
る。
(Prior Art) Encoders used as position detection devices include types that can obtain a sine wave two-phase output signal, such as a so-called resolver and an encoder disclosed in Japanese Patent Application Laid-Open No. 62-8015. Since this type of encoder detects the position according to the introduction of the values of two sine wave signals, it has the advantage of being able to perform highly accurate position detection in principle.

(発明が解決しようとする課題) しかし、エンコーダから出力される2相の正弦波信号は
正確な正弦波ではなく、誤差を含むのが一般的である。
(Problem to be Solved by the Invention) However, the two-phase sine wave signal output from the encoder is not a precise sine wave and generally includes errors.

例えばエンコーダの機械的構造に起因した誤差は、ロー
タリーエンコーダの同一回転位置で必ず発生ずる。また
、このような誤差はエンコーダの環境温度によっても変
化することがある。従来は、このようにエンコーダの正
弦波2相出力信号が誤差を含んでいたため、現実に高精
づ 度な位置検出を行うことが困難であった。
For example, errors caused by the mechanical structure of the encoder always occur at the same rotational position of the rotary encoder. Furthermore, such errors may also change depending on the environmental temperature of the encoder. Conventionally, since the sine wave two-phase output signal of the encoder contained errors in this way, it was difficult to actually perform highly accurate position detection.

(発明の目的) この発明は、従来技術における上述の課題を解決するた
めになされたものであり、高精度な位置検出を行うこと
ができるエンコーダの信号処理回路を意提供することを
目的とする。
(Object of the Invention) The present invention was made to solve the above-mentioned problems in the prior art, and its purpose is to provide a signal processing circuit for an encoder that can perform highly accurate position detection. .

(課題を解決するための手段) 上述の課題を解決するため、この発明の第1の構成では
、所定の可動部に取付けられたエンコーダから、固定部
に対する前記可動部の相対位置を位相変数として含むよ
うな異相の第1と第2の正弦波信号を受けて、前記相対
位置を検出するためのエンコーダの信号処理回路であっ
て、次の各手段を備えている。
(Means for Solving the Problem) In order to solve the above-mentioned problem, in a first configuration of the present invention, the relative position of the movable part with respect to the fixed part is detected as a phase variable from an encoder attached to a predetermined movable part. A signal processing circuit of an encoder for detecting the relative position by receiving first and second sine wave signals of different phases, which include the following:

■ 可変パラメータとしての仮位置を経時的に変化させ
つつ、当該仮位置を位相変数とした理想的正弦波波形を
有する信号として、異相の第1と第2の基準正弦波信号
を発生する基準正弦波信号生成手段。
■ A reference sine waveform that generates first and second reference sine wave signals of different phases as signals having an ideal sine wave waveform with the temporary position as a phase variable while changing the temporary position as a variable parameter over time. Wave signal generation means.

■ 前記相対位置に応じて変化する前記第1と第2の正
弦波信号の理想的正弦波波形からのズレに基づいて予め
求められた第1と第2の補正データを、前記仮位置に応
じて記憶しており、前記仮位置に応じて第1と第2の補
正データをそれぞれ発生する補正データ発生手段。
(i) The first and second correction data, which are obtained in advance based on the deviation from the ideal sine wave waveform of the first and second sine wave signals that change depending on the relative position, are adjusted according to the temporary position. correction data generating means for storing first and second correction data in accordance with the temporary position;

■ 前記第1と第2の基準正弦波信号をそれぞれ前記第
1と第2の補正データで補正することにより、第1と第
2の補正基準信号を生成する補正手段。
(2) A correction means for generating first and second corrected reference signals by correcting the first and second reference sine wave signals with the first and second correction data, respectively.

■ 前記第1と第2の補正基準信号をそれぞれ前記第1
と第2の正弦波信号と乗算することにより、第1と第2
の乗算信号を生成する乗算手段。
■ The first and second correction reference signals are respectively
By multiplying by the second sine wave signal, the first and second
multiplication means for producing a multiplied signal.

■ 前記第1と第2の乗算信号の差分を求め、当該差分
が所定の基準差分値に等しいときに、前記仮位置を前記
相対位置の検出値として発生する検出手段。
(2) Detection means that calculates a difference between the first and second multiplied signals and generates the temporary position as a detected value of the relative position when the difference is equal to a predetermined reference difference value.

この発明の第2の構成では、第1の構成における■補正
データ発生手段のかわりに、 ■′第2のパラメータに応じて変化する前記第1と第2
の正弦波信号の理想的正弦波波形からのズレに基づいて
予め求められた第1と第2の補正データを、前記第2の
パラメータに応じて記憶しており、前記第2のパラメー
タに応じて第1と第2の補正データをそれぞれ発生する
補正データ発生手段 を備えている。
In the second configuration of the present invention, instead of the correction data generating means in the first configuration,
first and second correction data obtained in advance based on the deviation of the sine wave signal from the ideal sine wave waveform are stored according to the second parameter, and the first and second correction data are stored according to the second parameter. and a correction data generating means for generating first and second correction data respectively.

なお、この実施例における「位置」とは、直線軸上の位
置のみでなく、回転軸まわりの回転角なとも含む用語で
ある。また、「正弦波」とは、sinθで表わされる狭
義の正弦波のみでなく、これと位相のずれた余弦波など
も含む広い意味の用語である。
Note that the term "position" in this embodiment includes not only a position on a linear axis but also a rotation angle around a rotation axis. Furthermore, the term "sine wave" is a term in a broad sense that includes not only a sine wave in the narrow sense represented by sin θ, but also a cosine wave whose phase is shifted from the sine wave.

(作用) 基準正弦波信号を補正した補正基準信号に基づいて可動
部の相対位置を検出するので、エンコーダからの正弦波
信号が正確な正弦波からずれている場合にも、可動部の
相対位置を正確に求めることができる。
(Function) The relative position of the movable part is detected based on the corrected reference signal obtained by correcting the reference sine wave signal, so even if the sine wave signal from the encoder deviates from an accurate sine wave, the relative position of the movable part is detected. can be determined accurately.

エンコーダからの正弦波信号が理想的正弦波からずれて
いるズレ量が相対位置の値に応じて変化する場合には、
補正信号データ手段は低位置に応じて補正データを発生
すればよい。
If the amount of deviation of the sine wave signal from the encoder from the ideal sine wave changes depending on the relative position value,
The correction signal data means may generate correction data depending on the low position.

また、前記ズレ量が第2パラメータに応じて変化する場
合には、補正データ発生手段は当該第2のパラメータに
応じて補正データを発生すればよい。
Moreover, when the amount of deviation changes according to the second parameter, the correction data generating means may generate the correction data according to the second parameter.

(実施例) A、装置の全体構成 第1図は、本発明の一実施例を適用した制御システムの
構成を示すブロック図である。この制御システムは、第
1のエンコーダ10と、第2のエンコーダ20と、第1
のエンコーダ用の第]の信号処理回路30と、第2のエ
ンコーダ用の第2の信号処理回路40と、制御装置60
と、スイッチ回路70とを備えている。
(Embodiment) A. Overall configuration of the apparatus FIG. 1 is a block diagram showing the configuration of a control system to which an embodiment of the present invention is applied. This control system includes a first encoder 10, a second encoder 20, and a first
a second signal processing circuit 30 for the encoder, a second signal processing circuit 40 for the second encoder, and a control device 60.
and a switch circuit 70.

第1と第2のエンコーダ10.20は、同一の回転軸α
のまわりにそれぞれ設置されたロータリーエンコーダで
ある。第1のエンコーダ10は、前記の回転軸αの1回
転が1周期に相当する正弦波出力信号e   e  を
発生する。一方、第2のLA’  IB エンコーダ20は、前記の回転軸αの1回転がN周期(
Nは数十〜数百程度の整数)に相当する正弦波出力信号
e2A”2Bを発生する。第2図に、これらの正弦波出
力信号CIA’  lB、e2A’  e2Bを示して
おり、第1の正弦波出力信号e   e1^’  2A と第2の正弦波出力信号e  、e  とは位相が91
.8    2B O°異なっている。第1の信号処理回路3oは、第1の
エンコーダ10からの正弦波出力信号CIA’e1Bを
受取ってこれを処理し、前記回転軸αの絶対位置として
の第1の回転角θ1を発生する。
The first and second encoders 10.20 have the same rotation axis α
Rotary encoders are installed around each. The first encoder 10 generates a sinusoidal output signal e e in which one rotation of the rotation axis α corresponds to one period. On the other hand, in the second LA' IB encoder 20, one rotation of the rotation axis α has N periods (
(N is an integer from tens to hundreds). FIG. 2 shows these sine wave output signals CIA' IB, e2A' e2B, and The phase of the sine wave output signal e e1^' 2A and the second sine wave output signal e and e is 91
.. 8 2B O° different. The first signal processing circuit 3o receives the sinusoidal output signal CIA'e1B from the first encoder 10, processes it, and generates a first rotation angle θ1 as the absolute position of the rotation axis α.

方、第2の信号処理回路40は、第2のエンコーダ20
からの正弦波出力信号e   e  および第2八″ 
2B 1の信号処理回路30からの第1の回転角θ1の検出値
などを受取って、第2の回転角θ2の検出値を発生する
。第2の回転角θ2は、前記回転軸αの1回転をN等分
した角度を一周期(2πラジアン)として、何ラジアン
であるかを示す値である。第1と第2の回転角θ 、θ
2は制御装置6Oに与えられ、前記回転軸αの図示しな
い駆動装置が制御装置60によって制御される。
On the other hand, the second signal processing circuit 40
The sinusoidal output signal from e and the 28th"
It receives the detected value of the first rotation angle θ1 from the signal processing circuit 30 of 2B1 and generates the detected value of the second rotation angle θ2. The second rotation angle θ2 is a value indicating how many radians is one period (2π radians), which is an angle obtained by dividing one rotation of the rotation axis α into N equal parts. First and second rotation angles θ, θ
2 is given to a control device 6O, and a drive device (not shown) for the rotation axis α is controlled by the control device 60.

なお、第1の信号処理回路30は従来から使用されてい
る回路であり、第2の信号処理回路40にこの発明が適
用されている。
Note that the first signal processing circuit 30 is a conventionally used circuit, and the present invention is applied to the second signal processing circuit 40.

B、第1の信号処理回路の構成と動作 第1−の信号処理回路30における信号処即の原理は次
の通りである。
B. Configuration and operation of the first signal processing circuit The principle of signal processing in the first signal processing circuit 30 is as follows.

第1のエンコーダ10の2相出力信号e1AeLBは、
次のように表わされる。
The two-phase output signal e1AeLB of the first encoder 10 is
It is expressed as follows.

e  =k    sinθ1・(1,)1、A   
  l e  =k    cosθt−(2)IB     
L ここで、 k :定数 θ1 :回転軸αの回転角 一方、信号処理回路30内で別の2つの基準正弦波si
nφ 、  COSφ(を発生させて、」1記の2相出
力信号e   e  と次のような乗算を行なう。
e = k sinθ1・(1,)1, A
le = k cos θt-(2) IB
L Here, k: Constant θ1: Rotation angle of rotation axis α Meanwhile, within the signal processing circuit 30, two other reference sine waves si
nφ and COSφ( are generated, and the following multiplication is performed with the two-phase output signal e e described in 1).

IA″  (B E−e  ・ cosφI IA   IA = k    sinθ   cosφ  =・(3)
L     1     1 E  =e    sinφI LB   IB −Ic    cosθ l51nφ  −=(4)i
     t      t さらに、2つの乗算結果E  、E  間の差ΔE11
、A     ID を求める。
IA'' (B E-e ・ cosφI IA IA = k sinθ cosφ =・(3)
L 1 1 E =e sinφI LB IB −Ic cosθ l51nφ −=(4)i
t t Furthermore, the difference ΔE11 between the two multiplication results E and E
, find A ID.

ΔE1.””EIA−01B = k    sin (θ −φi)・・・(5)1 (5)式において、ΔE1−0となるような角度φ1を
求めると、次のようになる。
ΔE1. ``''EIA-01B = k sin (θ - φi)... (5) 1 In equation (5), if the angle φ1 that makes ΔE1-0 is found, the following is obtained.

φ1−01             ・・・(6a)
又は φ(鴫θt+π         ・・・(6b
)但し、角度θ 、φ1はともにO〜2πの間の値( をとるものとしている。
φ1-01...(6a)
Or φ(紫θt+π...(6b
) However, both angles θ and φ1 are assumed to take values between O and 2π.

信号処理回路30では、可変パラメータとしての基準角
度φ を変化さぜつつΔE1=0となるような基準角度
φ を求め、この基準角度φ1を回転角θ1の検出値と
して出力する。なお、(6a)式が常に成立してφ1=
01となるようにするため、回転軸αの回転角θ1が0
0のときに角度φlを00とする調整が行われる(これ
については後述する)。
The signal processing circuit 30 changes the reference angle φ 2 as a variable parameter to find a reference angle φ 2 such that ΔE1=0, and outputs this reference angle φ1 as a detected value of the rotation angle θ1. Note that equation (6a) always holds true and φ1=
01, the rotation angle θ1 of the rotation axis α is set to 0.
When the angle φl is 0, adjustment is made to set the angle φl to 00 (this will be described later).

第3図は、第1の信号処理回路30の内部構成を示すブ
ロック図である。図において、信号処理回路30は2つ
の乗算回路31a、31bを有しており、第1のエンコ
ーダからの2相信号el^。
FIG. 3 is a block diagram showing the internal configuration of the first signal processing circuit 30. In the figure, the signal processing circuit 30 has two multiplication circuits 31a and 31b, and receives a two-phase signal el^ from the first encoder.

eIBかそれぞれに与えられる。また2つの乗算回路3
1.a、31.bには、ROM32a、32bから正弦
波eO3φ 、  sinφIのデジタル値がそれそれ
与えられ、上記(3)式および (4)式の乗算が行わ
れる。乗算結果E  、E  は、乗算回路311A 
  iB a、31bから減算回路33に与えられ、上記(5)式
の減算が行われる。減算結果ΔE1は、減算回路35か
らコンパレータ34に与えられて、ΔE  =0になっ
たか否かが判定される。△E1=0になると、コンパレ
ータ34の出力信号ScIが立上る(または立下る)。
eIB is given to each. Also two multiplier circuits 3
1. a, 31. The digital values of the sine waves eO3φ and sinφI are respectively given to b from the ROMs 32a and 32b, and multiplication of the above equations (3) and (4) is performed. The multiplication results E and E are obtained by the multiplication circuit 311A.
It is applied from iB a, 31b to the subtraction circuit 33, and the subtraction of the above equation (5) is performed. The subtraction result ΔE1 is provided from the subtraction circuit 35 to the comparator 34, and it is determined whether ΔE=0. When ΔE1=0, the output signal ScI of the comparator 34 rises (or falls).

例えば、減算結果ΔE の値が正から負になると出力信
号S。1がHしベルに立上り、一方、負から正になると
Lレベルに立下る。アップダウンカウンタ35は、コン
パレータ34からの出力信号S。1を受取り、信号S 
がHレベルのときには基準角度φ1の値を減l 少させるように、カウントダウンを行い、一方、信号S
 がLレベルのときには基準角度φ1の値l を増加させるようにカウントアツプを行う。アラ1 ブダウンカウンタ35から出力された基準角度φ1は、
前記のROM32a、32bのアドレスとしてそれぞれ
与えられる。コンパレータ34の出力信号S。lは、ゼ
ロクロスパルス発生回路36にも与えられている。ゼロ
クロスパルス発生回路36は、信号S。1の立上りエツ
ジを検出して、ラッチゲーi・制御信号SLlを発生ず
る。ラッチゲ−1・制御信号SL1はゼロクロスパルス
発生回路36からラッチ回路37に与えられる。ラッチ
回路37には、アップダウンカウンタ35から出力され
た角度φlが入力データとして与えられており、ラッチ
ゲート制御信号S1.1がHレベルに立上ると基準角度
φ1の値をラッチし、これを回転角θ1の検出値として
出力する。なお、ラッチゲート制御信号S はビジー信
号B1として信号処理回路1、.1 30から制御装置60にも与えられている(第1図参照
)。そして、ラッチ回路37がデータの書換を行ってい
る期間(信号SLlがHレベルの期間)は制御装置60
がラッチ回路39から回転角θ1の値を読出すのを禁止
している。
For example, when the value of the subtraction result ΔE changes from positive to negative, the output signal S is generated. 1 goes high and rises to the bell, while when it goes from negative to positive, it falls to the low level. The up/down counter 35 receives the output signal S from the comparator 34. 1, signal S
When the signal S is at H level, a countdown is performed to decrease the value of the reference angle φ1, while the signal S
When is at the L level, a count-up is performed to increase the value l of the reference angle φ1. The reference angle φ1 output from the Ara 1 down counter 35 is
These are given as addresses of the ROMs 32a and 32b, respectively. Output signal S of comparator 34. l is also given to the zero-cross pulse generation circuit 36. The zero cross pulse generation circuit 36 generates a signal S. The rising edge of 1 is detected and the latch gate i/control signal SLl is generated. The latch gate 1/control signal SL1 is applied from the zero-cross pulse generation circuit 36 to the latch circuit 37. The latch circuit 37 is given the angle φl output from the up/down counter 35 as input data, and when the latch gate control signal S1.1 rises to H level, it latches the value of the reference angle φ1 and uses it as input data. It is output as a detected value of rotation angle θ1. Note that the latch gate control signal S is sent as a busy signal B1 to the signal processing circuits 1, . 130 to the control device 60 (see FIG. 1). During the period when the latch circuit 37 is rewriting data (the period when the signal SLl is at H level), the control device 60
is prohibited from reading the value of rotation angle θ1 from the latch circuit 39.

ノ;とf 第4図は、信号処理回路30の動作を示すタイミングチ
ャートである。時刻t1oでは減算結果(以下、「差分
」という。)ΔE1の値が正なので、コンパレータ34
の出力信号S。lがLレヘ/l/に保たれている。そし
て、この信号S。■を受けたアップダウンカウンタ35
が、基準角度φ1をカウントダウンしている。なお、第
4図ではカウンタ35が8ビツトのデジタル値として基
準角度φ を出力すると仮定しており、基準角度φ1の
値を16進数で示している。基準角度φIの値がカウン
トダウンされて0E(1,6進数)になると、時刻t 
において差分ΔE1が零となる。すると、1 コンパレータ34の出力信号S。Iが立上る。ゼロクロ
スパルス発生回路36は信号S。1の立上りエツジを検
出して、その出力信号S1,1を短時間だけHレベルに
立上げる。この結果、信号SLLをラッチ信号として受
けたラッチ回路37が基準角度φ =OEの値を回転角
θ1の検出値として出力する。一方、時刻t11で信号
S。1がHレベルに立上ると、アップダウンカウンタ3
5は基準角度 4 φIの値をカウントアツプする。そして、時刻t12に
おいて、角度φ1の値がOFになると、信号S。1が立
下る。その後、アップダウンカウンタ37はカウントダ
ウンとカウントアツプとを繰返し、信号S。1がHレベ
ルに立上る時刻t13、14・・・においてラッチ回路
37のデータが書換えられて、そのデータが回転角θl
の検出値として出力される。
f; and f FIG. 4 is a timing chart showing the operation of the signal processing circuit 30. At time t1o, the value of the subtraction result (hereinafter referred to as "difference") ΔE1 is positive, so the comparator 34
output signal S. l is kept at Llehe/l/. And this signal S. ■Up-down counter 35 received
is counting down the reference angle φ1. In FIG. 4, it is assumed that the counter 35 outputs the reference angle φ1 as an 8-bit digital value, and the value of the reference angle φ1 is shown in hexadecimal notation. When the value of the reference angle φI is counted down and reaches 0E (1, hexadecimal number), time t
The difference ΔE1 becomes zero. Then, 1 the output signal S of the comparator 34. I stands up. Zero cross pulse generation circuit 36 receives signal S. 1 is detected, and the output signal S1,1 is raised to H level for a short period of time. As a result, the latch circuit 37 which receives the signal SLL as a latch signal outputs the value of the reference angle φ=OE as the detected value of the rotation angle θ1. On the other hand, the signal S is generated at time t11. 1 rises to H level, up/down counter 3
5 is a reference angle. 4 Count up the value of φI. Then, at time t12, when the value of angle φ1 becomes OF, signal S is generated. 1 falls. Thereafter, the up/down counter 37 repeats counting down and counting up, and the signal S is output. 1 rises to the H level, the data in the latch circuit 37 is rewritten, and the data becomes the rotation angle θl.
is output as the detected value.

なお、第4図では回転軸αの回転角θ1の値が一定値(
=OE)に保たれている場合を示したが、回転角θ1が
経時的に変化する場合にもこれに追従して各時点の回転
角θ1の値が求められ、出力される。
In addition, in Fig. 4, the value of the rotation angle θ1 of the rotation axis α is a constant value (
=OE), but even if the rotation angle θ1 changes over time, the value of the rotation angle θ1 at each time point is determined and outputted following this change.

差分ΔE1の値が零のときは、基準角度φ1と回転角θ
1との間に前記(6a)式または(6b)式の関係が成
立つ。しかし、求めたいのは(6a)式の関係である。
When the value of the difference ΔE1 is zero, the reference angle φ1 and the rotation angle θ
1, the relationship of equation (6a) or equation (6b) is established. However, what we want to find is the relationship expressed by equation (6a).

そこで、第1図の制御システムの起動時に、回転軸αの
回転角θ1を00に設定し、このときにラッチ回路37
をクリア信号CL、(第3図参照)によってクリアし、
ラッチ回路37からの出力である回転角θ1の検出値を
0°に合わせる。このように初期調整を行えば、その後
は回転角θ1の変化に追従してその値が信号処理回路3
0によって求められるので、常に(6a)式の関係が保
たれる。
Therefore, when starting up the control system shown in FIG. 1, the rotation angle θ1 of the rotation axis α is set to 00, and the latch circuit
is cleared by the clear signal CL, (see Figure 3),
The detected value of the rotation angle θ1, which is the output from the latch circuit 37, is adjusted to 0°. If the initial adjustment is performed in this way, the value will be applied to the signal processing circuit 3 following the change in the rotation angle θ1.
0, so the relationship in equation (6a) is always maintained.

第5図は、第2の信号処理回路40の内部構成を示すブ
ロック図である。この信号処理回路40は乗算回路4 
]、a、4 l b、ROM42.減算回路43.コン
パレータ44.アップダウンカウンタ45.ゼロクロス
パルス発生回路46および3ステ一トラツチ回路47を
有しており、これらの構成要素は第2図における構成要
素と同じ機能を有している。但し、ROM42は第3図
の2つのROM 32 a 、  32 bの機能を有
しており、2つの基準正弦波sinφ 、  COSφ
2を表わすデータを時分割で交互に出力する。すなわち
、ROM42のアドレスの上位半分には、基準角度φ2
に対する基準正弦波sinφ2の値が記憶されており、
1 ) 下位半分には基準余弦波eosφ2の値が記憶されてい
る。そして、タイミング発生回路48からROM42に
与えられる選択信号MSBに従って、sinφ とco
sφ2の値とが交互にROM42から出力される。この
選択信号MSBはROM42のアドレスの最上位ビット
を指定する。一方、ROM42のアドレスの下位ビット
は、アップダウンカウンタ45から与えられる角度φ2
によって指定される。
FIG. 5 is a block diagram showing the internal configuration of the second signal processing circuit 40. This signal processing circuit 40 is a multiplication circuit 4
], a, 4 l b, ROM42. Subtraction circuit 43. Comparator 44. Up/down counter 45. It has a zero-cross pulse generation circuit 46 and a three-step latch circuit 47, and these components have the same functions as the components in FIG. However, the ROM 42 has the functions of the two ROMs 32 a and 32 b shown in FIG. 3, and has two reference sine waves sinφ and COSφ
Data representing 2 is outputted alternately in a time-sharing manner. That is, the reference angle φ2 is stored in the upper half of the address of the ROM 42.
The value of the reference sine wave sinφ2 for is stored,
1) The value of the reference cosine wave eosφ2 is stored in the lower half. Then, according to the selection signal MSB applied from the timing generation circuit 48 to the ROM 42, sinφ and co
The value of sφ2 is alternately outputted from the ROM 42. This selection signal MSB specifies the most significant bit of the address of the ROM 42. On the other hand, the lower bit of the address of the ROM 42 is the angle φ2 given from the up/down counter 45.
specified by.

第2の信号処理回路40はさらに、基準正弦波データs
1nφ 、  COSφ2を補正するための補正値f 
 、f  を記憶しているRAM49を備えて2 いる。RAM49もROM42と同様に、アドレスの上
位半分には基準正弦波データsinφ2のための補正値
f1を記憶し、下位半分には基準余弦波データCOSφ
 のための補正値f2を記憶している。そして、タイミ
ング発生回路48から与えられる選択信号MSBに従っ
て補正値f1とf2とを交互に出力する。基準正弦波デ
ータsinφ2゜COSφ2は、加算回路50において
それぞれの補 6 正値f、f2と加算され、加算結果(sinφ2 +f)、(cosφ2+12)は乗算回路4]b。
The second signal processing circuit 40 further includes reference sine wave data s.
1nφ, correction value f for correcting COSφ2
, f is provided. Similarly to the ROM 42, the RAM 49 also stores the correction value f1 for the reference sine wave data sinφ2 in the upper half of the address, and the reference cosine wave data COSφ in the lower half.
A correction value f2 for is stored. Then, according to the selection signal MSB given from the timing generation circuit 48, the correction values f1 and f2 are outputted alternately. The reference sine wave data sinφ2°COSφ2 is added to the respective correction values f and f2 in the adder circuit 50, and the addition results (sinφ2+f) and (cosφ2+12) are added to the multiplication circuit 4]b.

41aにそれぞれ与えられる。41a, respectively.

上記の加算結果(sinφ2+f、)、(cosφ2 
+ f 2 )は乗算回路41b、4]、Hにそれぞれ
与えられて、第2のエンコーダ20の正弦波出力信号e
   e  との乗算が行われる。乗算回路2B’  
2A 41a、41bでの乗算結果E  、E  は減算口2
A   2B 路43に与えられて差分ΔE(”’ E2A  ”’ 
2B)が算出される。そして、その後は第3図の信号処
理回路30と同様に、コンパレータ44.アップダウン
カウンタ45.ゼロクロスパルス発生回路46およびラ
ッチ回路47の働きによって、φ2−〇 となる基準角
度φ2が求められ、これが回転角θ2の検出値として、
ラッチ回路47からデータバス51を介して制御装置6
0に出力される。
The above addition result (sinφ2+f,), (cosφ2
+ f 2 ) are given to the multiplication circuits 41b, 4] and H, respectively, and the sine wave output signal e of the second encoder 20 is
Multiplication with e is performed. Multiplier circuit 2B'
2A Multiplication results E and E in 41a and 41b are subtraction port 2
The difference ΔE("' E2A "'
2B) is calculated. Then, similarly to the signal processing circuit 30 of FIG. 3, the comparator 44. Up/down counter 45. By the action of the zero cross pulse generation circuit 46 and the latch circuit 47, a reference angle φ2 that becomes φ2−〇 is obtained, and this is used as the detected value of the rotation angle θ2.
from the latch circuit 47 to the control device 6 via the data bus 51.
Output to 0.

なお、第2の信号処理回路40において、主としてアッ
プダウンカウンタ45とROM42とがこの発明におけ
る基準正弦波信号生成手段を構成している。また、RA
M49が補正データ発生子 8 段を、加算回路50が補正手段を構成している。
In the second signal processing circuit 40, the up/down counter 45 and the ROM 42 mainly constitute the reference sine wave signal generating means in the present invention. Also, R.A.
M49 constitutes an 8-stage correction data generator, and the adder circuit 50 constitutes a correction means.

さらに、乗算回路41a、41bが乗算手段を構成して
いる。また、減算回路43.コンパレータ44、ゼロク
ロスパルス発生回路46.ラッチ回路47などが検出手
段を構成している。
Furthermore, multiplication circuits 41a and 41b constitute multiplication means. Further, the subtraction circuit 43. Comparator 44, zero cross pulse generation circuit 46. The latch circuit 47 and the like constitute the detection means.

C−3,補正値の算出 RAM49に書込まれている補正値f、f2( は、例えば次のようにして算出されている。C-3, Calculation of correction value Correction values f, f2 ( is calculated, for example, as follows.

まず、第2のエンコーダ20の2相出力信号e2A”2
Bを何らかの記録装置に記録する。これらの2相出力信
号e   e  は、第2図(b)に示2八″ 2B すように正確な正弦波、余弦波ではなく、誤差を含んで
おり、次のように書き表わせる。
First, the two-phase output signal e2A"2 of the second encoder 20
Record B on some recording device. These two-phase output signals e e are not accurate sine waves or cosine waves as shown in FIG. 2(b), but contain errors, and can be expressed as follows.

e  −k    sinθ +a (θl)   ・
−(7a)2^    2゛2 e  −k    cosθ +b (θ、 )   
−(7b)2B    2       2 ここでa(θ )、b(θ1)は正確な正弦波からのズ
レ量であり、回転角θ1に依存している。
e −k sinθ +a (θl) ・
-(7a)2^ 2゛2 e -k cosθ +b (θ, )
-(7b)2B 2 2 Here, a(θ) and b(θ1) are deviation amounts from an accurate sine wave, and are dependent on the rotation angle θ1.

乗算回路41a、41bにおける乗算結果E2AE2B
はそれぞれ次のようになるはずである。
Multiplication result E2AE2B in multiplication circuits 41a and 41b
should be as follows:

E  −e  ・(cosφ 十f2 (θ1))2A
     2A           2−(k   
sjnθ2+a(θ1〉)x (cosφ 十f2 (
θi、 ))  −(8a)E  =e  ・(sin
φ2+f1 (θ1))28    2B =(k    eosθ2+b (θ())X (si
nφ +f1 (θ1 ))  −(81))補正値f
  、f  は、θ2=φ2が成立っとき2 に、ΔE (=E2A−E2B)の値を零にするように
決めればよい。このとき、E2A= E2+3だから次
の式が成立する。
E −e ・(cosφ 10f2 (θ1))2A
2A 2-(k
sjnθ2+a(θ1〉)x (cosφ 10f2 (
θi, )) −(8a)E = e ・(sin
φ2+f1 (θ1))28 2B = (k eosθ2+b (θ())X (si
nφ +f1 (θ1)) −(81)) Correction value f
, f may be determined so that the value of ΔE (=E2A−E2B) becomes zero when θ2=φ2 holds. At this time, since E2A=E2+3, the following equation holds true.

(k    sinθ2+a (θ1))X (cos
φ2+f2 (θ()) ””(k    cosθ +b (θ1))2 X (sinθ +f1 (θ1))・・(9)2相出
力信号e   e  の波形を予め記録して2A″ 2
B おいたので、回転角θ1の値に対応する誤差a(θ、)
、b(θ1)の値は既知である。従って、(9)式にお
いて、未知数は補正値f、(θ1)f (θ1)の2つ
だけである。 (9)式を満足するような補正値f (
θ )、f2 (0,1)の組1 ] 9 合せは無限にあるが、乗算回路41.a、41bや減算
回路43での演算の精度等を考慮して、適宜それぞれの
補正値f (θ )、f2 (θ1)を1 決定すればよい。
(k sin θ2+a (θ1))X (cos
φ2+f2 (θ()) ””(k cosθ +b (θ1)) 2
B, the error a(θ,) corresponding to the value of the rotation angle θ1
, b(θ1) are known. Therefore, in equation (9), there are only two unknowns: the correction value f and (θ1)f (θ1). A correction value f (
θ ), f2 (0,1) set 1 ] 9 There are infinite combinations, but the multiplication circuit 41 . The correction values f (θ ) and f2 (θ1) may be appropriately determined by taking into consideration the accuracy of calculations in a, 41b and the subtraction circuit 43, respectively.

C−3,補正値の書込み動作 RAM52への補正値f、f2の書込みは次のように行
われる。まず、制御装置10から信号処理回路40に与
えられる各種の制御信号(第1図参照)のレベルは次の
通りである。
C-3, Writing operation of correction values Writing of correction values f and f2 to the RAM 52 is performed as follows. First, the levels of various control signals (see FIG. 1) given from the control device 10 to the signal processing circuit 40 are as follows.

ラッチイネーブル信号LE−H・・・(tea、)イン
ヒビット信号I N=HI又はり。・・・(10b)バ
ッファイネーブル信号BE−H,・・・(10c)書込
み制御信号WR−H,・・・(lod)ラッチイネーブ
ル信号LEはインバータ55を介して3ステ一トラツチ
回路47のイネーブル端子に入力されている。従って、
LE−H,(LE=L )であれば、3ステ一トラツチ
回路47はハイインピーダンスとなり、アップダウンカ
ウンタ45からラッチ回路47に与えられる角度データ
φ2が外部に出力されない状態となる。また、う 0 ッチイネーブル信号LEはそのまま3ステートバツフア
53のイネーブル端子にも与えられている。
Latch enable signal LE-H... (tea,) inhibit signal IN N=HI or otherwise. (10b) Buffer enable signal BE-H, (10c) Write control signal WR-H, (lod) Latch enable signal LE enables the 3-step latch circuit 47 via the inverter 55. input to the terminal. Therefore,
If LE-H, (LE=L), the three-step latch circuit 47 becomes high impedance, and the angle data φ2 given from the up/down counter 45 to the latch circuit 47 is not outputted to the outside. Further, the off-catch enable signal LE is also applied to the enable terminal of the 3-state buffer 53 as it is.

従って、LE−Hlのときにこの3ステートバッファ5
6は通常のバッファとして動作し、データバス51を介
して制御装置60から与えられた補正値f  、f  
をRAMのデータバス101に伝2 達する。バッファイネーブル信号BEは、3ステートバ
ツフア54のイネーブル端子に入力される。
Therefore, when LE-Hl, this 3-state buffer 5
6 operates as a normal buffer and receives correction values f and f given from the control device 60 via the data bus 51.
is transmitted to the RAM data bus 101. Buffer enable signal BE is input to the enable terminal of 3-state buffer 54.

従って、BE=H,のとき、3ステートバッファ54は
外部から与えられる回転角θ1をRAMのアドレスバス
102に伝送する。なお、このとき第1図のスイッチ回
路70は制御装置60側に切換えられており、RAM5
2のアドレスとしての回転角θ のデータは、補正値f
  、f  ととも1          1、  2 に制御装置60から信号処理回路40に供給される。バ
ッファイネーブル信号BEは、同時にインバータ55を
介して3ステートバツフア56のイネーブル端子にも入
力されている。従ってBE−H,(BE−L  )であ
れば、3ステートバツフ】             
  0 ア56はハイインピーダンスとなり、アップダウ 2 ンカウンタ45から3ステートバツフア56およびアド
レスバス102を介してRAM49に与えられるアドレ
ス(角度φ2)が遮断される。書込み制御信号WRはR
AM49の書込み制御端子にそのまま人力されるととも
とに、インバータ57を介して反転されてRAM49の
読出し制御端子にも入力される。WR=H,であれば、
データバス101を介して与えられる補正値f  、f
  が、2 アドレスバス102を介して与えられるアドレスθ1に
従ってRAM49内に書込まれる。なお、書込み制御信
号WRをLレベルにすれば、RAM49に記憶されてい
る補正値f  、f  がデータ2 バス101..3ステートバッファ53.およびデータ
バス51を介して制御装置60に読出される。
Therefore, when BE=H, the 3-state buffer 54 transmits the rotation angle θ1 given from the outside to the address bus 102 of the RAM. Note that at this time, the switch circuit 70 in FIG. 1 has been switched to the control device 60 side, and the RAM 5
The data of the rotation angle θ as address 2 is the correction value f
, f and 1 1, 2 are supplied from the control device 60 to the signal processing circuit 40 . Buffer enable signal BE is also input to the enable terminal of 3-state buffer 56 via inverter 55 at the same time. Therefore, if BE-H, (BE-L), 3-state buffer]
0 gate 56 becomes high impedance, and the address (angle φ2) applied from up/down counter 45 to RAM 49 via 3-state buffer 56 and address bus 102 is cut off. Write control signal WR is R
The signal is input directly to the write control terminal of the AM 49, and is also inverted via the inverter 57 and input to the read control terminal of the RAM 49. If WR=H, then
Correction values f , f given via data bus 101
is written into the RAM 49 according to the address θ1 given via the 2-address bus 102. Note that when the write control signal WR is set to L level, the correction values f 1 and f stored in the RAM 49 are transferred to the data 2 bus 101. .. 3-state buffer 53. and is read out to the control device 60 via the data bus 51.

C−41回転角の検出動作 回転角θ2の検出時において制御装置60から信号処理
回路40に与えられる各制御信号のレベルは次の通りで
ある。
C-41 Rotation Angle Detection Operation The levels of each control signal applied from the control device 60 to the signal processing circuit 40 when detecting the rotation angle θ2 are as follows.

ラッチイネーブル信号L E = Lo   ・・・(
lla)インヒビット信号I H=H,又はL ・・・
(llb)】         0 バッファイネーブル信号BE−H・・・(+、lc)書
込み制御信号WR−L。     ・・・(lid)L
E−L  (LE−H,)なので、3ステートうッチ回
路47が能動状態となり、一方、3ステートバツフア5
3はハイインピーダンス状態となる。
Latch enable signal L E = Lo...(
lla) Inhibit signal I H=H, or L...
(llb)] 0 Buffer enable signal BE-H...(+, lc) Write control signal WR-L. ...(lid)L
Since E-L (LE-H,), the 3-state latch circuit 47 becomes active, while the 3-state buffer 5
3 is in a high impedance state.

また、BE=H,なので、3ステートバッファ54.5
6がそれぞれ能動状態およびハイインピーダンス状態と
なる。さらに、WR−L  なのでRAM49への書込
みが禁止され、RAM49からの読出しが可能となる。
Also, since BE=H, the 3-state buffer 54.5
6 are in the active state and high impedance state, respectively. Furthermore, since it is WR-L, writing to the RAM 49 is prohibited and reading from the RAM 49 is enabled.

以上のように各制御信号が与えられている結果、第5図
の信号処理回路40は、第6A図に示す回路40aと等
価になる。
As a result of each control signal being applied as described above, the signal processing circuit 40 shown in FIG. 5 becomes equivalent to the circuit 40a shown in FIG. 6A.

第6A図の回路40aは、第3図に示す第1の信号処理
回路30に、RAM49と加算回路5oとを加えたもの
とほぼ等価である。
The circuit 40a in FIG. 6A is almost equivalent to the first signal processing circuit 30 shown in FIG. 3 plus a RAM 49 and an adder circuit 5o.

第7図は、回転角θ2の検出時における信号処理回路4
0(40a)の動作を示すタイミングチャートである。
FIG. 7 shows the signal processing circuit 4 when detecting the rotation angle θ2.
4 is a timing chart showing the operation of 0 (40a).

第1の信号処理回路3oによって検出された回転角θ1
のデータは、アドレスバス102を介してRAM49に
周期的に与えられる。
Rotation angle θ1 detected by the first signal processing circuit 3o
The data is periodically given to the RAM 49 via the address bus 102.

 3 第7図に示すように、回転角θ1が定期的に供給される
時に、基準タイミング信号S が同時に第1の信号処理
回路30から第2の信号処理回路40に供給され、第6
A図に示すように、タイミング発生回路48に人力され
る。タイミング発生回路48は、基準タイミング信号S
 基づいて、乗算回路41.a、41b、ROM42お
よびRAM49のタイミングを合わせるためのタイミン
グ信号548(第7図参照)を発生する。このタイミン
グ信号S48のうちで、選択信号MSBはROM42に
与えられており、ROM42に記憶されている基準正弦
波sinθ 、  cosφ2のデータDRoMがこの
選択信号MSBに応じて周期的に交互に読出される。選
択信号MSBの周期は、アップダウンカウンタ45から
ROM42のアドレスに人力される基準角度φ2が更新
される周期と同じである。すなわち、基準角度φ2が1
.つの値を保持している間に選択信号MSBが“]“と
“0”の値を1度づつ交互にとる。選択信号MSBの値
が“1”のとき、ROM42から読出されるデータDR
oMはsinφ2であり、選択信号MSBの値が“0”
のとき、ROM42から読出されるデータDRoMはa
osφ2である。選択信号MSBはRAM49にも与え
られており、選択信号MSBの値が“1″のときにRA
M49から読出されるデータD  は補正値f1であり
、選択信号MSBのAM 値が“0″のときにRAM49から読出されるデータD
  は補正値f2である。第7図からもゎAM かるように、ROM42とRAM49がら読出されるデ
ータD   、D   は、選択信号MSBにROM 
  RAM 同期して同時に加算回路50に与えられる。
3. As shown in FIG. 7, when the rotation angle θ1 is supplied periodically, the reference timing signal S is simultaneously supplied from the first signal processing circuit 30 to the second signal processing circuit 40,
As shown in Figure A, the timing generation circuit 48 is manually operated. The timing generation circuit 48 generates a reference timing signal S
Based on the multiplication circuit 41. A timing signal 548 (see FIG. 7) for synchronizing the timings of ROM 42 and RAM 49 is generated. Of this timing signal S48, the selection signal MSB is given to the ROM 42, and the data DRoM of the reference sine waves sinθ and cosφ2 stored in the ROM 42 are periodically and alternately read out in accordance with this selection signal MSB. . The cycle of the selection signal MSB is the same as the cycle in which the reference angle φ2 manually entered from the up/down counter 45 to the address of the ROM 42 is updated. That is, the reference angle φ2 is 1
.. While this value is held, the selection signal MSB alternately takes the values "]" and "0" once each. When the value of the selection signal MSB is “1”, the data DR read from the ROM 42
oM is sinφ2, and the value of the selection signal MSB is “0”
At this time, the data DRoM read from the ROM 42 is a
osφ2. The selection signal MSB is also given to the RAM 49, and when the value of the selection signal MSB is "1", the RAM 49
The data D read from the RAM 49 is the correction value f1, and the data D read from the RAM 49 when the AM value of the selection signal MSB is "0".
is the correction value f2. As can be seen from FIG.
RAM synchronously and simultaneously provided to the adder circuit 50.

加算回路50で加算された結果は、次のようにして乗算
回路41a、41bで処理される。第6B図は、乗算回
路41a、41bの内部構成を示すブロック図である。
The result added by the addition circuit 50 is processed by the multiplication circuits 41a and 41b as follows. FIG. 6B is a block diagram showing the internal configuration of multiplication circuits 41a and 41b.

乗算回路41a、41bはともに2つのレジスタ411
,41.2と、乗算器413とを有している。第1のレ
ジスタ411には加算回路50から加算結果が与えられ
ており、タイミング発生回路48から与えられるレジス
タ制御信号S (又はS、2)に応じて、加算結果1 (sfnφ2 十f t )  (又は(cosφ2+
f2))が第ルジスタ411にデータDb1(又はり、
()として書込まれる(第7図参照)。第ルジスタ41
1に書込まれたデータD、1(又はDa□)は、タイミ
ング発生回路48から第2レジスタ412に与えられる
レジスタ制御信号S に応じて第2しr ジスタ412に書込まれる。第2レジスタ412にデー
タが書込まれると、乗算器413は第2レジスタ412
のデータD (又はり、2)と、第22 のエンコーダ20から与えられた正弦波信号e2B(又
はe2^)との乗算を行って乗算結果E2B(又はE2
A)を出力する(第7図nは図示せず)。第6A図およ
び第7図かられかるように、第2レジスタ412に与え
られるレジスタ制御信号S はr「 2つの乗算回路41.a、41bに共通に与えられてお
り、第2レジスタ412へのデータD、2゜Db2の書
込みおよび乗算結果の出力は、2つの乗算回路41a、
4.1bにおいて同じタイミングで行われる。この後の
動作は、第1の信号処理回路30と同じである。すなわ
ち、減算回路43によって求められた差分ΔE  (=
E2^−E2B)に従ってコンパレータ44がアップダ
ウンカウンタ45をカウントアツプまたはカウントダウ
ンさせる。
The multiplication circuits 41a and 41b both have two registers 411.
, 41.2, and a multiplier 413. The first register 411 is given the addition result from the adder circuit 50, and the addition result 1 (sfnφ2 + f t ) ( or (cosφ2+
f2)) is stored in the first register 411 as data Db1 (or
() (see Figure 7). No. 41
The data D, 1 (or Da□) written to 1 is written to the second register 412 in response to the register control signal S 2 applied from the timing generation circuit 48 to the second register 412. When data is written to the second register 412, the multiplier 413 writes the data to the second register 412.
The data D (or 2) is multiplied by the sine wave signal e2B (or e2^) given from the 22nd encoder 20, and the multiplication result E2B (or E2
A) (Figure 7n is not shown). As can be seen from FIGS. 6A and 7, the register control signal S given to the second register 412 is commonly given to the two multiplier circuits 41.a and 41b, and the register control signal S given to the second register 412 is The writing of data D, 2°Db2 and the output of the multiplication results are performed by two multiplication circuits 41a,
4.1b at the same timing. The subsequent operation is the same as that of the first signal processing circuit 30. That is, the difference ΔE (=
E2^-E2B), the comparator 44 causes the up/down counter 45 to count up or down.

そして、これによって回転角θ2に等しい基準角度φ2
の値が検出され、ラッチ回路47から制御装置60に回
転角θ2の検出値として供給される。
As a result, the reference angle φ2 equal to the rotation angle θ2
The value of is detected and supplied from the latch circuit 47 to the control device 60 as the detected value of the rotation angle θ2.

なお、インヒビット信号INは、制御装置60がラッチ
回路47から回転角θ2の値を読出している場合にLレ
ベルとなり、ラッチ回路47のデータの書換えを禁止す
る。すなわち、インヒビット信号INがLレベルになり
、AND回路59に与えられると、ゼロクロスパルス発
生信号46が発生したラッチゲート制御信号S1,2が
AND回路59によって阻止されて、ラッチ回路47に
−りえられなくなる。従って、制御装置60が回転角θ
2をラッチ回路47から読出している最中にラッチ回路
47の保持データが書換えられるという不都合が回避さ
れる。
Note that the inhibit signal IN becomes an L level when the control device 60 is reading the value of the rotation angle θ2 from the latch circuit 47, and prohibits rewriting of data in the latch circuit 47. That is, when the inhibit signal IN goes to the L level and is applied to the AND circuit 59, the latch gate control signals S1 and S2 in which the zero-cross pulse generation signal 46 is generated are blocked by the AND circuit 59 and sent back to the latch circuit 47. It disappears. Therefore, the control device 60 controls the rotation angle θ
This avoids the inconvenience that the data held in the latch circuit 47 is rewritten while the data 2 is being read from the latch circuit 47.

このように、第2のエンコーダ20の回転角θ2を検出
するに際して、絶対位置検出用の第] 7 のエンコーダ10で検出した回転角θ1を用い、この回
転角θ に応じた補正値fi  (θ1)。
In this way, when detecting the rotation angle θ2 of the second encoder 20, the rotation angle θ1 detected by the seventh encoder 10 for absolute position detection is used, and the correction value fi (θ1 ).

f (θ1)を用いて補正を行っているので、第2のエ
ンコーダ20の正弦波2相出力信号e2A。
Since the correction is performed using f (θ1), the sine wave two-phase output signal e2A of the second encoder 20.

e2Bが正確な正弦波でない場合にも回転角θ2を高精
度で検出できる。
Even if e2B is not a precise sine wave, the rotation angle θ2 can be detected with high precision.

D、変形例 この発明は、上記実施例に限られるものではなく、次の
ような変形も可能である。
D. Modifications The present invention is not limited to the above embodiments, and the following modifications are also possible.

■ 第1のエンコーダ10の回転角θ1を検出するため
の第1の信号処理回路30として、第2の信号処理回路
40と同じ構成の回路を用いてもよい。このとき、回転
角θ1の検出時に制御装置60から与えられる各制御信
号のレベルは次の通りになる。
(2) As the first signal processing circuit 30 for detecting the rotation angle θ1 of the first encoder 10, a circuit having the same configuration as the second signal processing circuit 40 may be used. At this time, the levels of each control signal given from the control device 60 when detecting the rotation angle θ1 are as follows.

ラッチイネーブル信号LE−L    ・・・(12a
)インヒビット信号I H−H,又はり。・・・(12
b)バッファイネーブル信号BE−L   ・・・(1
2c)書込み制御信号WR−L。     ・・・(L
2d)このとき、第5図の信号処理回路40は、第8図
 8 の回路40bと等価になる。但し、第5図の回路40に
おいて角度θ 、φ2で書表わされていた部分は、第8
図では角度θ 、φ に書換えられ】  1 ている。
Latch enable signal LE-L (12a
) inhibit signal I H-H, or. ...(12
b) Buffer enable signal BE-L...(1
2c) Write control signal WR-L. ...(L
2d) In this case, the signal processing circuit 40 of FIG. 5 becomes equivalent to the circuit 40b of FIG. 8. However, in the circuit 40 of FIG. 5, the portion indicated by angles θ and φ2 is
In the figure, the angles θ and φ are rewritten as] 1.

第8図かられかるように、アップダウンカウンタ45か
ら出力された基準角度φ2のデータは、RAM49のア
ドレスを指定するためにも用いられている。このように
すれば、第1のエンコーダ]0の2相出力信号e  、
e  が正確な正弦波かIA   LB らずれている場合にも、回転角θ1に応じた補正値f 
 、f  を用いて乗算結果E  、E  及び減1、
  1          1.A   IB算結果Δ
E1を補正することにより、回転角θ1を高精度で検出
できる。
As can be seen from FIG. 8, the data of the reference angle φ2 outputted from the up/down counter 45 is also used to specify the address of the RAM 49. In this way, the two-phase output signal e of the first encoder]0,
Even if e is a precise sine wave or deviates from IALB, the correction value f according to the rotation angle θ1
, f using multiplication results E , E and subtraction 1,
1 1. A IB calculation result Δ
By correcting E1, the rotation angle θ1 can be detected with high accuracy.

なお、上記のようにして、回転角θ1を十分な高精度で
検出できる場合には、第2のエンコーダ20とその信号
処理回路40は不要である。
Note that if the rotation angle θ1 can be detected with sufficiently high accuracy as described above, the second encoder 20 and its signal processing circuit 40 are unnecessary.

■ エンコーダの正弦波出力信号の誤差は、回転角ばか
りでなく、エンコーダの環境温度などの他のパラメータ
に依存することがある。この場合には、補正値f  、
f  を、回転角θ1や環境温2 度などの種々のパラメータに依存するデータとして求め
、RAM49に記憶しておけばよい。そして、RAM4
9のアドレスがそのパラメータによって指定されるよう
にすればよい。
■ The error of the encoder's sinusoidal output signal may depend not only on the rotation angle but also on other parameters such as the encoder's environmental temperature. In this case, the correction value f,
f may be obtained as data dependent on various parameters such as the rotation angle θ1 and the environmental temperature 2 degrees, and stored in the RAM 49. And RAM4
9 address may be specified by the parameter.

■ 補正値f  、f2はRAM49に記憶させす るものとしたが、不揮発性のメモリ(たとえばPROM
)に記憶させるようにすれば、信号処理回路の電源を切
っても補正値f、f2のデータが保存される。従って、
電源を0N10FFするたびに補正値f  、f2をメ
モリに書込まなくても良いという利点がある。
■ The correction values f and f2 are stored in the RAM 49, but they can also be stored in a non-volatile memory (for example, a PROM).
), the data of the correction values f and f2 will be saved even if the power to the signal processing circuit is turned off. Therefore,
There is an advantage that it is not necessary to write the correction values f 1 and f 2 into the memory every time the power supply is turned on and off.

■ 基準正弦波データは、補正値との加算によって補正
するものとしたが、その補正を他の四則演算などを用い
て行なってもよい。
(2) Although the reference sine wave data is corrected by adding it to a correction value, the correction may be performed using other four arithmetic operations.

■ 上記実施例はロータリーエンコーダを対象としたが
、リニアエンコーダでもよく、正弦波2相信号を発生す
るエンコーダのための信号処理回路であれば、この発明
が適用可能である。
(2) Although the above embodiment is directed to a rotary encoder, the present invention may be applied to a linear encoder, and any signal processing circuit for an encoder that generates a sine wave two-phase signal can be applied.

(発明の効果) 以上説明したように、この発明では、基準正弦1 波信号を補正した補正基準信号に基づいて可動部の相対
位置を検出するので、エンコーダからの正弦波信号が理
想的正弦波からずれている場合にも、可動部の相対位置
を正確に求めることができるという効果がある。
(Effects of the Invention) As explained above, in this invention, the relative position of the movable part is detected based on the corrected reference signal obtained by correcting the reference sine wave signal, so that the sine wave signal from the encoder is converted into an ideal sine wave. There is an effect that the relative position of the movable part can be accurately determined even when the movable part deviates from the position shown in FIG.

なお、エンコーダからの正弦波信号が理想的iE弦波か
らずれているズレ量が相対位置の値に応じて変化する場
合には、補正データ発生手段は低位置に応じて補正デー
タを発生すれば正確な相対位置検出が可能である。
Note that if the amount of deviation of the sine wave signal from the encoder from the ideal iE sine wave changes depending on the value of the relative position, the correction data generation means should generate correction data according to the low position. Accurate relative position detection is possible.

また、前記ズレ量が第2のパラメータに応じて変化する
場合には、補正データ発生手段は当該節2のパラメータ
に応じて補正データを発生すれば正確な相対位置検出が
可能である。
Moreover, when the amount of deviation changes according to the second parameter, if the correction data generating means generates the correction data according to the parameter of the second clause, accurate relative position detection is possible.

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

第1図は、この発明の一実施例を適用した制御システム
の構成を示すブロック図、 第2図はエンコーダの正弦波出力信号の波形を示す図、 第3図は、第1の信号処理回路の構成を示すブロック図
、 第4図は、第1の信号処理回路の動作を示すタイミング
チャート、 第5図は、第2の信号処理回路の構成を示すブロック図
、 第6A図は、第2の信号処理回路の動作時における等価
回路を示すブロック図、 第6B図は、乗算回路の内部構成を示すブロック図、 第7図は、第2の信号処理回路の動作を示すタイミング
チャート、 第8図は、第2の信号処理回路の他の動作時における等
価回路を示すブロック図である。 1.0.20・・・エンコーダ、 41a、41b・・・乗算回路、 42・・・ROM、       43・・・減算回路
、44・・・コンパレータ、 45・・・アップダウンカウンタ、 46・・・ゼロクロスパルス発生回路、47・・・ラッ
チ回路、    4つ・・・RAM。  3 50・・・加算回路、  e2A’  e2「・・正弦
波信号、sinφ 、  cosφ2・・・基準正弦波
、θ1.θ2・・・回転角、   φ2・・・基準角度
、fl、f2・・・補正値
FIG. 1 is a block diagram showing the configuration of a control system to which an embodiment of the present invention is applied. FIG. 2 is a diagram showing the waveform of a sine wave output signal of an encoder. FIG. 3 is a diagram showing a first signal processing circuit. 4 is a timing chart showing the operation of the first signal processing circuit, FIG. 5 is a block diagram showing the structure of the second signal processing circuit, and FIG. 6A is a timing chart showing the operation of the first signal processing circuit. FIG. 6B is a block diagram showing the internal configuration of the multiplication circuit; FIG. 7 is a timing chart showing the operation of the second signal processing circuit; FIG. The figure is a block diagram showing an equivalent circuit during another operation of the second signal processing circuit. 1.0.20... Encoder, 41a, 41b... Multiplication circuit, 42... ROM, 43... Subtraction circuit, 44... Comparator, 45... Up/down counter, 46... Zero cross pulse generation circuit, 47...Latch circuit, 4...RAM. 3 50...Addition circuit, e2A'e2'...Sine wave signal, sinφ, cosφ2...Reference sine wave, θ1.θ2...Rotation angle, φ2...Reference angle, fl, f2... Correction value

Claims (2)

【特許請求の範囲】[Claims] (1)所定の可動部に取付けられたエンコーダから、固
定部に対する前記可動部の相対位置を位相変数として含
むような異相の第1と第2の正弦波信号を受けて、前記
相対位置を検出するためのエンコーダの信号処理回路で
あって、 可変パラメータとしての仮位置を経時的に変化させつつ
、当該仮位置を位相変数とした理想的正弦波波形を有す
る信号として、異相の第1と第2の基準正弦波信号を発
生する基準正弦波信号生成手段と、 前記相対位置に応じて変化する前記第1と第2の正弦波
信号の理想的正弦波波形からのズレに基づいて予め求め
られた第1と第2の補正データを、前記仮位置に応じて
記憶しており、前記仮位置に応じて第1と第2の補正デ
ータをそれぞれ発生する補正データ発生手段と、 前記第1と第2の基準正弦波信号をそれぞれ前記第1と
第2の補正データで補正することにより、第1と第2の
補正基準信号を生成する補正手段と、前記第1と第2の
補正基準信号をそれぞれ前記第1と第2の正弦波信号と
乗算することにより、第1と第2の乗算信号を生成する
乗算手段と、前記第1と第2の乗算信号の差分を求め、
当該差分が所定の基準差分値に等しいときに、前記仮位
置を前記相対位置の検出値として発生する検出手段とを
備えていることを特徴とするエンコーダの信号処理回路
(1) Detecting the relative position by receiving first and second sine wave signals of different phases that include the relative position of the movable part with respect to the fixed part as a phase variable from an encoder attached to a predetermined movable part. This is a signal processing circuit for an encoder, which changes a temporary position as a variable parameter over time, and converts the temporary position as a phase variable into a signal having an ideal sinusoidal waveform. a reference sine wave signal generating means for generating a second reference sine wave signal; correction data generating means that stores first and second correction data corresponding to the temporary position, and generates the first and second correction data, respectively, according to the temporary position; a correction means for generating first and second corrected reference signals by correcting a second reference sine wave signal with the first and second correction data, respectively; and a correction means for generating first and second corrected reference signals; multiplication means for generating first and second multiplied signals by multiplying by the first and second sine wave signals, respectively; and determining a difference between the first and second multiplied signals;
1. A signal processing circuit for an encoder, comprising: detecting means for generating the tentative position as a detected value of the relative position when the difference is equal to a predetermined reference difference value.
(2)所定の可動部に取付けられたエンコーダから、固
定部に対する前記可動部の相対位置を位相変数として含
むような異相の第1と第2の正弦波信号を受けて、前記
相対位置を検出するためのエンコーダの信号処理回路で
あって、 第1のパラメータとしての仮位置を経時的に変化させつ
つ、当該仮位置を位相変数とした理想的正弦波波形を有
する信号として、異相の第1と第2の基準正弦波信号を
発生する基準正弦波信号生成手段と、 第2のパラメータに応じて変化する前記第1と第2の正
弦波信号の理想的正弦波波形からのズレに基づいて予め
求められた第1と第2の補正データを、前記第2のパラ
メータに応じて記憶しており、前記第2のパラメータに
応じて第1と第2の補正データをそれぞれ発生する補正
データ発生手段と、 前記第1と第2の基準正弦波信号をそれぞれ前記第1と
第2の補正データで補正することにより、第1と第2の
補正基準信号を生成する補正手段と、前記第1と第2の
補正基準信号をそれぞれ前記第1と第2の正弦波信号と
乗算することにより、第1と第2の乗算信号を生成する
乗算手段と、前記第1と第2の乗算信号の差分を求め、
当該差分が所定の基準差分値に等しいときに、前記仮位
置を前記相対位置の検出値として発生する検出手段とを
備えていることを特徴とするエンコーダの信号処理回路
(2) Detecting the relative position by receiving first and second sine wave signals of different phases that include the relative position of the movable part with respect to the fixed part as a phase variable from an encoder attached to a predetermined movable part. This is a signal processing circuit of an encoder for changing a temporary position as a first parameter over time, and converting a first out-of-phase signal into a signal having an ideal sinusoidal waveform with the temporary position as a phase variable. and a reference sine wave signal generating means for generating a second reference sine wave signal; and a reference sine wave signal generating means for generating a second reference sine wave signal, based on a deviation from an ideal sine wave waveform of the first and second sine wave signals, which varies according to a second parameter. A correction data generator that stores first and second correction data obtained in advance in accordance with the second parameter, and generates the first and second correction data respectively in accordance with the second parameter. correcting means for generating first and second corrected reference signals by correcting the first and second reference sine wave signals with the first and second correction data, respectively; and a second correction reference signal, respectively, to generate first and second multiplied signals by multiplying the first and second sine wave signals; Find the difference,
1. A signal processing circuit for an encoder, comprising: detecting means for generating the tentative position as a detected value of the relative position when the difference is equal to a predetermined reference difference value.
JP21990889A 1989-08-25 1989-08-25 Signal processing circuit for encoder Pending JPH0382913A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP21990889A JPH0382913A (en) 1989-08-25 1989-08-25 Signal processing circuit for encoder

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP21990889A JPH0382913A (en) 1989-08-25 1989-08-25 Signal processing circuit for encoder

Publications (1)

Publication Number Publication Date
JPH0382913A true JPH0382913A (en) 1991-04-08

Family

ID=16742912

Family Applications (1)

Application Number Title Priority Date Filing Date
JP21990889A Pending JPH0382913A (en) 1989-08-25 1989-08-25 Signal processing circuit for encoder

Country Status (1)

Country Link
JP (1) JPH0382913A (en)

Similar Documents

Publication Publication Date Title
JP4138899B2 (en) Phase difference detection apparatus, position detection system and method for position detection
EP0331189B1 (en) Position/speed detection method and apparatus
JPH06167354A (en) Interpolation unit for scale
JPS62162968A (en) Speed detecting device
JP2011033602A (en) Resolver/digital converter, and resolver/digital conversion method
JP3460017B2 (en) R / D converter
JPH05231879A (en) Correcting method for detecting position
JP3365063B2 (en) Rotation angle detection method
JPH11190606A (en) Rotation quantity measuring method and rotation quantity measuring device
JPH0382913A (en) Signal processing circuit for encoder
JPS61110006A (en) Position detector
JP2000337924A (en) R/d converter
JP2009288241A6 (en) Method for determining a time difference between a first event and a second event
JP3092100B2 (en) Position detector with error correction function
JP3365913B2 (en) Position detection device
JPS62237316A (en) Detection error correcting device for position detector
JPS61110005A (en) Method and apparatus for detecting position
JPS62187210A (en) Pulse distribution type position detecting device
JP3439814B2 (en) Digital PLL device
JPS6211113A (en) Position detector
JP2551680B2 (en) Position detection device
JP3009620B2 (en) Home position return method for multi-pole detection resolver and home position return device for multi-pole detection resolver
JP3391646B2 (en) Position detection device with error correction function
JPH0528486Y2 (en)
JPH04355326A (en) Rotary encoder with electrical angle output function