JPH0548461A - A/d converter - Google Patents

A/d converter

Info

Publication number
JPH0548461A
JPH0548461A JP20536291A JP20536291A JPH0548461A JP H0548461 A JPH0548461 A JP H0548461A JP 20536291 A JP20536291 A JP 20536291A JP 20536291 A JP20536291 A JP 20536291A JP H0548461 A JPH0548461 A JP H0548461A
Authority
JP
Japan
Prior art keywords
counter
counting
data
converter
proportional
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP20536291A
Other languages
Japanese (ja)
Inventor
Tomoyasu Hachiro
友康 鉢呂
Kuniaki Yasukawa
国明 安川
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.)
Meidensha Corp
Meidensha Electric Manufacturing Co Ltd
Original Assignee
Meidensha Corp
Meidensha Electric Manufacturing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Meidensha Corp, Meidensha Electric Manufacturing Co Ltd filed Critical Meidensha Corp
Priority to JP20536291A priority Critical patent/JPH0548461A/en
Publication of JPH0548461A publication Critical patent/JPH0548461A/en
Pending legal-status Critical Current

Links

Landscapes

  • Analogue/Digital Conversion (AREA)

Abstract

PURPOSE:To improve the resolution and the versatility by providing 1st and 2nd counters to the A/D converter, counting a clock signal only during the count operation of the 1st counter to obtain a digital value proportional to an input voltage and using a setting value for the 1st counter to be a prescribed count time. CONSTITUTION:A V/F converter 11 outputs a pulse of a frequency F proportional to an analog input voltage V. A 1st counter 12 counts number of pulses by a value N set by a computer 13 and an on-state is obtained at an output OUT for that time. A 2nd counter 14 counts the number of clocks from a reference oscillator 15 only for a period when the output OUT of the counter 12 is in the on-state to obtain a count M. The computer 13 obtains a digital data proportional to the analog input based on a preceding setting data and a coefficient. Based on the data, the setting value N of the 1st counter 12 is adjusted to make almost the count time constant.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、アナログ信号をディジ
タル信号に変換してコンピュータ等に取り込むためのA
/D変換装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an A for converting an analog signal into a digital signal and loading it into a computer or the like.
The present invention relates to a / D converter.

【0002】[0002]

【従来の技術】コンピュータを制御中枢部とする各種制
御装置は、計測値や設定値になる多くのアナログ信号を
ディジタル信号に変換してデータ処理を行い、制御性能
の向上を図っている。
2. Description of the Related Art Various control devices using a computer as a control center convert many analog signals of measured values and set values into digital signals and perform data processing to improve control performance.

【0003】従来のA/D変換装置には図4に示すもの
がある。同図(a)の方式は、ポテンショメータ等にさ
れる設定器1からのアナログ電圧をA/D変換器2でデ
ィジタル信号に変換してコンピュータ3に取り込む。同
図(b)の方式は、設定器1からのアナログ電圧を電圧
−周波数変換器4で比例した周波数のパルスに変換し、
このパルスをカウンタ5の計数入力とし、コンピュータ
3からの一定時間のゲート信号期間だけカウンタ5を計
数動作させ、カウンタ5の計数値をアナログ電圧に比例
したディジタル信号としてコンピュータ3に取り込む。
A conventional A / D converter is shown in FIG. In the system shown in FIG. 3A, an analog voltage from a setting device 1 such as a potentiometer is converted into a digital signal by an A / D converter 2 and is taken into a computer 3. In the method of FIG. 2B, the analog voltage from the setter 1 is converted into a pulse having a proportional frequency by the voltage-frequency converter 4,
This pulse is used as the count input of the counter 5, and the counter 5 is caused to count for the gate signal period of the fixed time from the computer 3, and the count value of the counter 5 is taken into the computer 3 as a digital signal proportional to the analog voltage.

【0004】なお、計測値を取り込むには設定器1がセ
ンサと電圧増幅器に置換される。
The setter 1 is replaced with a sensor and a voltage amplifier to capture the measured value.

【0005】[0005]

【発明が解決しようとする課題】従来装置において、A
/D変換器2は各種市販されているが、10ビット以上
の分解能を持つものは高価なものになる。
In the conventional device, the A
Various types of / D converters 2 are commercially available, but those having a resolution of 10 bits or more are expensive.

【0006】一方、V/F変換器4とカウンタ5を使用
するものは、分解能を高めるには計数する時間(サンプ
ル時間)を長くするか、又はV/F変換器4のフルスケ
ール周波数を高める。しかし、計数時間を長くすると、
変換時間(データ入力間隔)が、0.1秒など長くなっ
てしまい、計測値の取り込みには応答性で問題が残る。
逆に、フルスケール周波数を高める場合には高価なV/
F変換器となってしまう。
On the other hand, in the case of using the V / F converter 4 and the counter 5, in order to improve the resolution, the counting time (sample time) is lengthened or the full-scale frequency of the V / F converter 4 is increased. .. However, if you increase the counting time,
The conversion time (data input interval) becomes long, such as 0.1 seconds, and the problem of responsiveness remains in the acquisition of measured values.
Conversely, when increasing the full-scale frequency, expensive V /
It becomes an F converter.

【0007】例えば、16ビットの分解能を得るにはフ
ルスケール周波数が1MHzで計数時間に65msを必
要とする。
For example, to obtain a resolution of 16 bits, a full-scale frequency is 1 MHz and a counting time of 65 ms is required.

【0008】本発明の目的は、電圧−周波数変換器とカ
ウンタによるA/D変換装置において、フルスケール周
波数を低くかつ計数時間を短くしながら高分解能を得る
と共に汎用性の高いA/D変換装置を提供することにあ
る。
An object of the present invention is to provide an A / D converter having a voltage-frequency converter and a counter, which has a high full resolution while having a low full-scale frequency and a short counting time, and which has high versatility. To provide.

【0009】[0009]

【課題を解決するための手段】本発明は前記課題の解決
を図るため、アナログ入力電圧に比例した周波数のパル
スを得る電圧−周波数変換器と、前記パルスを計数入力
とし設定された値Nまで計数する第1のカウンタと、前
記第1のカウンタの計数動作中だけクロック信号を計数
する第2のカウンタと、前記第2のカウンタの計数値M
から前記アナログ入力電圧に比例したディジタルデータ
nを得ると共に該データnから前記第1のカウンタの計
数時間をほぼ一定にする値を求めて該第1のカウンタの
設定値Nを与える演算手段とを備えたことを特徴とす
る。
In order to solve the above-mentioned problems, the present invention provides a voltage-frequency converter which obtains a pulse having a frequency proportional to an analog input voltage, and a value N set with the pulse as a count input. A first counter for counting, a second counter for counting clock signals only during the counting operation of the first counter, and a count value M of the second counter
From the data n to obtain a digital data n proportional to the analog input voltage, obtain a value for making the counting time of the first counter substantially constant, and give a set value N of the first counter. It is characterized by having.

【0010】[0010]

【作用】上記構成になる本発明によれば、V/F変換器
及び第1のカウンタによる変換及び計数の周波数を低く
することでフルスケール及び計数時間を低く設定し、第
1のカウンタの計数時間に第2のカウンタがクロックを
計数したデータを変換したディジタルデータとすること
で高い分解能を得る。また、第1のカウンタの設定値N
をほぼ一定の計数時間とすることで応答性の低下を起こ
すことなく広範囲のアナログ入力電圧に対応できるよう
にする。
According to the present invention having the above structure, the full scale and the counting time are set low by lowering the frequency of conversion and counting by the V / F converter and the first counter, and the counting of the first counter is performed. High resolution can be obtained by converting the data obtained by counting the clock by the second counter into digital data converted at time. In addition, the set value N of the first counter
Is set to a substantially constant counting time, so that a wide range of analog input voltages can be supported without causing deterioration in response.

【0011】[0011]

【実施例】図1は本発明の一実施例を示す装置構成図で
ある。V/F変換器11はアナログ入力電圧Vに比例し
た周波数Fのパルスを出力する。第1のカウンタ12は
コンピュータ13から設定(例えばプリセット)される
値NだけV/F変換器11からのパルスを計数し、この
間の出力OUTにオン状態を得る。また、カウンタ12
はコンピュータ13からのトリガ信号(G入力)が与え
られたときから最初のパルスFの計数を始め、最終カウ
ントNで出力をオフにする。従って、カウンタ12の計
数はV/F変換器11の出力パルスに完全に同期する。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 is a block diagram of an apparatus showing an embodiment of the present invention. The V / F converter 11 outputs a pulse having a frequency F proportional to the analog input voltage V. The first counter 12 counts the pulses from the V / F converter 11 by a value N set (for example, preset) from the computer 13, and obtains an ON state at the output OUT during this period. Also, the counter 12
Starts counting the first pulse F when the trigger signal (G input) from the computer 13 is given, and turns off the output at the final count N. Therefore, the count of the counter 12 is completely synchronized with the output pulse of the V / F converter 11.

【0012】第2のカウンタ14は、カウンタ12の出
力OUTがオンになったときにリセットされ該オン状態
にある期間TCだけ基準発振器15(又はコンピュータ
13)からのクロックを計数し、計数値Mを得る。
The second counter 14 is reset when the output OUT of the counter 12 is turned on, counts the clock from the reference oscillator 15 (or the computer 13) for the period T C in which the output OUT is turned on, and counts the count value. Get M.

【0013】コンピュータ13は、カウンタ12のカウ
ント終了時の出力OUTを割込み信号INTとして起
動、又はカウンタ12のカウント終了をポーリングで受
けて起動される。この起動によるコンピュータ13の処
理は図2に示す手順になる。
The computer 13 is started by using the output OUT at the end of counting of the counter 12 as an interrupt signal INT or by receiving the end of counting of the counter 12 by polling. The processing of the computer 13 by this activation is as shown in FIG.

【0014】コンピュータ13はカウンタ14のデータ
Mを取り込み(ステップS1)、このデータMと前回の
設定データNi-1及び係数KCからアナログ入力に比例し
たディジタルデータとしての値nとして n=(Ni-1×KC)/M の演算によって求め(ステップS2)、さらに係数KN
を乗じた設定データNi(=n×KN)を求め(ステップ
S3)、この設定データNiをカウンタ12にストアし
(ステップS4)、カウンタ12のトリガを発生する
(ステップS5)。ここで、係数KCはコンピュータ1
3内で実際に必要とするデータに変換する係数であり、
基準発振器15のクロック周波数等から決まる。また、
係数KNは今回のデータnから次回のサンプル時間をほ
ぼ一定の時間TCにするためのものである。
The computer 13 takes in the data M of the counter 14 (step S1), and n = (as a value n as digital data proportional to the analog input from this data M, the previous setting data N i-1 and the coefficient K C. N i-1 × K C ) / M is calculated (step S2), and the coefficient K N
Setting data N i (= n × K N ) multiplied by is obtained (step S3), this setting data N i is stored in the counter 12 (step S4), and a trigger for the counter 12 is generated (step S5). Here, the coefficient K C is the computer 1
It is a coefficient that is converted into the data actually needed within 3.
It is determined from the clock frequency of the reference oscillator 15 and the like. Also,
The coefficient K N is used to make the next sampling time from the current data n a substantially constant time T C.

【0015】本実施例の動作波形図は図3に示すように
なる。アナログ入力電圧Vに比例した周波数のパルスが
V/F変換器11の出力Fとして取り出され、コンピュ
ータ13からの設定データNの設定に次ぐトリガ入力に
よってカウンタ12が信号Fに同期して計数を開始し
(時刻t1)、同時にカウンタ12の出力outがオン
状態になってカウンタ14を瞬時リセットする。
The operation waveform diagram of this embodiment is as shown in FIG. A pulse having a frequency proportional to the analog input voltage V is taken out as the output F of the V / F converter 11, and the counter 12 starts counting in synchronization with the signal F by the trigger input following the setting of the setting data N from the computer 13. At the same time (time t 1 ), at the same time, the output out of the counter 12 is turned on and the counter 14 is instantly reset.

【0016】従って、カウンタ12の計数開始と同時に
カウンタ14の計数が開始され、カウンタ12の計数値
に対してカウンタ14の計数値はクロック周波数fC
カウンタ12の入力Fの比率で増加し、データMは信号
Fに比例している。
Accordingly, the counting of the counter 14 is started at the same time when the counting of the counter 12 is started, and the counting value of the counter 14 increases with respect to the counting value of the counter 12 by the ratio of the clock frequency f C and the input F of the counter 12. The data M is proportional to the signal F.

【0017】カウンタ12の計数値が設定データNに達
すると(時刻t2)、その出力outがオンからオフに
切り換わり、同時にカウンタ14の計数も停止し、また
コンピュータ13には割込みINTが行われる。
When the count value of the counter 12 reaches the set data N (time t 2 ), its output out is switched from on to off, the counting of the counter 14 is stopped at the same time, and the interrupt INT is sent to the computer 13. Be seen.

【0018】この割込みにより、コンピュータ13は図
2の手順に従ってデータMのロードと、このデータMか
らのディジタルデータnの演算によりアナログ入力電圧
Vに比例した値として保存し、次いで該データnの大小
によって係数KNを変えて次回の設定データNiを求め、
カウンタ12へ設定値Nとしてストアし、カウンタ12
のトリガによってカウンタ12,14の計数動作を再開
させる。
By this interrupt, the computer 13 stores the data M as a value proportional to the analog input voltage V by loading the data M and calculating the digital data n from this data M according to the procedure of FIG. By changing the coefficient K N to obtain the next setting data N i ,
The set value N is stored in the counter 12, and the counter 12
The counting operation of the counters 12 and 14 is restarted by the trigger of.

【0019】ここで、KNの乗算によって設定データN
はカウンタ入力Fの周波数変化にも一定の計数時間TC
になるようにするため、実際に使用するディジタルデー
タnはアナログ入力に比例させるためには前回のN設定
に使用した係数KNによる換算を行う。
[0019] In this case, set by the multiplication of K N data N
Is a constant counting time T C even when the frequency of the counter input F changes.
Therefore, in order to make the digital data n actually used proportional to the analog input, conversion is performed by the coefficient K N used for the previous N setting.

【0020】本実施例によれば、カウンタ12によって
計測時間(サンプル時間)TCに見合った設定データN
だけ計数し、この計数中の時間TCにカウンタ14がク
ロックを計数することでアナログ入力Vに比例したディ
ジタルデータを求める。
According to this embodiment, the counter 12 sets the setting data N corresponding to the measurement time (sampling time) T C.
The counter 14 counts the clock at the time T C during the counting to obtain digital data proportional to the analog input V.

【0021】従って、V/F変換器11の出力に完全に
同期した計数になって計数開始,終了タイミングのずれ
が無く、高精度のA/D変換装置になる。
Therefore, the counting is completely synchronized with the output of the V / F converter 11, and there is no deviation in the timing of starting and ending the counting, and a highly accurate A / D converter is obtained.

【0022】また、求められるディジタルデータnの分
解能はカウンタ14の計数値Mによって決まり、このM
は計数時間TCをほぼ一定に保つためM=fC×TCとな
り、分解能がfC及びTCによって決まる。このことは、
設定データNの値には影響されないこと、即ちV/F変
換器11のフルスケールは低くかつ第1のカウンタ計数
時間を低くして高分解能を実現できることになる。例え
ば、16ビットの分解能を得るには、F=200KH
z、fC=8MHz、TC=8.2msで済み、フルスケ
ールを低くし、計数時間TCも10ms程度に短くする
ことができる。さらに、アナログ入力範囲を任意にして
汎用性を高めることができる。
The resolution of the digital data n to be obtained is determined by the count value M of the counter 14, and this M
In order to keep the counting time T C substantially constant, M = f C × T C , and the resolution is determined by f C and T C. This is
It is not affected by the value of the setting data N, that is, the full scale of the V / F converter 11 is low and the first counter counting time is low, so that high resolution can be realized. For example, to obtain 16-bit resolution, F = 200KH
z, f C = 8 MHz and T C = 8.2 ms are sufficient, the full scale can be lowered, and the counting time T C can be shortened to about 10 ms. Furthermore, the versatility can be enhanced by making the analog input range optional.

【0023】なお、実施例において、コンピュータ13
による図2の処理はA/D変換装置専用の演算手段を設
け、この演算手段からコンピュータ13にA/D変換し
たディジタルデータのみを与える構成にすることができ
る。
In the embodiment, the computer 13
The processing of FIG. 2 can be configured such that arithmetic means dedicated to the A / D conversion device is provided and only the digital data that has been A / D converted is provided to the computer 13 from this arithmetic means.

【0024】[0024]

【発明の効果】以上のとおり、本発明によれば、V/F
変換器と第1のカウンタによる低い周波数での設定値N
までの計数時間に第2のカウンタでクロックを計数し、
この計数値にアナログ入力電圧に比例したディジタルデ
ータを得るようにし、該データの基に第1のカウンタの
設定値を計数時間がほぼ一定になるよう設定するように
したため、V/F変換器及び第1のカウンタの周波数及
び計数時間を低くして一般の安価なV/F変換器を使用
できると共に応答性を低下させることなく高い分解能で
しかも汎用性の高い装置になる。
As described above, according to the present invention, V / F
Set value N at low frequency by converter and first counter
Count the clock with the second counter during the counting time up to
Digital data proportional to the analog input voltage is obtained from this count value, and the set value of the first counter is set based on the data so that the count time becomes almost constant. Therefore, the V / F converter and By lowering the frequency and counting time of the first counter, a general inexpensive V / F converter can be used, and a device with high resolution and high versatility can be obtained without lowering the response.

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

【図1】実施例の装置構成図。FIG. 1 is a device configuration diagram of an embodiment.

【図2】実施例におけるコンピュータの処理手順図。FIG. 2 is a processing procedure diagram of a computer in the embodiment.

【図3】実施例の各部波形図。FIG. 3 is a waveform chart of each part of the embodiment.

【図4】従来の装置構成図。FIG. 4 is a configuration diagram of a conventional device.

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

11…V/F変換器、12…カウンタ、13…コンピュ
ータ、14…カウンタ、15…基準発振器。
11 ... V / F converter, 12 ... Counter, 13 ... Computer, 14 ... Counter, 15 ... Reference oscillator.

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 アナログ入力電圧に比例した周波数のパ
ルスを得る電圧−周波数変換器と、前記パルスを計数入
力とし設定された値Nまで計数する第1のカウンタと、
前記第1のカウンタの計数動作中だけクロック信号を計
数する第2のカウンタと、前記第2のカウンタの計数値
Mから前記アナログ入力電圧に比例したディジタルデー
タnを得ると共に該データnから前記第1のカウンタの
計数時間をほぼ一定にする値を求めて該第1のカウンタ
の設定値Nを与える演算手段とを備えたことを特徴とす
るA/D変換装置。
1. A voltage-frequency converter that obtains a pulse having a frequency proportional to an analog input voltage, and a first counter that counts the pulse to a set value N by using the pulse as a count input.
A second counter that counts clock signals only during the counting operation of the first counter, and digital data n proportional to the analog input voltage is obtained from the count value M of the second counter, and the digital data n is obtained from the data n. An A / D conversion device, comprising: an arithmetic unit that obtains a value for making the counting time of the first counter substantially constant and gives the set value N of the first counter.
JP20536291A 1991-08-16 1991-08-16 A/d converter Pending JPH0548461A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP20536291A JPH0548461A (en) 1991-08-16 1991-08-16 A/d converter

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP20536291A JPH0548461A (en) 1991-08-16 1991-08-16 A/d converter

Publications (1)

Publication Number Publication Date
JPH0548461A true JPH0548461A (en) 1993-02-26

Family

ID=16505607

Family Applications (1)

Application Number Title Priority Date Filing Date
JP20536291A Pending JPH0548461A (en) 1991-08-16 1991-08-16 A/d converter

Country Status (1)

Country Link
JP (1) JPH0548461A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017011667A (en) * 2015-06-22 2017-01-12 エルセンElssen Sensor device and sensing method
US12388397B2 (en) 2022-10-31 2025-08-12 Asahi Kasei Microdevices Corporation Clock generation apparatus, clock generation method, adjustment apparatus, adjustment method, and non-transitory computer readable medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017011667A (en) * 2015-06-22 2017-01-12 エルセンElssen Sensor device and sensing method
US12388397B2 (en) 2022-10-31 2025-08-12 Asahi Kasei Microdevices Corporation Clock generation apparatus, clock generation method, adjustment apparatus, adjustment method, and non-transitory computer readable medium

Similar Documents

Publication Publication Date Title
JPH0548461A (en) A/d converter
JPS6322330B2 (en)
JP3732588B2 (en) Integrating A / D Converter and A / D Conversion Method
JPH0516551Y2 (en)
JPH06103293B2 (en) Ultrasonic measurement device A / D conversion processing method
JP2645374B2 (en) Phase difference or relative frequency deviation measuring device
JPS62143524A (en) Digital/analog converter
JPS6321511A (en) Testing pulse oscillator
JP3284146B2 (en) Waveform data calculation device
JP3171466B2 (en) Vector voltage ratio measuring method and vector voltage ratio measuring device
JP2971307B2 (en) Waveform recording device
JPH0798336A (en) Sampling type measuring device
JPH055514Y2 (en)
JPH05211442A (en) Test method for a/d converter
SU1441323A2 (en) Digital voltmeter
JPS63286025A (en) Integration type a/d converter
SU1479878A1 (en) Device for recording single shocks
JP2607113B2 (en) A / D conversion method
JPS62148882A (en) Time measuring instrument
SU877448A1 (en) Device for determination of stroboscopic transducer graduation characteristics
JPH07294564A (en) Waveform detector
JP3207952B2 (en) Digital oscilloscope
JPH0721509B2 (en) Digital waveform display
SU1478130A1 (en) Device for suppressing non-stabilities of stroboscopic recorder
RU1795276C (en) Nonuniform illumination zone detector