JP2008256657A - Encoder for motor - Google Patents

Encoder for motor Download PDF

Info

Publication number
JP2008256657A
JP2008256657A JP2007101908A JP2007101908A JP2008256657A JP 2008256657 A JP2008256657 A JP 2008256657A JP 2007101908 A JP2007101908 A JP 2007101908A JP 2007101908 A JP2007101908 A JP 2007101908A JP 2008256657 A JP2008256657 A JP 2008256657A
Authority
JP
Japan
Prior art keywords
count value
signal
multiplication
multiplied
analog
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.)
Withdrawn
Application number
JP2007101908A
Other languages
Japanese (ja)
Inventor
Nobuo Fukazawa
信夫 深沢
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.)
Mitsuba Corp
Original Assignee
Mitsuba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Mitsuba Corp filed Critical Mitsuba Corp
Priority to JP2007101908A priority Critical patent/JP2008256657A/en
Publication of JP2008256657A publication Critical patent/JP2008256657A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To prevent wrong counting in an encoder for a motor. <P>SOLUTION: This encoder 1 for the motor has an encoder substrate 3 stored in the motor, and a driver 5 connected by a cable 4 and is arranged outside the motor. The encoder substrate 3 has differential A/D converters 12, 14 for converting the analog signal of pseudo-sine wave output from an optical pick-up 11 into a digital signal, to be output serially, and comparators 13, 15 for detecting a code change of the pseudo-sine wave. Signals serially output from the differential A/D converters 12, 14 and the comparators 13, 15 are subjected to multiplication processings in a multiplication-dedicated IC 22 in the driver 5. The multiplication dedicated IC 22 has an error correction circuit 35 and corrects the combined value of counted values of the differential A/D converters 12, 14 and the counted values of the signals from the comparators 13, 15. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、モータ用エンコーダに関する。   The present invention relates to a motor encoder.

モータの回転制御をするときに、ロータの回転位置を検出するセンサとして、例えば、エンコーダを使用することがある。この種の用途に用いられるエンコーダでは、ロータの回転に従って周期関数からなるアナログ信号が発生されるので、アナログ/デジタル(以下、A/Dという)変換器でデジタルのパルス信号を作成してステータのコイルの通電を切り替えるタイミングを演算する(例えば、特許文献1参照)。   For example, an encoder may be used as a sensor for detecting the rotational position of the rotor when controlling the rotation of the motor. In an encoder used for this kind of application, an analog signal composed of a periodic function is generated according to the rotation of the rotor. Therefore, a digital pulse signal is created by an analog / digital (hereinafter referred to as A / D) converter to generate a stator signal. The timing which switches energization of a coil is calculated (for example, refer to patent documents 1).

ここで、従来のエンコーダは、モータに内蔵して使用されるエンコーダ基板がケーブルでドライバに接続される構成になっている。エンコーダ基板は、ロータに固定されたスケールの回転を検出する光学ピックアップと、光学ピックアップから出力される擬似サイン波出力が入力されるA/D変換器と、擬似コサイン波出力が入力されるA/D変換器と、各A/D変換器からのデジタル信号を4逓倍する逓倍専用IC(集積回路)と、レベル変換回路が実装されている。ここで、4逓倍のパルス信号を作成するためには、擬似サイン波や擬似コサイン波(以下、これらを総称するときは擬似正弦波という)の符号変化を常に検出していなければならない。このため、A/D変換器に要求される能力は、モータへの通電を切り替えるタイミングを演算する周期より大きい周波数でA/D変換が可能である必要がある。例えば、1周に1024個のスリットがあるスケールを使用し、6000rpm(100Hz)で回転させたときに、符号の変化を正しく判定するためには、100Hz×1024×4=409.6kHz以上の周波数でA/D変換する必要がある。このため、従来のモータ用エンコーダでは、高速差動A/D変換器を使用し、逓倍専用ICとの間の通信はパラレル通信を採用していた。
実開昭61−82216号公報
Here, the conventional encoder has a configuration in which an encoder board used in a motor is connected to a driver by a cable. The encoder board includes an optical pickup that detects rotation of a scale fixed to the rotor, an A / D converter that receives a pseudo sine wave output output from the optical pickup, and an A / D that receives a pseudo cosine wave output. A D converter, an IC (integrated circuit) for multiplying a digital signal from each A / D converter by 4 and a level conversion circuit are mounted. Here, in order to create a quadruple pulse signal, it is necessary to always detect a sign change of a pseudo sine wave or a pseudo cosine wave (hereinafter collectively referred to as a pseudo sine wave). For this reason, the capability required of the A / D converter needs to be able to perform A / D conversion at a frequency larger than the cycle for calculating the timing for switching the energization to the motor. For example, when using a scale with 1024 slits in one circle and rotating at 6000 rpm (100 Hz), a frequency of 100 Hz × 1024 × 4 = 409.6 kHz or more is necessary to correctly determine the change in sign. A / D conversion is required. For this reason, the conventional motor encoder uses a high-speed differential A / D converter, and employs parallel communication for communication with the multiplication IC.
Japanese Utility Model Publication No. 61-82216

しかしながら、モータ用エンコーダが複数の信号を使って逓倍した信号を生成するときは、信号が出力されるタイミングがずれるとカウント値が大きくずれてしまうことがあった。
また、高速差動A/D変換器は、回路のサイズが大きくなるので、エンコーダ基板を小型化することができなかった。また、高速差動A/D変換器と逓倍専用ICの間は、特許文献1に示すように多数の配線でパラレル接続する必要があった。このような配線は、エンコーダ基板の小型化を妨げる原因になっていた。さらに、逓倍専用ICもパラレル通信をするために多数の端子が必要になるので小型化が難しかった。これらの理由から、従来ではエンコーダ基板を小型化することが困難であり、エンコーダ基板を内蔵するモータの小型化も難しかった。
この発明は、このような事情に鑑みてなされたものであり、モータ用エンコーダの誤カウントを防止することを主な目的とする。
However, when the motor encoder generates a signal multiplied by using a plurality of signals, the count value may be greatly shifted if the timing at which the signal is output is shifted.
Further, since the high-speed differential A / D converter has a large circuit size, the encoder board cannot be miniaturized. In addition, as shown in Patent Document 1, it is necessary to perform parallel connection between the high-speed differential A / D converter and the multiplication-dedicated IC using a large number of wires. Such wiring has been a cause of hindering miniaturization of the encoder board. Furthermore, the multiplication-dedicated IC is also difficult to miniaturize because a large number of terminals are required for parallel communication. For these reasons, it has conventionally been difficult to reduce the size of the encoder board, and it has also been difficult to reduce the size of the motor incorporating the encoder board.
The present invention has been made in view of such circumstances, and a main object thereof is to prevent erroneous counting of a motor encoder.

上記の課題を解決する本発明の請求項1に係る発明は、モータに取り付けられる検出部と、前記モータ外に配置され、前記検出部との間でデータ通信可能に接続されたドライバとを有するモータ用エンコーダであって、前記モータの回転に伴って擬似正弦波状のアナログ信号を出力するピックアップと、前記ピックアップから出力されるアナログ信号をデジタル信号に変換してシリアル出力するアナログ/デジタル変換器と、基準電位に対するアナログ信号の符号変化に伴って信号レベルが切り替わるパルス状の符号変化信号を生成するコンパレータと、前記アナログ/デジタル変換器及び前記コンパレータから出力されるデジタル信号を受け取って、逓倍処理する逓倍部とを有し、前記逓倍部は、前記アナログ/デジタル変換器から出力されるデジタル信号から第1の逓倍カウント値を算出する第1の逓倍回路と、前記コンパレータから出力される符号変化信号の符号変化をカウントして第2の逓倍カウント値を生成する第2の逓倍回路と、第1の逓倍カウント値と第2の逓倍カウント値を合成して合成逓倍カウント値を生成する合成回路と、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差の大きさが所定の値以上になったらカウント値のずれを補正する誤カウント補正回路を有することを特徴とするモータ用エンコーダとした。
アナログ/デジタル変換器の出力タイミングとコンパレータの出力タイミングがずれていたときは、合成逓倍カウント値の今回値が前回値に対して大きく異なる値になる。したがって、今回値と前回値の差に応じて補正を行い、正しいカウント値が得られるようにする。
The invention according to claim 1 of the present invention that solves the above-described problem includes a detection unit that is attached to a motor, and a driver that is disposed outside the motor and is connected to the detection unit so as to enable data communication. A motor encoder, a pickup that outputs a pseudo sine wave analog signal as the motor rotates, an analog / digital converter that converts the analog signal output from the pickup into a digital signal and serially outputs the digital signal; A comparator that generates a pulse-like sign change signal whose signal level changes with a sign change of the analog signal with respect to a reference potential, and a digital signal output from the analog / digital converter and the comparator, and performs multiplication processing A multiplier, and the multiplier is output from the analog / digital converter. A first multiplication circuit for calculating a first multiplication count value from the digital signal, and a second multiplication circuit for generating a second multiplication count value by counting the code change of the code change signal output from the comparator And a synthesis circuit for synthesizing the first multiplied count value and the second multiplied count value to generate a synthesized multiplied count value, and a difference between the previous synthesized multiplied count value and the current synthesized multiplied count value is predetermined. The motor encoder is characterized by having an erroneous count correction circuit that corrects the deviation of the count value when the value becomes equal to or greater than.
When the output timing of the analog / digital converter is different from the output timing of the comparator, the current value of the combined multiplication count value is greatly different from the previous value. Therefore, correction is performed according to the difference between the current value and the previous value so that a correct count value is obtained.

請求項2に係る発明は、請求項1に記載のモータ用エンコーダにおいて、前記誤カウント補正回路は、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差が第1の閾値を越えたら、第2の逓倍カウント値の2カウント分補正した合成逓倍カウント値を生成し、第1の閾値未満で第2の閾値以上であったら第2の逓倍カウント値の1カウント分補正した合成逓倍カウント値を生成するように構成されていることを特徴とする。
このモータ用エンコーダは、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差が大きいときには、第2の逓倍カウント値の1カウント分又は2カウント分の補正を行う。前回の合成逓倍カウント値に対して今回の合成逓倍カウント値が第1、第2の閾値より大きいときは、それぞれ2カウント分、1カウント分だけ減算する。前回の合成逓倍カウント値に対して今回の合成逓倍カウント値が第1、第2の閾値より小さいときは、それぞれ2カウント分、1カウント分だけ加算する。
According to a second aspect of the present invention, in the motor encoder according to the first aspect, the erroneous count correction circuit is configured such that the difference between the previous combined multiplied count value and the current combined multiplied count value exceeds a first threshold value. A composite multiplication count value corrected by 2 counts of the second multiplication count value is generated, and if it is less than the first threshold and greater than or equal to the second threshold, the composite multiplication count value corrected by 1 count of the second multiplication count value It is characterized by producing | generating.
When the difference between the previous combined multiplication count value and the current combined multiplication count value is large, the motor encoder corrects the second multiplied count value by one count or two counts. When the current combined multiplied count value is larger than the first and second threshold values with respect to the previous combined multiplied count value, 2 counts and 1 count are respectively subtracted. When the current combined multiplication count value is smaller than the first and second threshold values with respect to the previous combined multiplication count value, 2 counts and 1 count are added respectively.

請求項3に係る発明は、請求項2に記載のモータ用エンコーダにおいて、第1の閾値は、第2の逓倍カウント値の1.5カウントに相当する値であり、第2の閾値は、第2の逓倍カウント値の0.5カウントに相当する値であることを特徴とする。
このモータ用エンコーダは、第2の逓倍カウント値のカウントアップ又はカウントダウンのタイミングがずれたときに合成逓倍カウント値の誤差が大きくなることに着目し、第2の逓倍カウント値に対応付けて補正する。
According to a third aspect of the present invention, in the motor encoder according to the second aspect, the first threshold value is a value corresponding to 1.5 counts of the second multiplied count value, and the second threshold value is It is a value corresponding to 0.5 count of 2 multiplied count value.
The motor encoder pays attention to the fact that the error of the combined multiplied count value becomes large when the timing of counting up or counting down the second multiplied count value is shifted, and corrects it in association with the second multiplied count value. .

請求項4に係る発明は、請求項1から請求項3のいずれか一項に記載のモータ用エンコーダにおいて、前記ピックアップは、周期が1/4異なる擬似サイン波信号と擬似コサイン波信号を出力し、前記アナログ/デジタル変換器及び前記コンパレータは、擬似サイン波信号が入力される第1のアナログ/デジタル変換器及び第1のコンパレータと、擬似コサイン波信号が入力される第2のアナログ/デジタル変換器及び第2のコンパレータを有することを特徴とする。
このモータ用エンコーダは、ピックアップが位相の異なる2種類のアナログ信号を発生させる。このため、アナログ/デジタル変換器及びコンパレータがそれぞれ2つずつ検出部に設けられ、それぞれに対応したデジタル信号がモータ外のドライバに送られて逓倍処理される。
According to a fourth aspect of the present invention, in the motor encoder according to any one of the first to third aspects, the pickup outputs a pseudo sine wave signal and a pseudo cosine wave signal having a period different by ¼. The analog / digital converter and the comparator include a first analog / digital converter and a first comparator to which a pseudo sine wave signal is input, and a second analog / digital conversion to which the pseudo cosine wave signal is input. And a second comparator.
In this motor encoder, the pickup generates two types of analog signals having different phases. For this reason, two analog / digital converters and two comparators are provided in the detection unit, respectively, and corresponding digital signals are sent to a driver outside the motor and multiplied.

請求項5に係る発明は、請求項1から請求項4のいずれか一項に記載のモータ用エンコーダにおいて、前記アナログ/デジタル変換器及び前記コンパレータを前記検出部に設け、前記逓倍部を前記ドライバに設けたことを特徴とする。
このモータ用エンコーダは、逓倍処理を行う逓倍部がモータ外に配置される。アナログ/デジタル変換器からシリアル出力されたデジタルデータは、ドライバに送られてからデータ処理される。検出部から出力されるアナログ信号の符号変化は、コンパレータの出力を参照すれば調べられるのでアナログ/デジタル変換器の信号出力頻度を低くできる。
According to a fifth aspect of the present invention, in the motor encoder according to any one of the first to fourth aspects, the analog / digital converter and the comparator are provided in the detection unit, and the multiplication unit is the driver. It is characterized by being provided in.
In this motor encoder, a multiplication unit that performs multiplication processing is arranged outside the motor. The digital data serially output from the analog / digital converter is sent to the driver and processed. Since the change in the sign of the analog signal output from the detection unit can be checked by referring to the output of the comparator, the signal output frequency of the analog / digital converter can be lowered.

本発明によれば、アナログ/デジタル変換器とコンパレータを用いて合成逓倍カウント値を作成するようにしたので簡単な構成でモータの回転検出が行える。この際に、アナログ/デジタル変換器とコンパレータの信号出力のタイミングがずれたときは、誤カウント補正回路で合成逓倍カウント値が補正されるので、正しいカウント値が得られる。   According to the present invention, since the combined multiplication count value is created using the analog / digital converter and the comparator, the rotation of the motor can be detected with a simple configuration. At this time, if the signal output timings of the analog / digital converter and the comparator are shifted, the combined multiplication count value is corrected by the erroneous count correction circuit, so that a correct count value can be obtained.

発明を実施するための最良の形態について図面を参照しながら詳細に説明する。
エンコーダ1は、モータのロータの回転軸に固定されるスケール2を含み、モータ内に搭載されるエンコーダ基板3と、ケーブル4を介して接続されるドライバ5とを有する。
The best mode for carrying out the invention will be described in detail with reference to the drawings.
The encoder 1 includes a scale 2 fixed to the rotation shaft of the rotor of the motor, and includes an encoder board 3 mounted in the motor and a driver 5 connected via a cable 4.

スケール2は、不透明な円盤にスリット列を設けた構成になっている。スリット列は、擬似正弦波を出力するために周方向にスリットが設けられている。スリットは、周方向に多数、例えば、1024個設けられた第1のスリット列と、周方向に1箇所だけ設けた第2のスリットを有する。第1のスリット列は、ロータの回転角度を検出するために用いられる。第2のスリットは、モータの回転回数を計測したり、エンコーダ1のカウント値をリセットしたりする際に使用される。なお、スケール2は、ガラス等の円盤に光を反射する部分と反射しない部分が周方向に等間隔に設けた構成でも良い。   The scale 2 has a configuration in which slit rows are provided in an opaque disk. The slit row is provided with slits in the circumferential direction in order to output a pseudo sine wave. The slit has a large number of, for example, 1024 first slit rows provided in the circumferential direction, and a second slit provided only at one location in the circumferential direction. The first slit row is used to detect the rotation angle of the rotor. The second slit is used when measuring the number of rotations of the motor or resetting the count value of the encoder 1. Note that the scale 2 may have a configuration in which a portion that reflects light and a portion that does not reflect light on a disk such as glass are provided at equal intervals in the circumferential direction.

エンコーダ基板3は、スケール2に近接して配置される光ピックアップ11を有する検出部である。光ピックアップ11の出力は、エンコーダ基板3に搭載された第1の差動A/D変換器12、第1のコンパレータ13、第2の差動A/D変換器14及び第2のコンパレータ15に接続されている。さらに、信号を送受信する際に使用するレベル変換回路16も実装されている。   The encoder board 3 is a detection unit having an optical pickup 11 arranged close to the scale 2. The output of the optical pickup 11 is sent to the first differential A / D converter 12, the first comparator 13, the second differential A / D converter 14 and the second comparator 15 mounted on the encoder board 3. It is connected. Furthermore, a level conversion circuit 16 used when transmitting and receiving signals is also mounted.

光ピックアップ11は、透過型であれば発光素子と受光素子がスケール2のスリットを挟んで配置され、反射型であれば発光素子と受光素子がスケール2の同じ側に配置され、スケール2が回転したときに第1のスリット列に対応して周期的に変化するアナログ信号が出力される。この実施の形態では、アナログ信号として、擬似正弦波信号である擬似サイン波信号と、擬似サイン波信号に対して位相が1/4周期ずれた擬似正弦波信号である擬似コサイン波信号とを発生するように構成されている。光ピックアップ11は、基準電位に対する差動出力として擬似サイン波信号及び擬似コサイン波信号を出力する。具体的には、擬似サイン波信号は、基準電位からのプラス成分である擬似サインプラス信号Asin1と、基準電位からのマイナス成分である擬似サインマイナス信号Asin2として出力される。同様に、擬似サイン波信号は、基準電位からのプラス成分である擬似コサインプラス信号Acos1と、基準電位からのマイナス成分である擬似コサインマイナス信号Acos2として出力する。さらに、スケール2が一回転する度に第2のスリットに対応して1回出力されるインデックス信号Ixがレベル変換回路16に出力される。   If the optical pickup 11 is a transmissive type, the light emitting element and the light receiving element are arranged with the slit of the scale 2 interposed therebetween, and if the optical pickup 11 is a reflection type, the light emitting element and the light receiving element are arranged on the same side of the scale 2 In this case, an analog signal that periodically changes corresponding to the first slit row is output. In this embodiment, as an analog signal, a pseudo sine wave signal that is a pseudo sine wave signal and a pseudo cosine wave signal that is a pseudo sine wave signal whose phase is shifted by ¼ period from the pseudo sine wave signal are generated. Is configured to do. The optical pickup 11 outputs a pseudo sine wave signal and a pseudo cosine wave signal as differential outputs with respect to the reference potential. Specifically, the pseudo sine wave signal is output as a pseudo sine plus signal Asin1 that is a plus component from the reference potential and a pseudo sine minus signal Asin2 that is a minus component from the reference potential. Similarly, the pseudo sine wave signal is output as a pseudo cosine plus signal Acos1 that is a plus component from the reference potential and a pseudo cosine minus signal Acos2 that is a minus component from the reference potential. Further, an index signal Ix that is output once corresponding to the second slit is output to the level conversion circuit 16 every time the scale 2 rotates once.

第1の差動A/D変換器12は、光ピックアップ11から出力される擬似サインプラス信号Asin1と擬似サインマイナス信号Asin2をA/D変換し、アナログの擬似サイン波信号をデジタル化した第1のデジタル信号Dsinをシリアル出力する。
第2の差動A/D変換器14は、光ピックアップ11から出力される擬似コサインプラス信号Acos1と擬似コサインマイナス信号Acos2をA/D変換し、アナログの擬似コサイン波信号をデジタル化した第2のデジタル信号Dcosをシリアル出力する。
各差動A/D変換器12,14には、レベル変換回路16から制御信号AD1及びクロック信号AD2が入力され、第1、第2のデジタル信号Dsin,Dcosが一定時間ごとに同期して出力されるようになっている。
The first differential A / D converter 12 performs A / D conversion on the pseudo sine plus signal Asin1 and the pseudo sine minus signal Asin2 output from the optical pickup 11, and digitizes the analog pseudo sine wave signal. The digital signal Dsin is serially output.
The second differential A / D converter 14 performs A / D conversion on the pseudo cosine plus signal Acos1 and the pseudo cosine minus signal Acos2 output from the optical pickup 11, and digitizes the analog pseudo cosine wave signal. The digital signal Dcos is serially output.
Each of the differential A / D converters 12 and 14 receives the control signal AD1 and the clock signal AD2 from the level conversion circuit 16, and outputs the first and second digital signals Dsin and Dcos in synchronization with each other at a predetermined time. It has come to be.

第1のコンパレータ13は、光ピックアップ11から出力される擬似サインプラス信号Asin1と擬似サインマイナス信号Asin2から擬似サイン波信号の符号変化信号Csinをシリアル出力する。符号変化信号Csinは、擬似サイン波信号が基準電位に対してプラス側の値であるか、マイナス側の値であるかを示す信号である。
第2のコンパレータ15は、光ピックアップ11から出力される擬似コサインプラス信号Acos1と擬似コサインマイナス信号Acos2から擬似サイン波信号の符号変化信号Ccosをシリアル出力する。符号変化信号Ccosは、擬似コサイン波信号が基準電位に対してプラス側の値であるか、マイナス側の値であるかを示す信号である。
The first comparator 13 serially outputs a sign change signal Csin of a pseudo sine wave signal from the pseudo sine plus signal Asin1 and the pseudo sine minus signal Asin2 output from the optical pickup 11. The sign change signal Csin is a signal indicating whether the pseudo sine wave signal is a positive value or a negative value with respect to the reference potential.
The second comparator 15 serially outputs a sign change signal Ccos of a pseudo sine wave signal from the pseudo cosine plus signal Acos1 and the pseudo cosine minus signal Acos2 output from the optical pickup 11. The sign change signal Ccos is a signal indicating whether the pseudo cosine wave signal is a positive value or a negative value with respect to the reference potential.

レベル変換回路16は、各差動A/D変換器12,14及び各コンパレータ13,15からシリアル出力されるデジタル信号Dsin,Dcos,Csin,Ccosと、インデックス信号Ixが入力され、ケーブル4の信号線を通してドライバ5に出力するように構成されている。レベル変換回路16は、RS−422やLVDS(Low Voltage Differential Signaling)等に規格に則った差動信号に変換してケーブル4からデータをドライバ5に送信することで、耐ノイズ性を向上させている。また、ケーブル4を介してエンコーダ基板3の各回路に電力が供給される。   The level conversion circuit 16 receives the digital signals Dsin, Dcos, Csin, Ccos serially output from the differential A / D converters 12 and 14 and the comparators 13 and 15, and the index signal Ix, and the signal of the cable 4 It is configured to output to the driver 5 through a line. The level conversion circuit 16 improves the noise resistance by converting the differential signal according to the standard to RS-422, LVDS (Low Voltage Differential Signaling), etc., and transmitting the data from the cable 4 to the driver 5. Yes. Further, power is supplied to each circuit of the encoder board 3 via the cable 4.

ここで、各差動A/D変換器12,14からデジタル信号を受け取るために必要な端子数は、2つである。同様に、各コンパレータ13,15から符号変化信号Csin,Ccosを受け取るために必要な端子数も2つである。これに制御信号AD1及びクロック信号AD2を出力する端子と、インデックス信号Ix用の端子を合わせてもレベル変換回路16のデータ入力に必要な端子数は7個で済む。これに対して、従来のA/D変換器のようにパラレル通信を行う場合、例えば、12ビットのデータ出力では12個の端子と、信号AD1,AD2,Ix用の3つの端子の合計15の端子が必要であった。
また、パラレル出力された12ビットのデータをケーブル4で送信する場合には、12本の信号線が必要であり、差動信号を使用する場合には12×2=24本の信号線が必要になる。これに対して、レベル変換回路16は、差動信号を使用する場合でも、4×2=8本の信号線で足りる。
Here, the number of terminals required for receiving digital signals from the differential A / D converters 12 and 14 is two. Similarly, the number of terminals necessary for receiving the sign change signals Csin and Ccos from the comparators 13 and 15 is two. Even if the terminal for outputting the control signal AD1 and the clock signal AD2 and the terminal for the index signal Ix are combined, the number of terminals required for data input of the level conversion circuit 16 is only seven. On the other hand, when performing parallel communication like a conventional A / D converter, for example, in 12-bit data output, a total of 15 terminals including 12 terminals and 3 terminals for signals AD1, AD2, and Ix. A terminal was required.
When transmitting 12-bit data output in parallel via the cable 4, 12 signal lines are required, and when using differential signals, 12 × 2 = 24 signal lines are required. become. On the other hand, the level conversion circuit 16 needs only 4 × 2 = 8 signal lines even when a differential signal is used.

ドライバ5は、レベル変換回路21と、逓倍部である逓倍専用IC22と、制御用のCPU(中央演算装置)23とを有する。
逓倍専用IC22は、エンコーダ基板3から出力された信号が入力されるインターフェイス回路31と、A/D変換したデジタル信号Dsin,Dcosを逓倍する第1の逓倍回路32と、符号変換信号Csin,Ccosから逓倍のパルス信号を作成してカウントアップ又はカウントダウンを行う第2の逓倍回路である2相エンコーダ用カウンタ33と、合成逓倍カウント値生成回路34と、誤カウントを補正する誤カウント補正回路35とを有する。
The driver 5 includes a level conversion circuit 21, a multiplication-dedicated IC 22 that is a multiplication unit, and a control CPU (central processing unit) 23.
The multiplication-dedicated IC 22 includes an interface circuit 31 to which a signal output from the encoder board 3 is input, a first multiplication circuit 32 that multiplies the A / D converted digital signals Dsin and Dcos, and code conversion signals Csin and Ccos. A two-phase encoder counter 33 that is a second multiplication circuit that creates a multiplied pulse signal and counts up or down, a combined multiplied count value generation circuit 34, and an erroneous count correction circuit 35 that corrects erroneous counting. Have.

合成逓倍カウント値生成回路34は、第1の逓倍回路32で生成した第1の逓倍カウント値と、2相エンコーダ用カウンタ33で生成した第2の逓倍カウント値とを合成して合成逓倍カウント値を生成する。
図2に示すように、誤カウント補正回路35は、補正前のカウント値が入力される引き算回路41及び補正回路42を有し、補正回路42で補正したカウント値を出力する構成になっている。補正したカウント値は、保存用レジスタ43に記憶され、必要に応じて引き算回路41に補正後のカウント値を入力可能になっている。引き算回路41の出力は、補正回路42の入力に接続されている。
The synthesized multiplication count value generation circuit 34 synthesizes the first multiplication count value generated by the first multiplication circuit 32 and the second multiplication count value generated by the counter 33 for the two-phase encoder, thereby synthesizing the multiplication count value. Is generated.
As shown in FIG. 2, the erroneous count correction circuit 35 includes a subtraction circuit 41 and a correction circuit 42 to which the count value before correction is input, and is configured to output the count value corrected by the correction circuit 42. . The corrected count value is stored in the storage register 43, and the corrected count value can be input to the subtraction circuit 41 as necessary. The output of the subtraction circuit 41 is connected to the input of the correction circuit 42.

次に、この実施の形態のエンコーダ1でモータの回転検出を行う処理について説明する。
モータのロータが回転すると、回転軸に固定されたスケール2が一緒に回転する。光学ピックアップ11の発光素子から出射された光は、スケール2を透過又は反射して受光素子に入力される。光学ピックアップ11からは、受光素子で受光した光の光量に応じてアナログ信号が出力される。アナログ信号は、擬似的な正弦波形になっており、スケール2や発光素子、受光素子の配置によって位相が90度ずれた第1の擬似信号と第2の擬似信号が出力される。以下、第1の擬似信号を擬似サイン波信号とし、第2の擬似信号を擬似コサイン波信号とする。この光学ピックアップ11は、基準電位からの差動信号を出力するように構成されているので、図3に示すように、擬似サイン波信号は、基準電位より電位が高い成分からなる擬似サインプラス信号Asin1と、基準電位より電位が低い成分からなる擬似サインマイナス信号Asin2とが出力される。同様に、擬似コサイン波信号は、基準電位より電位が高い成分からなる擬似コサインプラス信号Acos1と、基準電位より電位が低い成分からなる擬似コサインマイナス信号Acos2とが出力される。
Next, processing for detecting rotation of the motor by the encoder 1 of this embodiment will be described.
When the rotor of the motor rotates, the scale 2 fixed to the rotating shaft rotates together. Light emitted from the light emitting element of the optical pickup 11 is transmitted or reflected through the scale 2 and input to the light receiving element. An optical signal is output from the optical pickup 11 in accordance with the amount of light received by the light receiving element. The analog signal has a pseudo sine waveform, and a first pseudo signal and a second pseudo signal whose phases are shifted by 90 degrees depending on the arrangement of the scale 2, the light emitting element, and the light receiving element are output. Hereinafter, the first pseudo signal is a pseudo sine wave signal and the second pseudo signal is a pseudo cosine wave signal. Since the optical pickup 11 is configured to output a differential signal from a reference potential, as shown in FIG. 3, the pseudo sine wave signal is a pseudo sine plus signal composed of a component having a higher potential than the reference potential. Asin1 and a pseudo sign minus signal Asin2 composed of a component whose potential is lower than the reference potential are output. Similarly, the pseudo cosine wave signal outputs a pseudo cosine plus signal Acos1 composed of a component having a higher potential than the reference potential and a pseudo cosine minus signal Acos2 composed of a component having a potential lower than the reference potential.

擬似サインプラス信号Asin1及び擬似サインマイナス信号Asin2は、差動A/D変換器12と第1のコンパレータ13のそれぞれに入力される。差動A/D変換器12は、制御信号AD1の指令を受けて一定時間ごとに擬似サインプラス信号Asin1及び擬似サインマイナス信号Asin2をデジタル変換して第1のデジタル信号Dsinを作成し、レベル変換回路16にシリアル出力する。第1のデジタル信号Dsinを作成する頻度は、擬似正弦波の周波数以下の頻度で良い。
第1のコンパレータ13では、擬似サインプラス信号Asin1と擬似サインマイナス信号Asin2を比較して符号変化信号Csinを作成してシリアル出力する。この結果、図3に示すように、擬似サイン波信号の変化に応じてHighレベルとLowレベルが入れ替わるパルス信号になる。
The pseudo sine plus signal Asin1 and the pseudo sine minus signal Asin2 are input to the differential A / D converter 12 and the first comparator 13, respectively. The differential A / D converter 12 receives the command of the control signal AD1 and digitally converts the pseudo sine plus signal Asin1 and the pseudo sine minus signal Asin2 at regular intervals to create a first digital signal Dsin, and performs level conversion. Serial output to the circuit 16. The frequency of generating the first digital signal Dsin may be a frequency equal to or lower than the frequency of the pseudo sine wave.
The first comparator 13 compares the pseudo sine plus signal Asin1 and the pseudo sine minus signal Asin2 to create a sign change signal Csin and serially outputs it. As a result, as shown in FIG. 3, a pulse signal in which the high level and the low level are switched in accordance with the change in the pseudo sine wave signal is obtained.

擬似コサインプラス信号Acos1及び擬似コサインマイナス信号Acos2は、差動A/D変換器14と第2のコンパレータ15のそれぞれに入力される。差動A/D変換器14は、前記と同様に、制御信号AD1の指令を受けて一定時間ごとにアナログ信号をデジタル変換して第2のデジタル信号Dcosに作成し、レベル変換回路16にシリアル出力する。第2のデジタル信号Dcosは、第1のデジタル信号Dsinと同期して作成される。
第2のコンパレータ15では、擬似コサイン波信号についての符号変化信号Ccosを作成してシリアル出力する。この結果、図3に示すように、擬似コサイン波信号の変化に応じてHighレベルとLowレベルが入れ替わるパルス信号になる。符合変化信号Ccosは、符号変化信号Csinに対して擬似正弦波の周期で1/4周期ずれたパルス信号になる。
The pseudo cosine plus signal Acos 1 and the pseudo cosine minus signal Acos 2 are input to the differential A / D converter 14 and the second comparator 15, respectively. In the same manner as described above, the differential A / D converter 14 receives the command of the control signal AD 1, converts the analog signal into a second digital signal Dcos at a predetermined time, and generates a second digital signal Dcos. Output. The second digital signal Dcos is generated in synchronization with the first digital signal Dsin.
The second comparator 15 generates a sign change signal Ccos for the pseudo cosine wave signal and serially outputs it. As a result, as shown in FIG. 3, a pulse signal in which the high level and the low level are switched in accordance with the change in the pseudo cosine wave signal is obtained. The sign change signal Ccos is a pulse signal that is shifted from the sign change signal Csin by a quarter of the period of the pseudo sine wave.

各差動A/D変換器12,14及び各コンパレータ13,15から出力されたデジタル信号は、レベル変換回路16及びケーブル4を介してドライバ5に送信される。ドライバ5では、デジタル信号がレベル変換回路21から逓倍専用IC22に受け渡される。逓倍専用IC22は、CPU23の制御下でデータ処理を行う。
2相エンコーダカウンタ33は、符号変化信号Csin,Ccosの符号の変化を調べて符号の変化から回転方向を検出する。例えば、図3の符号変化信号Csin,Ccosのように、時間経過に従って擬似コサイン波信号についての符号変化信号Ccosと擬似サイン波信号についての符号変化信号Csinの信号レベルの組み合わせが(Hihg、High)の次に(Low,High)に切り替わるとき、つまり符号変化信号Ccosが符号変化信号Csinより先行して変化するときはモータが反時計回りしているとみなし、符号が切り替わるごとにカウントアップする。
Digital signals output from the differential A / D converters 12 and 14 and the comparators 13 and 15 are transmitted to the driver 5 via the level conversion circuit 16 and the cable 4. In the driver 5, the digital signal is transferred from the level conversion circuit 21 to the multiplication-dedicated IC 22. The multiplication dedicated IC 22 performs data processing under the control of the CPU 23.
The two-phase encoder counter 33 checks the sign change of the sign change signals Csin and Ccos and detects the rotation direction from the sign change. For example, like the code change signals Csin and Ccos in FIG. 3, the combination of the signal level of the code change signal Ccos for the pseudo cosine wave signal and the code change signal Csin for the pseudo sine wave signal with the passage of time is (Hihg, High). Is switched to (Low, High), that is, when the sign change signal Ccos changes prior to the sign change signal Csin, the motor is considered to be counterclockwise and is counted up each time the sign is switched.

例えば、カウント開始時のカウント数が「n」であった場合、符号変化信号Csin,Ccosのいずれかの符号が変化する度に、「n+1」、「n+2」、「n+3」、「n+4」、「n+5」、「n+6」、「n+7」とカウントアップするような4逓倍カウント値が第2の逓倍カウント値として算出される。   For example, when the count number at the start of counting is “n”, every time the sign of the sign change signal Csin, Ccos changes, “n + 1”, “n + 2”, “n + 3”, “n + 4”, A quadruple count value that counts up as “n + 5”, “n + 6”, and “n + 7” is calculated as the second multiple count value.

さらに、第1の逓倍回路32は、擬似サイン波信号及び擬似コサイン波信号をA/D変換したデジタル信号Dsin,Dcosから第1の逓倍カウント値を算出する。第1の逓倍カウント値は、擬似正弦波の位相tan−1(第1のデジタル信号Dsinの値/第2のデジタル信号Dcos)から演算される。この実施の形態では、ラインL1に示すように、スケール2のスリットの数に対応して1024カウントまでカウントアップしてからリセットされるような信号になる。 Further, the first multiplication circuit 32 calculates a first multiplication count value from digital signals Dsin and Dcos obtained by A / D converting the pseudo sine wave signal and the pseudo cosine wave signal. The first multiplication count value is calculated from the phase tan −1 of the pseudo sine wave (value of the first digital signal Dsin / second digital signal Dcos). In this embodiment, as indicated by the line L1, the signal is reset after being counted up to 1024 counts corresponding to the number of slits of the scale 2.

第1、第2の逓倍カウント値は、合成逓倍カウント値生成回路34において合成され、ラインL2に示すように、4逓倍のパルス信号で段階的にカウントアップした値(ラインL2a参照)に、1つのカウント値の間をリニアに補完するような合成逓倍カウント値が得られる。なお、合成逓倍カウント値の算出例として、この実施の形態では、第1の逓倍カウント値の下位8ビットの信号(ラインL3参照)に、第2の逓倍カウント値を256倍した値を加算している。   The first and second multiplied count values are synthesized by the synthesized multiplied count value generation circuit 34, and as indicated by the line L2, the value counted up stepwise by the quadruple pulse signal (see the line L2a) is 1 A combined multiplication count value that linearly complements between the two count values is obtained. As an example of calculating the combined multiplication count value, in this embodiment, a value obtained by multiplying the second multiplication count value by 256 is added to the lower 8-bit signal (see line L3) of the first multiplication count value. ing.

一方、モータが逆回転したときは、図4に示すような擬似サイン波信号及び擬似コサイン波信号が得られる。このとき、符号変化信号Csin,Ccosの信号レベルの組み合わせは、符号変化信号Ccosに先行して符号変化信号Csinが変化する。ドライバ5は、モータが時計回りしているとみなし、符号が切り替わるごとにカウントダウンする。
例えば、カウント開始時のカウント数が「n」であった場合、符号変化信号Csin,Ccosのいずれかの符号が変化する度に、「n−1」、「n−2」、「n−3」、「n−4」、「n−5」、「n−6」、「n−7」とカウントダウンするような第2の逓倍カウント値が得られる。
On the other hand, when the motor rotates in reverse, a pseudo sine wave signal and a pseudo cosine wave signal as shown in FIG. 4 are obtained. At this time, the combination of the signal levels of the code change signals Csin and Ccos changes the code change signal Csin prior to the code change signal Ccos. The driver 5 assumes that the motor is rotating clockwise, and counts down every time the code is switched.
For example, when the count number at the start of counting is “n”, every time the sign of the sign change signal Csin, Ccos changes, “n−1”, “n-2”, “n-3” ”,“ N−4 ”,“ n−5 ”,“ n−6 ”, and“ n−7 ”, the second multiplied count value is obtained.

第1の逓倍回路32は、デジタル信号Dsin,Dcosから擬似正弦波の位相tan−1を算出して第1の逓倍カウント値を生成する。ラインL4に示すように、スケール2のスリットの数に対応して1024カウントからカウントダウンしてカウント値がゼロになったらリセットされるような信号になる。合成逓倍カウント値生成回路34は、ラインL5に示すように、4逓倍の第2のカウント値で段階的にカウントダウンするときに(ラインL5a参照)、1つのカウント値の間をリニアに補完するような合成逓倍カウント値を生成する。この場合も第1の逓倍カウント値の下位8ビットの信号(ラインL6参照)に、第2の逓倍カウント値を256倍した値を加算している。 The first multiplication circuit 32 calculates the phase tan −1 of the pseudo sine wave from the digital signals Dsin and Dcos and generates a first multiplication count value. As indicated by the line L4, the signal counts down from 1024 corresponding to the number of slits of the scale 2 and is reset when the count value becomes zero. The combined multiplication count value generation circuit 34 linearly complements between one count value when counting down step by step with the second count value multiplied by four (see line L5a), as indicated by line L5. A composite multiplication count value is generated. Also in this case, a value obtained by multiplying the second multiplied count value by 256 is added to the lower 8 bits of the first multiplied count value (see line L6).

さらに、合成逓倍カウント値は、誤カウント補正回路35に入力され、誤カウントがあった場合には補正される。誤カウント補正回路35の処理を図5のフローチャートに示す。誤カウント補正回路35は、予め前回の合成逓倍カウント値を保存用レジスタ43に保存しておく(ステップS101)。今回の合成逓倍カウント値が新しく入力されたら、引き算回路41が前回の合成逓倍カウント値と、新しく入力された今回の合成逓倍カウント値の差を算出する(ステップS102)。引き算の結果は、補正回路42に入力される。補正回路42は、差が第2の逓倍カウント値である4逓倍カウント値の1.5カウント分より大きいときは(ステップS103でYes)、4逓倍カウント値を2カウント分減らす(ステップS104)。差が4逓倍カウント値の1.5カウント分より小さく(ステップS103でNo)、かつ4逓倍カウント値の0.5カウント分より大きいときは(ステップS105でYes)4逓倍カウント値を1カウント分減らす(ステップS106)。   Further, the combined multiplication count value is input to the erroneous count correction circuit 35 and is corrected when there is an erroneous count. The processing of the erroneous count correction circuit 35 is shown in the flowchart of FIG. The erroneous count correction circuit 35 stores the previous combined multiplication count value in the storage register 43 in advance (step S101). When the current combined multiplication count value is newly input, the subtraction circuit 41 calculates a difference between the previous combined multiplication count value and the newly input current combined multiplication count value (step S102). The result of the subtraction is input to the correction circuit 42. When the difference is larger than 1.5 counts of the 4th count value that is the second multiplied count value (Yes in step S103), the correction circuit 42 decreases the 4th count value by 2 counts (step S104). When the difference is less than 1.5 counts of the quadruple count value (No in step S103) and larger than 0.5 counts of the quadruple count value (Yes in step S105), the quadruple count value is one count. Decrease (step S106).

これに対して、差が4逓倍カウント値の−1.5カウント分より小さいときは(ステップS107でYes)、4逓倍カウント値を2カウント分増やす(ステップS108)。差が4逓倍カウント値の−1.5カウント分より大きく(ステップS107でNo)、かつ4逓倍カウント値の−0.5カウント分より小さいときは(ステップS109でYes)4逓倍カウント値を1カウント分増やす(ステップS110)。それ以外の場合は、カウント値を修正しない。つまり、今回の合成逓倍カウント値と、保存用レジスタ43に記憶されている前回の合成逓倍カウント値の差を調べ、差が第1の閾値(差がプラスマイナスのそれぞれについて1.5カウント分)を越えているか、差が第1の閾値から第2の閾値(差がプラスマイナスのそれぞれについて0.5カウント分)までの間にあるかによって、異なる補正値を選択する。   On the other hand, when the difference is less than −1.5 counts of the 4-fold count value (Yes in step S107), the 4-fold count value is increased by 2 counts (step S108). When the difference is larger than the -1.5 count of the quadruple count value (No in step S107) and smaller than the -0.5 count of the quadruple count value (Yes in step S109), the quadruple count value is set to 1. The count is increased (step S110). In other cases, the count value is not corrected. In other words, the difference between the current combined multiplication count value and the previous combined multiplication count value stored in the storage register 43 is examined, and the difference is the first threshold value (1.5 counts for each difference of plus or minus). Or a different correction value is selected depending on whether the difference is between the first threshold value and the second threshold value (0.5 counts for each of plus and minus differences).

ここで、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差が4逓倍カウント値の0.5カウントより大きく、1.5カウント以下の場合(ステップS105でYesに相当)について、図6を参照して具体的に説明する。
符号変化信号Csin,Ccosは、本来であれば、一部破線で示すように、擬似コサイン波信号や擬似サイン波信号が基準電位とクロスする位置で符号が切り替わる筈であるが、アナログ式の第1、第2のコンパレータ13,15のクロス点の検出タイミングと、A/D変換のサンプルホールドタイミングとに回路の遅延等によって誤差が生じることがある。例えば、実線で示す符号変化信号Csin,Ccosのように実際のクロス点より手前のタイミングで符号変化が生じたとみなされたときは、ラインL2に示すように、対応する位置のカウント値が不連続に大きくなる。第2の逓倍カウント値である4逓倍カウント値がラインL2aに示すように早いタイミングで「n+2」にカウントアップされ、これに第1の逓倍カウント値を加算した値が大きくなってしまうからである。
そこで、この場合には、ステップS106で4逓倍カウント値を1カウント分減らして合成逓倍カウント値を演算すれば、一部を破線で示すラインL7に示すように、連続したカウント値が得られるようになる。
Here, when the difference between the previous combined multiplied count value and the current combined multiplied count value is larger than 0.5 count of the 4 multiplied count value and not more than 1.5 count (corresponding to Yes in step S105), FIG. It demonstrates concretely with reference to.
The sign change signals Csin and Ccos are supposed to change in sign at a position where the pseudo cosine wave signal or the pseudo sine wave signal crosses the reference potential as shown in part by broken lines. An error may occur between the detection timing of the cross point of the first and second comparators 13 and 15 and the sample / hold timing of the A / D conversion due to a delay of the circuit. For example, when it is determined that a sign change has occurred at a timing before the actual cross point as indicated by the sign change signals Csin and Ccos indicated by the solid line, the count value at the corresponding position is discontinuous as indicated by the line L2. Become bigger. This is because the quadruple count value that is the second multiple count value is counted up to “n + 2” at an early timing as indicated by the line L2a, and the value obtained by adding the first multiple count value to this increases. .
Therefore, in this case, if the combined multiplied count value is calculated by reducing the multiplied count value by one count in step S106, a continuous count value can be obtained as indicated by a line L7 partially shown by a broken line. become.

また、第2の逓倍カウント値で「n+4」から「n+5」にカウントアップするときのように実際のクロス点より遅れて符号変化が生じたとみなされたときは、ラインL2に示すように、対応する位置のカウント値が不連続に小さくなる。第2の逓倍カウント値である4逓倍カウント値がラインL2aに示すように遅れたタイミングで「n+5」にカウントアップされ、これに第1の逓倍カウント値を加算した値が小さくなってしまうからである。
そこで、この場合には、ステップS110で4逓倍カウント値を1カウント分増やして合成逓倍カウント値を演算すれば、一部を破線で示すラインL7に示すように、連続したカウント値が得られるようになる。
Also, when it is considered that the sign change has occurred behind the actual cross point, such as when counting up from “n + 4” to “n + 5” with the second multiplication count value, as shown in line L2, The count value at the position to be reduced becomes discontinuously small. The quadruple count value, which is the second multiple count value, is counted up to “n + 5” at a delayed timing as shown by the line L2a, and the value obtained by adding the first multiple count value to this becomes small. is there.
Therefore, in this case, if the combined multiplication count value is calculated by increasing the quadruple count value by one count in step S110, a continuous count value can be obtained as indicated by a line L7 partially shown by a broken line. become.

この実施の形態では、逓倍専用IC22をドライバ5側に搭載したので、モータ内に収容されるエンコーダ基板3に大型のICを搭載する必要がなくなり、エンコーダ基板3を小型化できる。
シリアル出力するA/D変換器12,14を使用したので、A/D変換器12,14とレベル変換回路16の間の信号ラインの数を削減でき、エンコーダ基板3を小型化できる。A/D変換器12,14を高速処理を行うタイプに比べて小型化できることもエンコーダ基板3の小型化に貢献する。シリアル出力を使用することでケーブル4に必要な信号線の数を減らせるのでケーブル4を細くできる。ケーブル4の信号線が減ることで、ケーブル4をエンコーダ基板3に接続するためのコネクタも小さくでき、エンコーダ基板3をさらに小型化できる。
シリアル出力するA/D変換器12,14では、データ変換の頻度が擬似正弦波の符号変化の頻度を下回ることがあるが、符号の変化はコンパレータ13,14の出力から判定できるので、第2の逓倍カウント値をベースにA/D変換したときのカウント値を加算すれば正確なカウント値が得られる。このため、A/D変換器12,14のデータ変換の頻度が少なくてもモータの回転検出を確実に行える。
In this embodiment, since the multiplication-dedicated IC 22 is mounted on the driver 5 side, it is not necessary to mount a large IC on the encoder board 3 accommodated in the motor, and the encoder board 3 can be reduced in size.
Since the serial output A / D converters 12 and 14 are used, the number of signal lines between the A / D converters 12 and 14 and the level conversion circuit 16 can be reduced, and the encoder board 3 can be downsized. The fact that the A / D converters 12 and 14 can be downsized as compared with the type that performs high-speed processing also contributes to downsizing of the encoder board 3. Since the number of signal lines required for the cable 4 can be reduced by using the serial output, the cable 4 can be made thinner. Since the number of signal lines of the cable 4 is reduced, the connector for connecting the cable 4 to the encoder board 3 can be reduced, and the encoder board 3 can be further reduced in size.
In the A / D converters 12 and 14 that output serially, the frequency of data conversion may be lower than the frequency of the sign change of the pseudo sine wave. However, since the sign change can be determined from the outputs of the comparators 13 and 14, the second An accurate count value can be obtained by adding the count values obtained when A / D conversion is performed based on the multiplied count value. For this reason, even if the frequency of data conversion of the A / D converters 12 and 14 is small, the rotation detection of the motor can be reliably performed.

また、この実施の形態では、誤カウント補正回路35が合成逓倍カウント値の前回値と今回値を比較し、その差が所定値以上であるときにカウント異常と判断して補正を行うようにしたので誤カウントが防止される。例えば、1回転の分解能が20ビットのモータ用エンコーダでサンプリング周期が50μ秒のとき、合成逓倍カウント値で128の変化は回転数100rpmに相当するが、実際のモータではこのような回転数変化はあり得ない。したがって、カウント値の差が128(第2の逓倍カウント値の0・5カウントに相当)を越えたら、256(第2の逓倍カウント値の1カウントに相当)を減算すれば、正しいカウント値に修正することができる。   Further, in this embodiment, the erroneous count correction circuit 35 compares the previous value of the combined multiplication count value with the current value, and when the difference is equal to or greater than a predetermined value, it is determined that the count is abnormal and correction is performed. Therefore, erroneous counting is prevented. For example, when a motor rotation encoder with a resolution of one rotation is 20 bits and the sampling period is 50 μsec, a change of 128 in the combined multiplication count value corresponds to a rotation speed of 100 rpm. impossible. Therefore, when the difference between the count values exceeds 128 (corresponding to 0.5 count of the second multiplied count value), 256 (corresponding to 1 count of the second multiplied count value) is subtracted to obtain the correct count value. It can be corrected.

なお、本発明は、前記の実施の形態に限定されずに広く応用することができる。
例えば、光学ピックアップ11の出力信号や、ケーブル4を介して送受信するデータは、差動出力を用いなくても良い。
光学ピックアップ11は一種類のアナログ信号を出力し、これに基づいて回転検出のカウント値を生成しても良い。
第1の閾値と第2の閾値の値は、1.5カウント、0.5カウントに限定されない第2の逓倍カウント値の1カウント分、2カウント分のずれを補正するのに適した値であれば良い。
Note that the present invention can be widely applied without being limited to the above-described embodiment.
For example, the output signal of the optical pickup 11 and the data transmitted / received via the cable 4 need not use a differential output.
The optical pickup 11 may output one type of analog signal and generate a rotation detection count value based on the analog signal.
The values of the first threshold value and the second threshold value are values suitable for correcting a shift of 1 count by 2 counts of the second multiplied count value not limited to 1.5 counts and 0.5 counts. I just need it.

本発明の実施の形態に係るモータ用エンコーダのブロック図である。It is a block diagram of the encoder for motors concerning an embodiment of the invention. 誤カウント補正回路の詳細を示すブロック図である。It is a block diagram which shows the detail of an erroneous count correction circuit. 正転時の擬似正弦波とカウント値の関係を説明する図である。It is a figure explaining the relationship between the pseudo sine wave at the time of forward rotation, and a count value. 逆転時の擬似正弦波とカウント値の関係を説明する図である。It is a figure explaining the relationship between the pseudo sine wave at the time of reverse rotation, and a count value. 誤カウント補正処理を説明するフローチャートである。It is a flowchart explaining an erroneous count correction process. 誤カウントが発生するような例を示す図である。It is a figure which shows the example which an erroneous count generate | occur | produces.

符号の説明Explanation of symbols

1 モータ用エンコーダ
2 スケール
3 エンコーダ基板(検出部)
4 ケーブル
5 ドライバ
11 光学ピックアップ
12 第1の差動A/D変換器
13 第1のコンパレータ
14 第2の差動A/D変換器
15 第2のコンパレータ
16,21 レベル変換回路
22 逓倍専用IC(逓倍部)
23 CPU
32 第1の逓倍回路
33 2相エンコーダ用カウンタ(第2の逓倍回路)
34 合成逓倍カウント値生成回路
35 誤カウント補正回路
41 引き算回路
42 補正回路
43 エンコーダ値保存用レジスタ
1 Motor encoder 2 Scale 3 Encoder board (detector)
4 Cable 5 Driver 11 Optical Pickup 12 First Differential A / D Converter 13 First Comparator 14 Second Differential A / D Converter 15 Second Comparator 16, 21 Level Conversion Circuit 22 Dedicated Multiplication IC ( Multiplication unit)
23 CPU
32 First multiplication circuit 33 Counter for two-phase encoder (second multiplication circuit)
34 Composite Multiplication Count Value Generation Circuit 35 Error Count Correction Circuit 41 Subtraction Circuit 42 Correction Circuit 43 Encoder Value Saving Register

Claims (5)

モータに取り付けられる検出部と、前記モータ外に配置され、前記検出部との間でデータ通信可能に接続されたドライバとを有するモータ用エンコーダであって、
前記モータの回転に伴って擬似正弦波状のアナログ信号を出力するピックアップと、
前記ピックアップから出力されるアナログ信号をデジタル信号に変換してシリアル出力するアナログ/デジタル変換器と、基準電位に対するアナログ信号の符号変化に伴って信号レベルが切り替わるパルス状の符号変化信号を生成するコンパレータと、前記アナログ/デジタル変換器及び前記コンパレータから出力されるデジタル信号を受け取って、逓倍処理する逓倍部とを有し、
前記逓倍部は、前記アナログ/デジタル変換器から出力されるデジタル信号から第1の逓倍カウント値を算出する第1の逓倍回路と、前記コンパレータから出力される符号変化信号の符号変化をカウントして第2の逓倍カウント値を生成する第2の逓倍回路と、第1の逓倍カウント値と第2の逓倍カウント値を合成して合成逓倍カウント値を生成する合成回路と、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差の大きさが所定の値以上になったらカウント値のずれを補正する誤カウント補正回路を有することを特徴とするモータ用エンコーダ。
A motor encoder having a detection unit attached to a motor and a driver disposed outside the motor and connected to the detection unit so as to be able to perform data communication,
A pickup that outputs a pseudo sine wave analog signal as the motor rotates,
An analog / digital converter that converts an analog signal output from the pickup into a digital signal and serially outputs the comparator, and a comparator that generates a pulse-like code change signal whose signal level is switched in accordance with a change in the sign of the analog signal relative to a reference potential And a multiplier for receiving and multiplying the digital signals output from the analog / digital converter and the comparator,
The multiplication unit counts a sign change of a sign change signal output from a first multiplication circuit that calculates a first multiplication count value from a digital signal output from the analog / digital converter and a comparator. A second multiplication circuit for generating a second multiplied count value; a combining circuit for combining the first multiplied count value and the second multiplied count value to generate a combined multiplied count value; and a previous combined multiplied count value. And an erroneous count correction circuit that corrects the deviation of the count value when the difference between the current and the combined multiplication count value exceeds a predetermined value.
前記誤カウント補正回路は、前回の合成逓倍カウント値と今回の合成逓倍カウント値の差が第1の閾値を越えたら、第2の逓倍カウント値の2カウント分補正した合成逓倍カウント値を生成し、第1の閾値未満で第2の閾値以上であったら第2の逓倍カウント値の1カウント分補正した合成逓倍カウント値を生成するように構成されていることを特徴とする請求項1に記載のモータ用エンコーダ。   The erroneous count correction circuit generates a combined multiplied count value corrected by 2 counts of the second multiplied count value when the difference between the previous combined multiplied count value and the current combined multiplied count value exceeds the first threshold value. The composite multiplied count value corrected by one count of the second multiplied count value is generated when the value is less than the first threshold value and greater than or equal to the second threshold value. Motor encoder. 第1の閾値は、第2の逓倍カウント値の1.5カウントに相当する値であり、第2の閾値は、第2の逓倍カウント値の0.5カウントに相当する値であることを特徴とする請求項2に記載のモータ用エンコーダ。   The first threshold value is a value corresponding to 1.5 counts of the second multiplied count value, and the second threshold value is a value corresponding to 0.5 counts of the second multiplied count value. The motor encoder according to claim 2. 前記ピックアップは、周期が1/4異なる擬似サイン波信号と擬似コサイン波信号を出力し、前記アナログ/デジタル変換器及び前記コンパレータは、擬似サイン波信号が入力される第1のアナログ/デジタル変換器及び第1のコンパレータと、擬似コサイン波信号が入力される第2のアナログ/デジタル変換器及び第2のコンパレータを有することを特徴とする請求項1から請求項3のいずれか一項に記載のモータ用エンコーダ。   The pickup outputs a pseudo sine wave signal and a pseudo cosine wave signal having a period different by ¼, and the analog / digital converter and the comparator are a first analog / digital converter to which the pseudo sine wave signal is input. And a first comparator, a second analog / digital converter to which a pseudo cosine wave signal is input, and a second comparator. Encoder for motor. 前記アナログ/デジタル変換器及び前記コンパレータを前記検出部に設け、前記逓倍部を前記ドライバに設けたことを特徴とする請求項1から請求項4のいずれか一項に記載のモータ用エンコーダ。   The motor encoder according to any one of claims 1 to 4, wherein the analog / digital converter and the comparator are provided in the detection unit, and the multiplication unit is provided in the driver.
JP2007101908A 2007-04-09 2007-04-09 Encoder for motor Withdrawn JP2008256657A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007101908A JP2008256657A (en) 2007-04-09 2007-04-09 Encoder for motor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007101908A JP2008256657A (en) 2007-04-09 2007-04-09 Encoder for motor

Publications (1)

Publication Number Publication Date
JP2008256657A true JP2008256657A (en) 2008-10-23

Family

ID=39980355

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007101908A Withdrawn JP2008256657A (en) 2007-04-09 2007-04-09 Encoder for motor

Country Status (1)

Country Link
JP (1) JP2008256657A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014057533A1 (en) * 2012-10-09 2014-04-17 株式会社安川電機 Overload detector, servo system, and converter
WO2020149002A1 (en) * 2019-01-18 2020-07-23 パナソニックIpマネジメント株式会社 Motor control device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014057533A1 (en) * 2012-10-09 2014-04-17 株式会社安川電機 Overload detector, servo system, and converter
WO2020149002A1 (en) * 2019-01-18 2020-07-23 パナソニックIpマネジメント株式会社 Motor control device
CN113316892A (en) * 2019-01-18 2021-08-27 松下知识产权经营株式会社 Motor control device
US20220085696A1 (en) * 2019-01-18 2022-03-17 Panasonic Intellectual Property Management Co., Ltd. Motor control device

Similar Documents

Publication Publication Date Title
JP5221494B2 (en) Rotation detection device and bearing with rotation detection device
US9481394B2 (en) Angle detection apparatus, motor having the angle detection apparatus, torque sensor, electric power steering apparatus, and vehicle
JP4875889B2 (en) Encoder count error detection circuit and encoder count error detection method
JP5341714B2 (en) Phase difference type resolver
JP4835606B2 (en) Rotating body phase / speed detector
CN107860404B (en) Rotary encoder and absolute angle position detection method for rotary encoder
JP2009080058A (en) Rotation detector and bearing with rotation detector
JP2008256657A (en) Encoder for motor
US20050090998A1 (en) Sensor signal processor
US9134143B2 (en) Absolute position detector with abnormality detection function
JP4782434B2 (en) Rotation detection device signal processing device
JP2008256656A (en) Encoder for motor
JPH074990A (en) Method for detecting absolute position in encoder apparatus
JP2009244022A (en) Phase detection circuit
JP2003130686A (en) Device for detecting position
JP3365913B2 (en) Position detection device
JP3118816B2 (en) Multi-rotation detection rotary encoder
JP3708093B2 (en) R / D converter used for motor servo control system and motor speed control
JP2010014410A (en) Rotational position detecting apparatus of rotator
JP2580714B2 (en) Composite rotary encoder
JP2008241639A (en) Rotary encoder and brushless motor
JP2008298745A (en) Rotation detecting device using resolver
JP2008076382A (en) Serial encoder data conversion circuit, and servo drive system
JP5097012B2 (en) Encoder signal processing circuit
JP2006177806A (en) Rotation detecting device

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20100706