[go: up one dir, main page]

JPH0115087B2 - - Google Patents

Info

Publication number
JPH0115087B2
JPH0115087B2 JP15084783A JP15084783A JPH0115087B2 JP H0115087 B2 JPH0115087 B2 JP H0115087B2 JP 15084783 A JP15084783 A JP 15084783A JP 15084783 A JP15084783 A JP 15084783A JP H0115087 B2 JPH0115087 B2 JP H0115087B2
Authority
JP
Japan
Prior art keywords
conversion
signal
analog
digital
terminal
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
JP15084783A
Other languages
Japanese (ja)
Other versions
JPS6041122A (en
Inventor
Minoru Takahashi
Hirotoshi Tono
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.)
Denso Ten Ltd
Original Assignee
Denso Ten 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 Denso Ten Ltd filed Critical Denso Ten Ltd
Priority to JP15084783A priority Critical patent/JPS6041122A/en
Publication of JPS6041122A publication Critical patent/JPS6041122A/en
Publication of JPH0115087B2 publication Critical patent/JPH0115087B2/ja
Granted legal-status Critical Current

Links

Landscapes

  • Control By Computers (AREA)
  • Analogue/Digital Conversion (AREA)
  • Electrical Control Of Air Or Fuel Supplied To Internal-Combustion Engine (AREA)
  • Combined Controls Of Internal Combustion Engines (AREA)

Description

【発明の詳細な説明】 技術分野 本発明は、アナログ信号をデジタル信号に変換
するアナログ/デジタル変換方式に関する。
DETAILED DESCRIPTION OF THE INVENTION Technical Field The present invention relates to an analog/digital conversion method for converting an analog signal into a digital signal.

背景技術 第1図は、先行技術におけるアナログ/デジタ
ル変換方式を示すブロツク図である。アナログ/
デジタルコンバータAにおけるマルチプレクサ1
の端子M1〜Miには電圧V1〜Viが与えられる。
マルチプレクサ1の出力は、ライン2を介して電
池3の負極に接続される。電池3の正極は、バツ
フアゲート4およびスイツチ5を介して比較器6
の非反転入力端子に接続される。比較器6の非反
転入力端子と接地間には、定電流源7およびコン
デンサ8が接続される。比較器6の反転入力端子
には、電池9の正極が接続される。比較器6の出
力は、端子10に接続される。ライン11は端子
12に接続され、ライン11に与えられる信号が
ハイレベルのとき、スイツチ5はオープンする。
ライン13は端子14に接続され、ライン13に
伝送される信号によつて、マルチプレクサ1の出
力がセレクトされる。
BACKGROUND ART FIG. 1 is a block diagram illustrating a prior art analog/digital conversion system. analog/
Multiplexer 1 in digital converter A
Voltages V1 to Vi are applied to terminals M1 to Mi of.
The output of multiplexer 1 is connected via line 2 to the negative pole of battery 3. The positive electrode of the battery 3 is connected to a comparator 6 via a buffer gate 4 and a switch 5.
is connected to the non-inverting input terminal of A constant current source 7 and a capacitor 8 are connected between the non-inverting input terminal of the comparator 6 and ground. The positive electrode of the battery 9 is connected to the inverting input terminal of the comparator 6 . The output of comparator 6 is connected to terminal 10. Line 11 is connected to terminal 12, and when the signal applied to line 11 is at a high level, switch 5 opens.
Line 13 is connected to terminal 14, and the signal transmitted on line 13 selects the output of multiplexer 1.

マイクロコンピユータBにおけるエツジ検出回
路15における端子16は、アナログ/デジタル
コンバータAの端子10に接続される。また端子
17は端子12に、端子18は端子14にそれぞ
れ接続される。エツヂ検出回路15は、ライン1
9を介して第1の変換完了信号を送出し、またラ
イン21を介してセーブレジスタ22に接続され
る。フリーランカウンタ23にはクロツク信号が
与えられ、フリーランカウンタ23の出力はセー
ブレジスタ22に接続される。
Terminal 16 of edge detection circuit 15 in microcomputer B is connected to terminal 10 of analog/digital converter A. Further, the terminal 17 is connected to the terminal 12, and the terminal 18 is connected to the terminal 14, respectively. The edge detection circuit 15 is connected to line 1.
It sends out a first conversion complete signal via line 9 and is also connected to a save register 22 via line 21. A clock signal is applied to the free run counter 23, and the output of the free run counter 23 is connected to the save register 22.

ここで第2図の波形図を参照して、前記第1図
示の先行技術の動作を説明する。第2図1は、第
1図のコンデンサ8の電位を示す波形図である。
電圧VBE1は電池3の電圧であり、電圧VBE2
は比較器6の反転入力端子に与えられる電圧であ
る。たとえば、アナログ/デジタルコンバータA
の端子Miに与えられた正常なアナログ信号をデ
ジタル信号に変換した場合は、第2図1の実線で
示すような波形になる。マイクロプロセツサBの
端子17に与えられる第2図2の信号の立上がり
で時刻t1を読み込み、変換時間経過後の時刻t
2では、第2図3に示すストツプ信号が立下がり
セーブレジスタ22に時刻t2が記憶されると同
時に、第2図4に示す第1の変換完了信号20が
セツトされる。
The operation of the prior art shown in FIG. 1 will now be described with reference to the waveform diagram in FIG. 2. FIG. 21 is a waveform diagram showing the potential of the capacitor 8 in FIG. 1.
Voltage VBE1 is the voltage of battery 3, voltage VBE2
is the voltage applied to the inverting input terminal of the comparator 6. For example, analog/digital converter A
When a normal analog signal applied to the terminal Mi of the terminal Mi is converted into a digital signal, the waveform becomes as shown by the solid line in FIG. The time t1 is read at the rising edge of the signal shown in FIG. 2 applied to the terminal 17 of the microprocessor B, and the time t is read after the conversion time has elapsed.
2, the stop signal shown in FIG. 2 falls and time t2 is stored in the save register 22, and at the same time, the first conversion completion signal 20 shown in FIG. 2 is set.

第2図の破線で示したようにアースレベルより
も低い電圧を変換する場合、第2図3の破線で示
すようにストツプ信号が変化しないため終了時刻
も記憶されないし、第1の変換完了信号20もセ
ツトされないことになる。このような場合いつま
でも変換の終了を待つことになり、以後の制御に
不具合をもたらすことになる。実際には、このよ
うな不具合に至らない様に事前に設計措置が取ら
れる。たとえば、負電圧レベルの最大値(制御器
のアースレベルやセンサのアースレベル)を想定
し、電圧VBE1をその最大値以上に設定し、ど
のような入力でも必ずコンデンサCの電位が電圧
VBE2以上になるように設計する。しかしこの
場合は、電圧VBE1+Viの最大値が規制されて
いるため必然的に電圧Viの最大値が圧縮され、
アナログ/デジタル変換の精度が悪くなる。
When converting a voltage lower than the ground level as shown by the broken line in Fig. 2, the stop signal does not change as shown by the broken line in Fig. 2, so the end time is not stored, and the first conversion completion signal 20 will also not be set. In such a case, the user will have to wait forever for the conversion to finish, which will cause problems in subsequent control. In reality, design measures are taken in advance to prevent such problems from occurring. For example, assuming the maximum value of the negative voltage level (controller ground level or sensor ground level), set the voltage VBE1 above that maximum value, and make sure that the potential of capacitor C is the voltage no matter what the input is.
Design to have a VBE of 2 or higher. However, in this case, since the maximum value of voltage VBE1 + Vi is regulated, the maximum value of voltage Vi is inevitably compressed,
Analog/digital conversion accuracy deteriorates.

目 的 本発明の目的は、上述の技術的課題を解決し、
アナログ/デジタル変換の精度を上昇させるアナ
ログ/デジタル変換方式を提供することである。
Purpose The purpose of the present invention is to solve the above-mentioned technical problem,
An object of the present invention is to provide an analog/digital conversion method that increases the accuracy of analog/digital conversion.

実施例 第3図は、本発明の一実施例のブロツク図であ
る。アナログ/デジタルコンバータA1の各端子
P1〜Piには、信号V1〜Viがそれぞれ与えら
れる。アナログ/デジタルコンバータA1の端子
Q1〜Q3は、処理回路であるマイクロコンピユ
ータB1の端子B2〜B4にそれぞれ接続され
る。端子B2に与えられたスタート信号と、端子
B3に与えられたストツプ信号の反転信号のアン
ドによつて、第2の変換完了信号B5が発生す
る。また端子B3に与えられた信号は、エツジ検
出回路B6を介して第1の変換完了信号を発生さ
せる。エツジ検出回路B6の出力は、ラインl1
を介してセーブレジスタB9に与えられる。フリ
ーランカウンタB8にはクロツク信号が与えら
れ、フリーランカウンタB8の出力はセーブレジ
スタB9に与えられる。
Embodiment FIG. 3 is a block diagram of an embodiment of the present invention. Signals V1 to Vi are applied to each terminal P1 to Pi of the analog/digital converter A1, respectively. Terminals Q1 to Q3 of analog/digital converter A1 are connected to terminals B2 to B4 of microcomputer B1, which is a processing circuit, respectively. A second conversion completion signal B5 is generated by ANDing the start signal applied to the terminal B2 and the inverted signal of the stop signal applied to the terminal B3. Further, the signal applied to terminal B3 generates a first conversion completion signal via edge detection circuit B6. The output of the edge detection circuit B6 is on the line l1
is applied to save register B9 via. A clock signal is applied to free run counter B8, and the output of free run counter B8 is applied to save register B9.

ここで第4図の波形図を参照して、第3図に示
すブロツク図の動作を説明する。アナログ/デジ
タルコンバータA1の回路構成は、第1図に示す
アナログ/デジタルコンバータAの回路構成と同
じである。第4図1〜第4図4に示す波形図は、
第2図1〜第2図4に示す波形図と同じである。
たとえば、前述したようにアナログ/デジタルコ
ンバータA1の端子Piに与えられた正常なアナロ
グ信号をデジタル信号に変換した場合は、第4図
において実線で示すような波形になる。マイクロ
コンピユータB1は、端子B2に与えられる第4
図2のスタート信号の立上がりでフリーランカウ
ンタB8からスタート時刻t1を読み込み、図示
せぬアキユムレータに記憶する。そして変換時間
経過後の時刻t2では、第4図3に示すストツプ
信号が立下がり、この立下がりエツジ検出回路B
6で検出され、その検出信号がラインl1を介し
て出力される。この検出信号により、フリーラン
カウンタB8の値がセーブレジスタB9に終了時
刻t2として記憶される。それと同時に第4図4
の実線に示す第1の変換完了信号B7が、エツジ
検出回路B6から出力され、セツトされる。また
ストツプ信号B3の立下がりに同期して、第4図
5の実線で示す第2の変換完了信号がセツトされ
る。
The operation of the block diagram shown in FIG. 3 will now be described with reference to the waveform diagram of FIG. 4. The circuit configuration of analog/digital converter A1 is the same as that of analog/digital converter A shown in FIG. The waveform diagrams shown in FIGS. 41 to 4 are as follows:
This is the same as the waveform diagrams shown in FIGS. 21 to 24.
For example, when a normal analog signal applied to the terminal Pi of the analog/digital converter A1 is converted into a digital signal as described above, the waveform becomes as shown by the solid line in FIG. 4. The microcomputer B1 receives the fourth signal applied to the terminal B2.
At the rise of the start signal in FIG. 2, the start time t1 is read from the free run counter B8 and stored in an accumulator (not shown). Then, at time t2 after the conversion time has elapsed, the stop signal shown in FIG. 4 falls, and this falling edge detection circuit B
6, and its detection signal is output via line l1. This detection signal causes the value of free run counter B8 to be stored in save register B9 as end time t2. At the same time, Figure 4
A first conversion completion signal B7 shown by a solid line is output from the edge detection circuit B6 and is set. Further, in synchronization with the fall of the stop signal B3, a second conversion completion signal shown by a solid line in FIG. 4 is set.

次に第4図1の破線で示すようにアースレベル
よりも低い電圧を変換する場合、第4図3の破線
で示すようにストツプ信号が変化しないため、エ
ツジ検出回路B6から検出信号が出力されない。
そのため、セーブレジスタB9に終了時刻が記憶
されず、また、第4図4の破線で示すように第1
の変換完了信号B7もセツトされない。しかし第
4図2のスタート信号の立上がりで第4図5の破
線で示すように第2の変換完了信号B5がセツト
される。
Next, when converting a voltage lower than the ground level as shown by the broken line in Figure 4 1, the stop signal does not change as shown by the broken line in Figure 4 3, so no detection signal is output from the edge detection circuit B6. .
Therefore, the end time is not stored in the save register B9, and as shown by the broken line in FIG.
The conversion completion signal B7 is also not set. However, at the rise of the start signal in FIG. 4, the second conversion completion signal B5 is set as shown by the broken line in FIG. 4.

マイクロコンピユータB1は、第2の変換完了
信号がセツトされたことを検出して、次の処理に
移行する。すなわち今回のアナログ/デジタル変
換が正常に終了したものか否かを判断するため
に、第1の変換完了信号B7の状態を調べ、第1
の変換完了信号B7がセツトされていれば、正常
に終了したものと判断して、前記スタート時刻と
セーブレジスタB9に記憶されている終了時刻と
の差を求め、デジタル値を算出する。また、第1
の変換完了信号B7がセツトされていなければ、
異常と判断して異常処理を行う。たとえば、今回
変換したアナログ電圧をゼロVとして処理する。
The microcomputer B1 detects that the second conversion completion signal is set and moves on to the next process. That is, in order to determine whether or not the current analog/digital conversion has ended normally, the state of the first conversion completion signal B7 is checked and the first
If the conversion completion signal B7 is set, it is determined that the conversion has ended normally, and the difference between the start time and the end time stored in the save register B9 is calculated to calculate a digital value. Also, the first
If the conversion completion signal B7 is not set, then
It is determined that there is an abnormality and the abnormality processing is performed. For example, the analog voltage converted this time is treated as zero V.

このように本実施例では、従来のように第1の
変換終了信号で次の処理に移行するのではなく、
アナログ/デジタル変換の終了が正常な場合でも
異常な場合でも、必ず発生する第2の変換終了信
号で次の処理に移行するように構成したので、負
電圧のアナログ/デジタル変換時にも変換完了
後、直ちに変換後の処理ルーチンにプログラム処
理を移行させることができる。
In this way, in this embodiment, instead of proceeding to the next process at the first conversion end signal as in the conventional case,
Regardless of whether the analog/digital conversion ends normally or abnormally, the system is configured to proceed to the next process with the second conversion end signal that is always generated, so even when negative voltage analog/digital conversion is completed, , the program processing can be immediately transferred to the converted processing routine.

第5図は、マイクロコンピユータB1の動作を
説明するためのフローチヤートである。アナロ
グ/デジタル変換処理ルーチンに入り、ステツプ
n1からステツプn2に移る。ステツプn2で
は、第2の変換完了信号がセツトされているか否
かが判断され、セツトされているときステツプn
3に移り、セツトされていないときステツプn7
に移りリターンする。ステツプn3では、アナロ
グ/デジタルコンバータA1の端子P1〜Piに与
えられる信号V1〜Viのアナログ/デジタル信
号変換準備、たとえば信号V1の変換が完了後次
の信号V2の変換を行なうチヤンネル選択および
電圧V2のチヤージを行なう。ステツプn4で
は、今回の変換時間をセーブする。ステツプn5
では、第1の変換完了信号がセツトされているか
否かが判断され、セツトされているときステツプ
n6に移り、セツトされていないときステツプn
8に移る。ステツプn6では、第4図で説明した
ようなアナログ/デジタル変換関係処理を実行す
る。ステツプn8では、前述したような負電圧変
換として0V相等処理を実行する。
FIG. 5 is a flowchart for explaining the operation of the microcomputer B1. An analog/digital conversion processing routine is entered, and the process moves from step n1 to step n2. In step n2, it is determined whether or not the second conversion completion signal is set, and if it is set, step n2 is executed.
3, and if it is not set, step n7
Move to and return. In step n3, preparations for analog/digital signal conversion of the signals V1 to Vi applied to the terminals P1 to Pi of the analog/digital converter A1 are made, for example, after the conversion of the signal V1 is completed, channel selection and voltage V2 are performed for converting the next signal V2. Perform a charge. In step n4, the current conversion time is saved. step n5
Then, it is determined whether or not the first conversion completion signal is set. If it is set, the process moves to step n6; if it is not set, the process moves to step n6.
Move on to 8. At step n6, analog/digital conversion related processing as explained in FIG. 4 is executed. In step n8, 0V equivalence processing is executed as negative voltage conversion as described above.

効 果 以上のように本発明によれば、アナログ/デジ
タルコンバータの精度を劣化させることなく、ま
た負電位のアナログ/デジタル変換時にも、変換
完了後、直ちに変換後の処理ルーチンにプログラ
ム処理を移行させることができる。
Effects As described above, according to the present invention, without deteriorating the accuracy of the analog/digital converter, even during negative potential analog/digital conversion, program processing can be immediately transferred to the post-conversion processing routine after conversion is completed. can be done.

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

第1図は先行技術のアナログ/デジタル変換方
式の電気的構成を示すブロツク図、第2図は第1
図のブロツク図の動作を説明するための波形図、
第3図は本発明の一実施例のブロツク図、第4図
は第3図のブロツク図の動作を説明するための波
形図、第5図は第3図のブロツク図の動作を説明
するためのフローチヤートである。 A1……アナログ/デジタルコンバータ、B1
……マイクコンピユータ。
Figure 1 is a block diagram showing the electrical configuration of the prior art analog/digital conversion system, and Figure 2 is a block diagram showing the electrical configuration of the prior art analog/digital conversion method.
A waveform diagram to explain the operation of the block diagram in Fig.
3 is a block diagram of an embodiment of the present invention, FIG. 4 is a waveform diagram for explaining the operation of the block diagram in FIG. 3, and FIG. 5 is a waveform diagram for explaining the operation of the block diagram in FIG. 3. This is a flowchart. A1...Analog/digital converter, B1
...Microphone computer.

Claims (1)

【特許請求の範囲】[Claims] 1 内燃機関制御用のマイクロプロセツサを用い
た制御器において、アナログ電圧をデジタル量に
変換するためにアナログ電圧に関係したパルスを
発生させ、かつ該パルスの変換終了時のエツヂ
で、第1の変換完了信号を発生させるアナログ/
デジタル変換方式において、変換のスタート信号
と、該パルス信号とから第2の変換完了信号を発
生させ、該第2の変換完了信号で変換後の処理ル
ーチンにプログラム処理を移行し、該処理ルーチ
ン中で変換が正常に終了したかどうかを該第1の
変換完了信号で判断することを特徴とするアナロ
グ/デジタル変換方式。
1. In a controller using a microprocessor for controlling an internal combustion engine, a pulse related to an analog voltage is generated in order to convert the analog voltage into a digital quantity, and the edge at the end of the conversion of the pulse is the first one. Analog/
In the digital conversion method, a second conversion completion signal is generated from a conversion start signal and the pulse signal, and the program processing is transferred to a post-conversion processing routine by the second conversion completion signal, and during the processing routine. An analog/digital conversion method characterized in that whether or not the conversion has been completed normally is determined based on the first conversion completion signal.
JP15084783A 1983-08-16 1983-08-16 Analog/digital conversion system Granted JPS6041122A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP15084783A JPS6041122A (en) 1983-08-16 1983-08-16 Analog/digital conversion system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP15084783A JPS6041122A (en) 1983-08-16 1983-08-16 Analog/digital conversion system

Publications (2)

Publication Number Publication Date
JPS6041122A JPS6041122A (en) 1985-03-04
JPH0115087B2 true JPH0115087B2 (en) 1989-03-15

Family

ID=15505674

Family Applications (1)

Application Number Title Priority Date Filing Date
JP15084783A Granted JPS6041122A (en) 1983-08-16 1983-08-16 Analog/digital conversion system

Country Status (1)

Country Link
JP (1) JPS6041122A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7578040B2 (en) 2002-01-25 2009-08-25 Bapco Closures Research Limited Container closures

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7578040B2 (en) 2002-01-25 2009-08-25 Bapco Closures Research Limited Container closures

Also Published As

Publication number Publication date
JPS6041122A (en) 1985-03-04

Similar Documents

Publication Publication Date Title
JPH0115087B2 (en)
EP0247650A2 (en) Motor speed control system
RU2820839C1 (en) Bidirectional frequency recovery time tolerance control device
JP3046327B2 (en) Control method of double integral type A / D converter
RU2817045C1 (en) Bidirectional frequency recovery time tolerance control device
RU2819573C1 (en) Bidirectional device for tolerance control of transient frequency deviation
SU1483410A1 (en) Device for monitoring inverter gain factor
JPS6152485B2 (en)
JPH10187287A (en) Delay connection switch
JPH0736301Y2 (en) Signal measuring device
JP2577656B2 (en) Rechargeable battery charging method
JPS63202235A (en) battery charger
JP2594287Y2 (en) Image sensor
JPH0542177B2 (en)
SU900193A1 (en) Phase method of forming adjusting actions for separate balancing of compensating bridge measuring circuits and device for realization thereof
JP2589857B2 (en) Microcomputer
SU1739486A1 (en) Single-shot multivibrator
JPH062343Y2 (en) Waveform shaping circuit for frequency measurement
CN112526205A (en) MCU-based DMA function control AD converter peak value sampling method
JPH05276039A (en) A/d converter device
JPS61179618A (en) Starting method for integration type ad converter
JPS61176860A (en) Voltage detecting circuit
JPH064170A (en) Control device
JPS632353B2 (en)
JPH0224575A (en) Pulse width measurement circuit