JPH0431333B2 - - Google Patents

Info

Publication number
JPH0431333B2
JPH0431333B2 JP29810685A JP29810685A JPH0431333B2 JP H0431333 B2 JPH0431333 B2 JP H0431333B2 JP 29810685 A JP29810685 A JP 29810685A JP 29810685 A JP29810685 A JP 29810685A JP H0431333 B2 JPH0431333 B2 JP H0431333B2
Authority
JP
Japan
Prior art keywords
output
code
reference code
time
clock
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired
Application number
JP29810685A
Other languages
Japanese (ja)
Other versions
JPS62156520A (en
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 filed Critical
Priority to JP29810685A priority Critical patent/JPS62156520A/en
Publication of JPS62156520A publication Critical patent/JPS62156520A/en
Publication of JPH0431333B2 publication Critical patent/JPH0431333B2/ja
Granted legal-status Critical Current

Links

Landscapes

  • Measurement Of Length, Angles, Or The Like Using Electric Or Magnetic Means (AREA)
  • Length Measuring Devices With Unspecified Measuring Means (AREA)
  • Transmission And Conversion Of Sensor Element Output (AREA)

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明は同期型のカウントパルス作成方法、特
に検出器から出力される位相の異なる複数のアナ
ログ長さ検出信号を用い、変位検出用のカウント
パルスを出力する方法に関する。
[Detailed Description of the Invention] [Industrial Application Field] The present invention provides a synchronous count pulse generation method, in particular, a count pulse generation method for displacement detection using a plurality of analog length detection signals output from a detector and having different phases. Concerning a method of outputting pulses.

[従来の技術] 従来よりリニアスケールあるいはロータリエン
コーダなどの検出器を用いて、被測定物の長さ測
定を行う各種の変位検出技術が周知であり、三次
元測定器、工作機械の位置決め装置、小型のデジ
タルノギス、デジタルマイクロメータ及びその他
の用途に幅広く用いられている。
[Prior Art] Various displacement detection techniques have been known in the past for measuring the length of objects to be measured using detectors such as linear scales or rotary encoders. Widely used in small digital calipers, digital micrometers, and other applications.

この種の変位検出技術としては、非同期型のも
のと同期型のものとが知られているが、非同期型
の変位検出技術はカウントパルスの幅にばらつき
が生じてカウントミスが発生しやすく、しかも装
置全体が高機能化するに従い回路全体のタイミン
グ調整が極めて難しくなるという問題がある。
This type of displacement detection technology is known as an asynchronous type and a synchronous type, but the asynchronous type displacement detection technology tends to cause counting errors due to variations in the width of the count pulse. There is a problem in that as the functionality of the entire device becomes more sophisticated, it becomes extremely difficult to adjust the timing of the entire circuit.

このため、今日この種の変位検出技術としては
同期型のものが幅広く用いられており、この同期
型の変位測定技術は、基準クロツクに基づき回路
全体のタイミング調整を行うことができるため、
動作が安定し正確な変位検出を行うことが可能と
なる。
For this reason, the synchronous type is widely used as this type of displacement detection technology today, and this synchronous displacement measurement technology can adjust the timing of the entire circuit based on the reference clock.
The operation becomes stable and accurate displacement detection becomes possible.

しかし、従来の変位検出技術では、リニアスケ
ール又はロータリエンコーダ(以下スケールなど
と記す)を高速で移動すると、検出器から出力さ
れる検出信号の周波数が極めて高くなり、検出信
号の変動速度に基準クロツクが追随できなかつ
た。従つて、このような場合には、カウントパル
スがスケールなどの変位量に正確に対応して出力
されず、測定誤差が発生してしまうという欠点が
あつた。
However, with conventional displacement detection technology, when a linear scale or rotary encoder (hereinafter referred to as scale) is moved at high speed, the frequency of the detection signal output from the detector becomes extremely high, and the fluctuation rate of the detection signal is affected by the reference clock. could not follow suit. Therefore, in such a case, there is a drawback that the count pulses are not output in accurate correspondence with the amount of displacement of the scale, etc., resulting in measurement errors.

特に、マニユアル操作型の変位検出装置では、
操作者がスケールなどを頻繁に高速移動すること
が多いため、前述した検出誤差が発生しやすくそ
の有効な対策が望まれていた。
In particular, with manually operated displacement detection devices,
Since operators frequently move scales and the like at high speeds, the aforementioned detection errors are likely to occur, and effective countermeasures have been desired.

第9図には、従来の同期型変位検出技術を用い
て形成されたカウントパルス作成回路が示されて
おり、第10図にはそのタイミングチヤートが示
されている。
FIG. 9 shows a count pulse generation circuit formed using the conventional synchronous displacement detection technique, and FIG. 10 shows its timing chart.

周知のように、変位検出装置では、検出器から
互いに90度位相の異なる正弦波及び余弦波がアナ
ログ長さ検出信号として出力されており、この正
弦波及び余弦波は、所定のA/D変換器を介して
デジタル信号φa,φbに変換されカウントパルス
作成回路に入力されている。
As is well known, in a displacement detection device, a sine wave and a cosine wave having a phase difference of 90 degrees from each other are output from the detector as analog length detection signals, and these sine waves and cosine waves are processed by a predetermined A/D conversion. The signals are converted into digital signals φ a and φ b through the converter and input to the count pulse generation circuit.

そして、このカウントパルス作成回路は、検出
信号φa及びφbを基準クロツクCP1に同期して信
号処理しアツプカウントパルス500a又はダウ
ンカウントパルス500bを出力する。なお、前
記基準クロツクCP1としては、回路全体の同期
用クロツク信号が用いられる。
This count pulse generating circuit processes the detection signals φ a and φ b in synchronization with the reference clock CP1 and outputs an up count pulse 500a or a down count pulse 500b. Note that a clock signal for synchronizing the entire circuit is used as the reference clock CP1.

すなわち、このカウントパルス作成回路は、検
出信号φa,φbがHレベルに切替わると、その後
最初に出力される基準クロツクCP1の立上がり
に同期して、素子N5又はN7からパルス信号を
出力する。そして、このパルス信号が出力される
と同時に、その立上がりに同期してアツプカウン
トパルス500a又はダウンカウントパルス50
0bを出力するよう形成されている。
That is, this count pulse generation circuit outputs a pulse signal from element N5 or N7 in synchronization with the rise of the first output reference clock CP1 after the detection signals φ a and φ b switch to H level. . At the same time as this pulse signal is output, an up count pulse 500a or a down count pulse 500a is generated in synchronization with the rising edge of the pulse signal.
It is formed to output 0b.

従つて、スケールなどをゆつくり移動場合に
は、第9図の区間100で示すように、検出器か
ら信号φa及びφbが充分な時間的な位相ずれをも
つて出力されるため、カウントパルス500がス
ケールの変位量に対応して正確に出力されること
になる。
Therefore, when a scale or the like is moved slowly, the signals φ a and φ b are output from the detector with a sufficient temporal phase shift, as shown in section 100 in FIG. The pulse 500 will be output accurately in accordance with the amount of displacement of the scale.

[発明が解決しようとする問題点] しかし、このような従来装置では、スケールな
どを高速で移動すると、第9図の区間200で示
すように、信号φa及びφbが基準クロツクCP1の
出力周期より短い時間間隔で順次出力されること
となり、素子N5及びN7からの出力パルスが同
位相となつてしまう。この結果、本来2個のカウ
ントパルスを出力すべきところを、単に1個のカ
ウントパルスだけしか出力しないという出力ミス
が生じ、測定誤差が発生してしまうという問題が
あつた。
[Problems to be Solved by the Invention] However, in such a conventional device, when a scale or the like is moved at high speed, the signals φ a and φ b are output from the reference clock CP1, as shown in section 200 in FIG. The pulses are sequentially output at time intervals shorter than the period, and the output pulses from elements N5 and N7 end up being in the same phase. As a result, an output error occurs in which only one count pulse is output when two count pulses should normally be output, resulting in a measurement error.

特に、スケールなどを極めて高速で移動する
と、検出器から出力される信号φa及びφbが基準
クロツクCP1の1サイクル出力周期内に複数回
変動する。この場合には、1サイクル周期内にお
いて、本来複数個カウントパルスを出力しなけれ
ばならないが、従来のカウントパルス作成技術で
は、単に1個のカウントパルスしか出力すること
ができず。測定誤差が更に大きなものとなるとい
う問題があつた。
In particular, when a scale or the like is moved at extremely high speed, the signals φ a and φ b output from the detector fluctuate multiple times within one output cycle of the reference clock CP1. In this case, a plurality of count pulses should originally be output within one cycle period, but with conventional count pulse generation techniques, only one count pulse can be output. There was a problem that the measurement error became even larger.

発明の目的 本発明は、このような従来の課題に鑑み為され
たものであり、その目的は、スケールなどを高速
度で移動し、検出器から高周波の検出信号が出力
された場合でも、変位測定用のカウントパルスを
確実に出力可能な同期型カウントパルス作成方法
を提供することにある。
Purpose of the Invention The present invention was made in view of such conventional problems, and its purpose is to detect displacement even when a scale or the like is moved at high speed and a high frequency detection signal is output from the detector. An object of the present invention is to provide a synchronous count pulse generation method that can reliably output count pulses for measurement.

[問題点を解決するための手段及び作用] 第1図には、本発明に係る同期型カウントパル
ス作成方法のフローチヤートが示されている。
[Means and effects for solving the problems] FIG. 1 shows a flowchart of a method for creating a synchronous count pulse according to the present invention.

本発明において、検出器から位相の異なる複数
のアナログ長さ検出信号が出力されると、基準ク
ロツクに同期して基準コードの作成が行われる。
In the present invention, when a plurality of analog length detection signals having different phases are output from the detector, a reference code is created in synchronization with the reference clock.

この基準コード作成工程においては、前記アナ
ログ長さ検出信号に基づき、所定のデジタル組合
せ信号を作成し、基準クロツクが出力される毎に
このデジタル組合せ信号により特定されるコード
データを基準コードとして出力する。
In this reference code creation step, a predetermined digital combination signal is created based on the analog length detection signal, and each time the reference clock is output, code data specified by this digital combination signal is output as a reference code. .

また、この基準コードの作成と共に、本発明に
おいては、参照コードの作成が行われる。
Further, in addition to creating this reference code, in the present invention, a reference code is created.

この参照コード作成工程においては、基準クロ
ツクが出力される毎に、1クロツク前の基準コー
ドが参照コードとして出力される。このとき、前
記検出信号の1サイクル周期内に順次出力される
コードデータ列に照らし、出力される基準コード
が参照コードに対し何ステツプ分シフトしている
か検出すれば、この検出シフト数がそのまま変位
量を表すことになる。
In this reference code creation step, each time the reference clock is output, the reference code one clock previous is output as the reference code. At this time, if it is detected how many steps the output standard code is shifted from the reference code in light of the code data string sequentially output within one cycle period of the detection signal, this detected shift number is the same as the displacement. It represents quantity.

従つて、本発明においては、この基準コードと
参照コードとを用い、次のようにカウントパルス
の出力を行つている。
Therefore, in the present invention, the standard code and reference code are used to output count pulses as follows.

すなわち、本発明のカウントパルス出力工程に
おいては、まず基準コードと参照コードとを比較
し、両者が不一致の場合には、両者が一致するか
否かの判別を行う。そして、両者が一致するまで
所定の短クロツク周期に設定された出力クロツク
が出力される毎に、前記検出信号の1サイクル周
期内に順次出力されるコードデータ列に従い、参
照コードを1ステツプずつサイクリツクにシフト
させながらカウントパルスの出力を行う。
That is, in the count pulse output step of the present invention, first the standard code and the reference code are compared, and if they do not match, it is determined whether or not they match. Then, each time the output clock set to a predetermined short clock period is output until the two match, the reference code is cycled one step at a time according to the code data string sequentially output within one cycle period of the detection signal. Count pulses are output while shifting to .

このようにすることにより、基準クロツクが出
力される度に、基準コードのシフト量に応じた個
数のカウントパルスを確実に出力し、各種の変位
測定を正確に行うことができる。
By doing so, each time the reference clock is output, a number of count pulses corresponding to the shift amount of the reference code can be reliably output, and various displacement measurements can be performed accurately.

特に、本発明によれば、スケールなどを高速度
で移動させ、検出器から高周波のアナログ長さ検
出信号を出力させたような場合であつても、その
変位量に対応した個数のカウントパルスを確実に
出力し正確な変位検出を行うことが可能となる。
In particular, according to the present invention, even when a scale or the like is moved at high speed and a high-frequency analog length detection signal is output from the detector, the number of count pulses corresponding to the amount of displacement can be output. It becomes possible to reliably output and perform accurate displacement detection.

[実施例] 次に本発明の好適な実施例を図面に基づき説明
する。
[Example] Next, a preferred example of the present invention will be described based on the drawings.

変位検出装置 第2図には本発明に用いられる変位検出装置の
好適な実施例が示されており、第3図にはその回
路各部におけるタイミングチヤートが示されてい
る。
Displacement Detection Device FIG. 2 shows a preferred embodiment of the displacement detection device used in the present invention, and FIG. 3 shows a timing chart for each part of the circuit.

実施例の装置では、スケールなどが移動する
と、検出器10から位相の異なるアナログ長さ検
出信号として、正弦波φa及び余弦波φbが出力さ
れる。
In the apparatus of the embodiment, when the scale or the like moves, the detector 10 outputs a sine wave φ a and a cosine wave φ b as analog length detection signals having different phases.

そして、これら各検出信号φa及びφbは2相/
4相変換回路12へ入力され、ここで次式に基づ
きφc,φdへの演算が行われ、合計4相の検出信
号φa,φb,φc,φdが出力される。
Each of these detection signals φ a and φ b has two phases/
The signals are input to the four-phase conversion circuit 12, where operations are performed on φ c and φ d based on the following equation, and a total of four phases of detection signals φ a , φ b , φ c , and φ d are output.

φc=φa+φb φd=φb−φb 第2図には、このような4相信号φa,φc,φb
φcが示されており、同図からこれら各信号φa
φc,φb,φdはそれぞれπ/4ずつ位相の異なる
信号として出力されることが理解される。
φ c = φ a + φ b φ d = φ b −φ b In FIG. 2, such four-phase signals φ a , φ c , φ b ,
φ c is shown, and from the same figure, each of these signals φ a ,
It is understood that φ c , φ b , and φ d are output as signals whose phases differ by π/4, respectively.

そして、信号処理回路14は、このようにして
入力される信号φa,φc,φb,φdを、所定のカウ
ントパルス作成方法に従つて信号処理し、スケー
ルなどの変位量に対応した個数のアツプカウント
パルス500a又はダウンカウントパルス500
bを出力する。
Then, the signal processing circuit 14 processes the signals φ a , φ c , φ b , φ d inputted in this way according to a predetermined count pulse creation method, and calculates signals corresponding to the amount of displacement of the scale, etc. Number of up count pulses 500a or down count pulses 500
Output b.

カウントパルス作成方法 第4図には、実施例のカウントパルス作成方法
の工程図が示されている。
Count Pulse Creation Method FIG. 4 shows a process diagram of the count pulse creation method of the embodiment.

(イ) 基準コードの作成 まず、2相/4相変換回路12から4相のア
ナログ長さ検出信号φa,φb,φc,φdが出力さ
れると、これら各信号を用いて基準コードの作
成が行われる。
(B) Creation of reference code First, when the 4-phase analog length detection signals φ a , φ b , φ c , φ d are output from the 2-phase/4-phase conversion circuit 12, a reference code is created using each of these signals. Code creation takes place.

本発明においては、入力される検出信号φa
φb,φc,φdに基づきデジタル組合せ信号10
0を作成し、基準クロツクCP1が出力される
毎に、このデジタル組合せ信号100により特
定されるコードデータ200を、基準コード3
00として出力している。
In the present invention, the input detection signals φ a ,
Digital combination signal 10 based on φ b , φ c , φ d
0, and each time the reference clock CP1 is output, the code data 200 specified by this digital combination signal 100 is generated as the reference code 3.
It is output as 00.

実施例において、この基準コード作成工程
は、デジタル組合せ信号作成工程と、データの
変換工程と、基準コードの出力工程の順で行わ
れる。
In the embodiment, this reference code creation step is performed in the order of a digital combination signal creation step, a data conversion step, and a reference code output step.

まず、前記デジタル組合せ信号作成工程で
は、2相/4相変換回路12から出力される検
出信号φa,φb,φc,φdを所定のスレツシヨル
ドレベルと比較し、第3図に示すように4個の
パルスA,B,C,Dの組合せからなるデジタ
ル組合せ信号100を作成する。ここにおい
て、各パルス信号A,C,B,Dはそれぞれ
π/4ずつ位相が異なるため、実施例のデジタ
ル組合せ信号100は、位相θが0〜2πまで
変化する1サイクルの間に16進表記で1、3、
7、F、B、C、8、0の順にその内容が順次
変化することになる。
First, in the digital combination signal creation step, the detection signals φ a , φ b , φ c , φ d output from the 2-phase/4-phase conversion circuit 12 are compared with a predetermined threshold level, As shown, a digital combination signal 100 consisting of a combination of four pulses A, B, C, and D is created. Here, since each of the pulse signals A, C, B, and D has a different phase by π/4, the digital combination signal 100 of the embodiment is expressed in hexadecimal notation during one cycle in which the phase θ changes from 0 to 2π. So 1, 3,
The contents change sequentially in the order of 7, F, B, C, 8, and 0.

本発明においてはこのようなデジタル組合せ
信号100をそのままコードデータとして使用
することも可能であるが、データの信号処理を
より簡単なものとするため、この4ビツトのデ
ジタル組合せ信号100を更にデータの変換工
程において3ビツトのコードデータ200に変
換している。
In the present invention, it is possible to use such a digital combination signal 100 as it is as code data, but in order to simplify data signal processing, this 4-bit digital combination signal 100 can be further converted into data. In the conversion process, it is converted into 3-bit code data 200.

すなわち、実施例のデータ変換工程において
は、4ビツトの内容で表示されるデジタル組合
せ信号100を8進表記で0、1、2、3…7
で表される8ビツトのコードデータ200に変
換出力している。
That is, in the data conversion process of the embodiment, the digital combination signal 100 displayed as 4-bit content is expressed as 0, 1, 2, 3...7 in octal notation.
It is converted and output into 8-bit code data 200 expressed as .

第6図には、前記デジタル組合せ信号100
とコードデータ200との対応関係が示されて
おり、同図からも明らかなように、検出信号
φa,φbの位相θが0〜2πまで変化する1サイ
クルの間に、アツプカウント時には0、1、2
…7の順(順方向)に従いコードデータが順次
出力され、またカウントパルス時には7、6、
5…0の順(逆方向)に従いコードデータが順
次出力されることになる。
FIG. 6 shows the digital combination signal 100
and the code data 200. As is clear from the figure, during one cycle in which the phase θ of the detection signals φ a and φ b changes from 0 to 2π, the phase θ of the detection signals φ a and φ b changes from 0 to 2π at the time of up counting. ,1,2
...Code data is output sequentially according to the order of 7 (forward direction), and at the time of count pulse, 7, 6,
Code data is sequentially output in the order of 5...0 (in the reverse direction).

そして、基準コードの出力工程においては、
このようにして出力されるコードデータ200
を、基準クロツクCP1が出力される毎にサン
プルホールドし、これを基準コード300とし
て出力している。なお、この基準クロツクCP
1としては回路全体の同期用クロツク信号が用
いられている。
In the standard code output process,
Code data 200 output in this way
is sampled and held every time the reference clock CP1 is output, and this is output as the reference code 300. Note that this reference clock CP
1, a clock signal for synchronizing the entire circuit is used.

このようにして、本実施例においては、デジ
タル組合せ信号作成工程、データ変換工程、基
準コードの出力工程の順に信号処理が行われ、
基準クロツクCP1が出力される毎に基準コー
ド300が出力されることになる。
In this way, in this embodiment, signal processing is performed in the order of digital combination signal creation step, data conversion step, and reference code output step.
The reference code 300 is output every time the reference clock CP1 is output.

なお、本発明においては、基準コードの出力
工程を特別に設けることなく、例えば基準クロ
ツクCP1に同期して入力データを(例えばφa
φb,φc,φd又はデジタル組合せ信号100)
サンプルホールドしながらデジタル組合せ信号
100の作成やコードデータ200の作成を行
うことにより、基準コード300を作成するこ
とも可能となる。この場合には、データの変換
工程を経て出力されるコードデータがそのまま
基準コード300となる。
Note that in the present invention, input data (for example, φ a ,
φ b , φ c , φ d or digital combination signal 100)
By creating the digital combination signal 100 and the code data 200 while sample-holding, it is also possible to create the reference code 300. In this case, the code data output through the data conversion process becomes the reference code 300 as it is.

(ロ) 参照コードの作成 また、本発明においては、この様な基準コー
ド300の作成と共に、参照コード400の作
成が同時に行われる。
(b) Creation of reference code Furthermore, in the present invention, the reference code 400 is created simultaneously with the creation of such a reference code 300.

この参照コード作成工程においては、基準ク
ロツクCP1が出力される毎に、1クロツク前
の基準コードを参照コード400として出力し
ている。
In this reference code creation step, each time the reference clock CP1 is output, the reference code one clock previous is output as the reference code 400.

従つて、このようにして出力される基準コー
ド300と参照コード400とを、第6図に示
すコードデータ列に照らして比較することによ
り、スケールなどの変位量を基準コード300
のシフト数として検出することができる。従つ
て、基準クロツクCP1に同期して、基準コー
ド300のシフト数に対応した個数のカウント
パルスを出力すれば、スケールなどの変位を正
確に測定可能であることが理解される。
Therefore, by comparing the standard code 300 and reference code 400 output in this way against the code data string shown in FIG.
It can be detected as the number of shifts. Therefore, it is understood that if the number of count pulses corresponding to the number of shifts of the reference code 300 is outputted in synchronization with the reference clock CP1, the displacement of the scale etc. can be accurately measured.

(ハ) カウントパルスの出力 このため、本発明においてはカウントパルス
出力工程において、基準コード300と参照コ
ード400とを比較し、両コードが一致するか
否かの判別を行つている。
(c) Output of count pulses Therefore, in the present invention, in the count pulse output step, the standard code 300 and the reference code 400 are compared to determine whether or not the two codes match.

そして、両者が一致しない場合には、所定の
短クロツク周期に設定された出力クロツクCP
2が出力される毎に、第6図に示すコードデー
タ列に従い、前記参照コード400を1ステツ
プずつサイクリツクにシフトさせながらカウン
トパルスの出力を行う。そして、基準コード3
00と参照コード400とが一致した時点で、
カウントパルスの出力を停止する。
If the two do not match, the output clock CP is set to a predetermined short clock period.
Each time 2 is output, a count pulse is output while cyclically shifting the reference code 400 one step at a time according to the code data string shown in FIG. And standard code 3
When 00 and reference code 400 match,
Stop outputting count pulses.

このようにすることにより、基準クロツク
CP1が出力される毎に、基準コード300と
参照コード400とのシフト数に対応した個数
のカウントパルスを正確に出力することが可能
となる。
By doing this, the reference clock
Each time CP1 is output, it is possible to accurately output the number of count pulses corresponding to the number of shifts between the standard code 300 and the reference code 400.

第5図にはこのカウントパルス出力工程の具
体的な信号処理工程が示されており、実施例に
おいてこのカウントパルス出力工程は、比較工
程、カウント動作判別工程、カウントパルス作
成工程及び参照コードシフト工程とを含む。
FIG. 5 shows a specific signal processing step of this count pulse output step, and in the embodiment, this count pulse output step includes a comparison step, a count operation discrimination step, a count pulse creation step, and a reference code shift step. including.

そして、比較工程においては、基準クロツク
CP1が出力される毎に、基準コード300と
参照コード400とを比較し、両者が一致しな
い場合には、基準コード300が前回の基準コ
ードに対しシフトしていると判別する。
In the comparison process, the reference clock
Every time CP1 is output, the standard code 300 and the reference code 400 are compared, and if they do not match, it is determined that the standard code 300 has shifted with respect to the previous standard code.

また、このような比較動作と連動して、カウ
ント動作判別工程においては、スケールなどが
アツプカウント方向又はダウンカウント方向の
どの方向に向け移動しているかの判別を行う。
Further, in conjunction with such a comparison operation, in the counting operation determination step, it is determined whether the scale or the like is moving in an up-counting direction or a down-counting direction.

そして、カウントパルス作成工程において
は、比較工程で不一致判別が行われたことを条
件として、所定の短クロツク周期に設定された
出力クロツクCP2が出力される毎に、カウン
トパルス500の出力を行つている。
In the count pulse generation step, a count pulse of 500 is output every time the output clock CP2, which is set to a predetermined short clock cycle, is output, provided that a mismatch is determined in the comparison step. There is.

ここにおいて、このカウントパルス500
は、スケールなどがアツプカウント方向へ移動
している場合には、アツプカウントパルス50
0aとして出力され、またスケールなどがダウ
ンカウント方向へ移動している場合には、ダウ
ンカウントパルス500bとして出力される。
Here, this count pulse 500
If the scale etc. is moving in the up count direction, the up count pulse 50
If the scale or the like is moving in the down-counting direction, it is output as a down-count pulse 500b.

そして、実施例の参照コードシフト工程は、
第6図に示すコードデータ列に従い、アツプカ
ウントパル500aが出力される場合には順方
向に沿つて前記参照コード400を1ステツプ
ずつサイクリツクにシフトさせ、またダウンカ
ウントパルス500bが出力される場合には参
照コード400を逆方向へ1ステツプずつサイ
クリツクにシフトさせる。
The reference code shift process of the embodiment is as follows:
According to the code data string shown in FIG. 6, when the up count pulse 500a is output, the reference code 400 is cyclically shifted one step at a time in the forward direction, and when the down count pulse 500b is output, the reference code 400 is cyclically shifted one step at a time in the forward direction. cyclically shifts reference code 400 in the opposite direction one step at a time.

従つて、基準クロツク出力時に出力される基
準コード300が、参照コード400に対し、
例えば2ステツプ分アツプカウント方向へシフ
トしているようにな場合を想定すると、アツプ
カウントパルス500aが出力される毎に、参
照コード400はコードデータ列に従いアツプ
カウント方向へ1ステツプずつシフトされるこ
とになる。そして、アツプカウントパルス50
0aが2個出力された時点で、基準コード30
0と参照コード400とが一致し、カウントパ
ルス500aの出力が停止されることとなる。
Therefore, the reference code 300 output when the reference clock is output is different from the reference code 400.
For example, assuming that there is a shift in the up-count direction by 2 steps, the reference code 400 is shifted by 1 step in the up-count direction according to the code data string every time the up-count pulse 500a is output. become. And up count pulse 50
When two 0a are output, the standard code 30
0 and the reference code 400 match, and the output of the count pulse 500a is stopped.

以上説明したように、実施例の方法によれば、
基準クロツクCP1が出力される毎に、このクロ
ツク出力時におけるコードデータ200と1クロ
ツク前のコードデータとを比較し、両者がアツプ
カウント方向又はダウンカウント方向に何ステツ
プ分シフトしているかを判別する。そして、この
シフト数に応じた個数のアツプカウントパルス5
00a又はダウンカウントパルス500bを出力
する。このため、スケールなどを高速で移動し、
検出器10から高周波の検出信号φa及びφbが出
力されるような場合であつても、その変位量に対
応した個数のアツプカウントパルス500a又は
ダウンカウントパルス500bを確実に出力する
ことができる。
As explained above, according to the method of the embodiment,
Every time the reference clock CP1 is output, the code data 200 at the time of this clock output is compared with the code data one clock previous, and it is determined how many steps the two have shifted in the up-count direction or down-count direction. . Then, the number of up count pulses 5 corresponding to this number of shifts is
00a or down count pulse 500b is output. For this reason, moving scales etc. at high speed,
Even if the detector 10 outputs high-frequency detection signals φ a and φ b , it is possible to reliably output the number of up-count pulses 500a or down-count pulses 500b corresponding to the amount of displacement. .

従つて、このようにして出力されるカウントパ
ルス500a又は500bをカウントすることに
より、スケールなどの変位量を正確に測定して、
例えばその値を表示器などに表示させ、またNC
機械などを正確にフイードバツク制御することが
可能となる。
Therefore, by counting the count pulses 500a or 500b output in this way, the amount of displacement of the scale etc. can be accurately measured.
For example, display the value on a display, or
It becomes possible to accurately feedback control machines, etc.

カウントパルス作成動作 次に、本実施例の方法に従つて行われる具体的
なカウントパルス作成動作を、スケールなどをア
ツプカウント動作方向に移動した場合を例にとり
説明する。
Count Pulse Creation Operation Next, a specific count pulse creation operation performed according to the method of this embodiment will be described using an example in which a scale or the like is moved in the up-count operation direction.

(イ) スケールなどの低速移動時 前述したように、検出器10から出力される
検出信号φa及びφbはその周波数がスケールな
どの移動撰速度にほぼ比例する。
(a) When the scale or the like moves at low speed As described above, the frequencies of the detection signals φ a and φ b output from the detector 10 are approximately proportional to the moving speed of the scale or the like.

従つて、スケールなどをゆつくり移動した場
合、検出信号φa及びφbの周波数は低く、作成
されるコードデータ200は基準クロツクCP
1の出力周期より充分に長い時間間隔を以て変
化することとなる。
Therefore, when the scale or the like is moved slowly, the frequencies of the detection signals φ a and φ b are low, and the generated code data 200 is based on the reference clock CP.
It changes at a time interval that is sufficiently longer than one output cycle.

第7図には、作成される基準コード300
は、このようにスケールなどをゆつくり移動し
た場合におけるタイミングチヤートの一例が示
されており、基準クロツクCP1が出力される
t00、t10、t20、t30、…の各時点で、それぞれ
4、4、5、5、…のように変化する。従つ
て、この基準コード300の変化を第6図に示
すコードデータ列に照らしてみると、その変化
は基準コードの順方向に添つて1ステツプずつ
シフトしながら行われていることが理解され
る。
FIG. 7 shows the standard code 300 to be created.
shows an example of a timing chart when the scale etc. is moved slowly in this way, and the reference clock CP1 is output.
At each point in time t00, t10, t20, t30, . . ., it changes as 4, 4, 5, 5, . . . , respectively. Therefore, when this change in the reference code 300 is compared with the code data string shown in FIG. 6, it can be seen that the change is made by shifting the reference code one step at a time in the forward direction. .

ここにおいて、例えば基準クロツクCP1が
出力されるt10の時点に着目してみると、その
時点において出力される基準コード300及び
参照コード400はともに「4」であり、両者
は一致するため、アツプカウントパルス500
aが出力されることはない。
For example, if we focus on the time point t10 when the reference clock CP1 is output, the reference code 300 and the reference code 400 output at that time are both "4", and since they match, the up count pulse 500
a is never output.

しかし、次の基準クロツクCP1が出力され
るt20の時点においては、スケールなどの変位
に対応して基準コード300が「5」となり、
両コード300,400は不一致の状態とな
る。この場合には、次に出力クロツクCP2が
最初に出力されるt21のタイミングでアツプカ
ウントパルス500aが出力され、これにより
参照コード400を第6図に示すコードデータ
列に従つて順方向に1ステツプシフトさせる。
However, at time t20 when the next reference clock CP1 is output, the reference code 300 becomes "5" in response to the displacement of the scale, etc.
Both codes 300 and 400 are in a mismatched state. In this case, the up count pulse 500a is output at timing t21 when the output clock CP2 is output for the first time, and this causes the reference code 400 to be incremented by one step in the forward direction according to the code data string shown in FIG. shift.

この結果、参照コード400は「5」とな
り、基準コード300の値と一致するため、ア
ツプカウントパルス500aの出力はその時点
で停止される。
As a result, the reference code 400 becomes "5" and matches the value of the reference code 300, so the output of the up count pulse 500a is stopped at that point.

このようにして、本実施例の方法によれば、
スケールなどがゆつくり移動される場合には、
基準コード300が参照コード400に対し1
ステツプ分シフトする毎に1個のアツプカウン
トパルス500aを出力する。
In this way, according to the method of this example,
If the scale etc. is moved slowly,
Standard code 300 is 1 for reference code 400
One up count pulse 500a is output for each step shift.

従つて、検出器10から出力される検出信号
φa,φbの位相θが、0〜2πの間で1サイクル
周期変化する毎に、確実に8個のカウントパル
ス500aを出力するとこととなり、スケール
などの変位量測定を正確に行うことが可能とな
る。
Therefore, every time the phase θ of the detection signals φ a and φ b output from the detector 10 changes by one cycle between 0 and 2π, eight count pulses 500a are reliably output. It becomes possible to accurately measure the amount of displacement of a scale, etc.

(ロ) スケールなどの高速移動時 これに対し、スケールなどを高速で移動する
と、検出器10からは高周波の検出信号φa
φbが出力され、作成されるコードデータ20
0は、基準クロツクCP1の出力周期に比し相
対的に短い時間間隔で変化することとなる。
(b) When a scale or the like moves at high speed On the other hand, when a scale or the like moves at a high speed, the detector 10 outputs high frequency detection signals φ a ,
φ b is output and the code data 20 created
0 changes at relatively short time intervals compared to the output cycle of the reference clock CP1.

第8図には、このような場合におけるタイミ
ングチヤートの一例が示されており、このよう
な場合には、基準クロツクCP1が出力される
間に、コードデータ200が複数回に渡つて変
化することとなる。
FIG. 8 shows an example of a timing chart in such a case, and in such a case, the code data 200 changes multiple times while the reference clock CP1 is output. becomes.

従つて、基準クロツクCP1に同期して出力
される基準コード300は、t00、t20、t30、
t40…の各時点において、それぞれ4、7、3、
5.7…のように複数のステツプにまたがつてシ
フトする。
Therefore, the reference code 300 output in synchronization with the reference clock CP1 is t00, t20, t30,
At each time point of t40..., 4, 7, 3,
Shift across multiple steps as in 5.7.

このような場合に、基準コード300と参照
コード400とを比較し、両者が不一致の場合
に単に1個のカウントパルスを出力するだけで
は到底正確な測定を行うことができないが、本
発明においては次のようにして基準コード30
0のシフト数に対応したカウントパルスを出力
し、正確な測定を可能としている。
In such a case, it is impossible to perform an accurate measurement by comparing the standard code 300 and the reference code 400 and simply outputting one count pulse if they do not match, but in the present invention, Standard code 30 as follows:
It outputs count pulses corresponding to the number of shifts of 0, making accurate measurement possible.

例えば、基準クロツクCP1が出力されるt10
の時点に着目してみると、この時点において
は、基準コード300として「7」が出力さ
れ、参照コード400としては「4」が出力さ
れている。
For example, t10 when the reference clock CP1 is output
Focusing on the point in time, at this point, "7" is output as the reference code 300, and "4" is output as the reference code 400.

従つて、そのt10の時点においては、基準コ
ード300は、前回出力された基準コードに対
し3ステツプ分順方向へシフトしていることが
理解される。
Therefore, it is understood that at the time t10, the reference code 300 has been shifted forward by three steps with respect to the previously output reference code.

この場合には、出力クロツクCP2が出力さ
れるt11、t12、t13の各タイミングでアツプカ
ウントパルス500aが出力され、各アツプカ
ウントパルス出力毎に、参照コード400を第
6図に示すコードデータ列に従つてその順方向
へ「5」「6」「7」の順に1ステツプずつシフ
トさせる。
In this case, the up count pulse 500a is output at each timing t11, t12, and t13 when the output clock CP2 is output, and each time the up count pulse is output, the reference code 400 is converted into the code data string shown in FIG. Therefore, the numbers are shifted one step at a time in the forward direction in the order of "5", "6", and "7".

このようにして参照コード400をシフトし
て行くと、カウントパルス500aは、合計3
個出力された時点でその出力が停止されること
となる。
By shifting the reference code 400 in this way, the count pulse 500a will be 3 in total.
The output will be stopped when the output is completed.

同様にして、次の基準クロツクCP1が出力
されるt20の時点で、基準コード300として
前回の基準コードに対し4ステツプ分シフトし
た「3」が出力されると、この基準コード30
0と参照コード400とが一致するよう4個の
アツプカウントパルス500aが出力される。
Similarly, at time t20 when the next reference clock CP1 is output, "3", which is shifted by 4 steps from the previous reference code, is output as the reference code 300.
Four up count pulses 500a are output so that 0 and reference code 400 match.

このようにして、本発明によれば、基準クロ
ツクCP1が出力される毎に、基準コード30
0のシフト数に対応した個数のアツプカウント
パルス500aを確実に出力することができ
る。
In this way, according to the invention, each time the reference clock CP1 is output, the reference code 30
The number of up-count pulses 500a corresponding to the number of zero shifts can be reliably output.

従つて、本発明によれば、スケールなどを高
速で移動し、検出器10から高周波の検出信号
φa及びφbが出力される場合であつても、検出
信号φa,φbの位相θが0〜2πの値で1サイク
ル変化する間に確実に8個のカウントパルスを
出力し、その変位量測定を正確に行うことが可
能となる。
Therefore, according to the present invention, even when the scale or the like is moved at high speed and the high frequency detection signals φ a and φ b are output from the detector 10, the phase θ of the detection signals φ a and φ b is It is possible to reliably output eight count pulses while the value changes from 0 to 2π in one cycle, and to accurately measure the amount of displacement.

なお、本実施例においては、アツプカウント
パルス500aの出力を行う場合を例にとり説
明したが、ダウンカウントパルス500bの出
力も同様にして行うことが可能であり、この場
合には、ダウンカウントパルス500bが出力
される毎に、参照コード400を前記コードデ
ータ列に従い逆方向に1ステツプずつサイクリ
ツクにシフトすれば良い。
In this embodiment, the case where the up count pulse 500a is outputted has been explained as an example, but the down count pulse 500b can also be outputted in the same way, and in this case, the down count pulse 500b can be outputted. Each time the reference code 400 is output, the reference code 400 may be cyclically shifted one step at a time in the opposite direction according to the code data string.

他の実施例 なお、前記実施例においては、検出器10から
アナログ長さ検出信号として正弦波及び余弦波を
出力する場合を例にとり説明したが、本発明はこ
れに限らず、他の種類のアナログ長さ検出信号を
用いる場合にも適用可能であることはいうまでも
ない。
Other Embodiments In the above embodiments, the case where a sine wave and a cosine wave are outputted from the detector 10 as an analog length detection signal has been described as an example, but the present invention is not limited to this, and can be applied to other types of detection signals. Needless to say, the present invention is also applicable when using an analog length detection signal.

また、前記実施例においては、デジタル組合せ
信号100を更にコードデータ200に変換して
出力する場合を例にとり説明したが、本発明はこ
れに限らず、デジタル組合せ信号100そのもの
をコードデータとして用いることも可能である。
Further, in the above embodiment, the case where the digital combination signal 100 is further converted into code data 200 and outputted has been explained as an example, but the present invention is not limited to this, and the digital combination signal 100 itself can be used as code data. is also possible.

更に、本実施例においては、検出器から出力さ
れる検出信号φa及びφbを2相/4相変換して用
いた場合を例にとり説明したが、本発明はこれに
限らず、検出信号φa及びφbをそのままデジタル
組合せ信号に変換しても良く、またこれ以外にこ
の検出信号φa,φbから8相、16相…の多相信号
を二次的に作成し、これらの信号からデジタル組
合せ信号を作成することも可能である。
Furthermore, in this embodiment, the case where the detection signals φ a and φ b outputted from the detector are converted into two-phase/four-phase conversion is explained as an example, but the present invention is not limited to this. φ a and φ b may be converted directly into a digital combination signal, or in addition to this, 8-phase, 16-phase, etc. polyphase signals may be created secondarily from the detection signals φ a and φ b , and these signals may be converted into digital combination signals. It is also possible to create a digital combination signal from the signals.

[発明の効果] 以上説明したように、本発明によれば、スケー
ルなどを高速で移動し検出器から高周波の変位検
出信号を出力するような場合であつても、その変
位量に対応したカウントパルスを確実に出力し正
確な変位測定を行うことが可能となる。
[Effects of the Invention] As explained above, according to the present invention, even when a scale or the like is moved at high speed and a high-frequency displacement detection signal is output from the detector, a count corresponding to the amount of displacement can be calculated. It becomes possible to reliably output pulses and perform accurate displacement measurements.

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

第1図は本発明に係るカウントパルス発生方法
示すフローチヤート図、第2図は本発明に用いら
れる変位検出装置の好適な実施例を示すブロツク
図、第3図は本実施例において行われるコードデ
ータ作成動作のタイミングチヤート図、第4図及
び第5図は本実施例において行われるカウントパ
ルス作成手順の工程図、第6図は本実施例におい
て用いられるデジタル組み合せ信号とコードデー
タとの対応関係を示す説明図、第7図及び第8図
はカウントパルス作成手順を示すタイミングチヤ
ート図、第9図は従来のカウントパルス作成回路
の説明図、第10図は第9図に示す回路のタイミ
ングチヤート図である。 10……検出器、12……2相/4相変換回
路、14……信号処理回路、φa,φb,φc,φd
…アナログ長さ検出信号、100……デジタル組
合せ信号、200……コードデータ、300……
基準コード、400……参照コード、500a,
500b……カウントパルス、CP1……基準ク
ロツク、CP2……出力クロツク。
FIG. 1 is a flowchart showing a count pulse generation method according to the present invention, FIG. 2 is a block diagram showing a preferred embodiment of a displacement detection device used in the present invention, and FIG. 3 is a code executed in this embodiment. A timing chart of the data creation operation, Figures 4 and 5 are process diagrams of the count pulse creation procedure performed in this embodiment, and Figure 6 is the correspondence between the digital combination signal and code data used in this embodiment. FIG. 7 and FIG. 8 are timing chart diagrams showing the count pulse creation procedure. FIG. 9 is an explanatory diagram of a conventional count pulse creation circuit. FIG. 10 is a timing chart of the circuit shown in FIG. 9. It is a diagram. 10...Detector, 12...2-phase/4-phase conversion circuit, 14...Signal processing circuit, φa , φb , φc , φd ...
...Analog length detection signal, 100...Digital combination signal, 200...Code data, 300...
Standard code, 400...Reference code, 500a,
500b...Count pulse, CP1...Reference clock, CP2...Output clock.

Claims (1)

【特許請求の範囲】 1 検出器から出力される位相の異なる複数のア
ナログ長さ検出信号を、所定の基準クロツクに同
期して信号処理することにより、変位検出用のカ
ウントパルスを出力する同期型カウントパルス作
成方法において、 前記アナログ長さ検出信号に基づき、所定のデ
ジタル組合せ信号を作成し、基準クロツクが出力
される毎にデジタル組合せ信号により特定される
コードデータを基準コードとして出力する基準コ
ード作成工程と、 基準クロツクが出力される毎に、1クロツク前
の基準コードを参照コードとして出力する参照コ
ード作成工程と、 基準コードと参照コードとを比較し、両者が一
致するまでの間、所定の短クロツク周期に設定さ
れた出力クロツクが出力される毎に、前記検出信
号の1サイクル周期内に順次出力されるコードデ
ータ列に従い参照コードを1ステツプずつサイク
リツクにシフトしながらカウントパルスを出力す
るカウントパルス出力工程と、 を含み、検出器のアナログ長さ検出信号の周波数
にかかわりなく変位量に対応したカウントパルス
の出力を行うことを特徴とするカウントパルス作
成方法。 2 特許請求の範囲1記載の方法において、基準
コード作成工程は、 アナログ長さ検出信号を信号処理し、所定のデ
ジタル組み合わせ信号を作成する組合せ信号作成
工程と、 このデジタル組み合わせ信号を所定のコードデ
ータに変換出力する変換工程と、 基準クロツクが出力される毎にコードデータを
基準コードとして出力する出力工程と、 を含むことを特徴とするカウントパルス作成方
法。
[Claims] 1. A synchronous type that outputs count pulses for displacement detection by signal processing a plurality of analog length detection signals with different phases output from a detector in synchronization with a predetermined reference clock. In the count pulse generation method, a predetermined digital combination signal is created based on the analog length detection signal, and each time a reference clock is output, code data specified by the digital combination signal is output as a reference code. A reference code creation process that outputs the reference code one clock before each time the reference clock is output as a reference code; A reference code creation process that compares the reference code with the reference code and performs a predetermined process until the two match. Each time an output clock set to a short clock cycle is output, a count pulse is output while cyclically shifting the reference code one step at a time according to the code data string sequentially output within one cycle cycle of the detection signal. 1. A count pulse generation method comprising: a pulse output step; and outputting a count pulse corresponding to a displacement amount regardless of the frequency of an analog length detection signal of a detector. 2. In the method according to claim 1, the reference code creation step includes: a combination signal creation step of processing the analog length detection signal to create a predetermined digital combination signal; and converting the digital combination signal into predetermined code data. 1. A count pulse generation method comprising: a conversion step of converting and outputting code data as a reference code each time a reference clock is output; and an output step of outputting code data as a reference code each time a reference clock is output.
JP29810685A 1985-12-27 1985-12-27 Count pulse generating method Granted JPS62156520A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP29810685A JPS62156520A (en) 1985-12-27 1985-12-27 Count pulse generating method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP29810685A JPS62156520A (en) 1985-12-27 1985-12-27 Count pulse generating method

Publications (2)

Publication Number Publication Date
JPS62156520A JPS62156520A (en) 1987-07-11
JPH0431333B2 true JPH0431333B2 (en) 1992-05-26

Family

ID=17855234

Family Applications (1)

Application Number Title Priority Date Filing Date
JP29810685A Granted JPS62156520A (en) 1985-12-27 1985-12-27 Count pulse generating method

Country Status (1)

Country Link
JP (1) JPS62156520A (en)

Also Published As

Publication number Publication date
JPS62156520A (en) 1987-07-11

Similar Documents

Publication Publication Date Title
US4450403A (en) Method and apparatus for determining rotational speed
US6389373B1 (en) Resolver signal processing system
US5710509A (en) Phase difference detection device for an inductive position detector
JPS62162968A (en) speed detection device
EP0331189B1 (en) Position/speed detection method and apparatus
US5382899A (en) Position detecting and time measuring device providing measurement finer than a clock signal period
US7015832B2 (en) Pulse width modulation based digital incremental encoder
US5920494A (en) Method and device for varying interpolation factors
US4795954A (en) Resolver controlling method and apparatus
JPS58117461A (en) Speed detector
JP2003185472A (en) Absolute encoder and its absolute value signal generation processing method
US4884226A (en) Method for detecting position
JPH0431333B2 (en)
JPH0342766B2 (en)
JPH0466288B2 (en)
EP0200791A1 (en) Method and apparatus for detecting position
EP0257100B1 (en) Pulse distribution type position detector
JP3860324B2 (en) Motor speed control device
JP3015751B2 (en) Encoder interpolation circuit
JPH0449892B2 (en)
US7154947B2 (en) Coincidence detection apparatus and method
JPH06258097A (en) Displacement measuring apparatus
JPS5951007B2 (en) position detection device
JPH0449891B2 (en)
JPH02173522A (en) Position detector

Legal Events

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