JP3400605B2 - Processing unit for control - Google Patents

Processing unit for control

Info

Publication number
JP3400605B2
JP3400605B2 JP11282495A JP11282495A JP3400605B2 JP 3400605 B2 JP3400605 B2 JP 3400605B2 JP 11282495 A JP11282495 A JP 11282495A JP 11282495 A JP11282495 A JP 11282495A JP 3400605 B2 JP3400605 B2 JP 3400605B2
Authority
JP
Japan
Prior art keywords
output
processing
signal
ocr
control
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 - Fee Related
Application number
JP11282495A
Other languages
Japanese (ja)
Other versions
JPH08305420A (en
Inventor
博 片山
光男 萱野
満 渡部
哲也 市橋
昭二 佐々木
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.)
Hitachi Ltd
Hitachi Automotive Systems Engineering Co Ltd
Original Assignee
Hitachi Ltd
Hitachi Car Engineering 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 Hitachi Ltd, Hitachi Car Engineering Co Ltd filed Critical Hitachi Ltd
Priority to JP11282495A priority Critical patent/JP3400605B2/en
Publication of JPH08305420A publication Critical patent/JPH08305420A/en
Application granted granted Critical
Publication of JP3400605B2 publication Critical patent/JP3400605B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、高速マイクロコンピュ
ータを有する制御用処理装置に係り、特に、多車種対
応,装着の容易性,低価格化を必要とする制御用処理装
置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a control processing device having a high-speed microcomputer, and more particularly to a control processing device which needs to be compatible with multiple types of vehicles, be easily mounted, and be inexpensive.

【0002】[0002]

【従来の技術】従来、自動車に用いられる制御用処理装
置において、例えば、エンジン制御の場合、エンジンの
気筒数、付属するセンサの構成などが異なると、制御装
置は、制御するそれぞれのエンジンに最適なI/O構成
(タイマやカウンタ,アナログ入出力端子数など)を持
つマイクロコンピュータを選別して用いていた。この種
の装置としては、例えば特公平3−40277号が公報に記載
されている。
2. Description of the Related Art Conventionally, in a control processing device used for an automobile, for example, in the case of engine control, if the number of cylinders of the engine and the configuration of attached sensors are different, the control device is optimized for each engine to be controlled. Microcomputers with various I / O configurations (timers, counters, number of analog input / output terminals, etc.) were selected and used. As a device of this kind, for example, Japanese Examined Patent Publication No. 3-40277 is described in the official gazette.

【0003】[0003]

【発明が解決しようとする課題】前記の如き従来の制御
用処理装置にあっては、エンジンの種類によってI/O
構成の異なるマイクロコンピュータが必要である。従っ
て、小量多品種の生産を行う場合制御装置の標準化が図
れず、コストが上昇する問題点があった。
In the conventional control processing apparatus as described above, depending on the type of engine, I / O
Microcomputers with different configurations are required. Therefore, there is a problem that standardization of the control device cannot be achieved in the case of producing a large amount of small quantities and the cost is increased.

【0004】本発明は、このような問題に鑑みてなされ
たもので、その目的は、内蔵するタイマ本数以上のタイ
マ出力処理を可能とし、且つ、出力端子を自在に設定で
きるようにすることにより、タイマ出力機能を広範に利
用できるようにするとともに、全体を安価な構成とする
ことができる、制御用処理装置を提供することにある。
The present invention has been made in view of the above problems, and an object thereof is to enable timer output processing of more than the number of built-in timers and to freely set output terminals. It is an object of the present invention to provide a control processing device capable of widely utilizing the timer output function and having an inexpensive configuration as a whole.

【0005】[0005]

【課題を解決するための手段】上記目的は、一定周波数
のパルスをカウントするカウンタ部と、前記カウンタ部
と比較する比較データを記憶する比較データ部と、前記
カウンタ部と比較データを比較する比較部と、出力端子
と出力値を指定できる出力部と、それらを制御する制御
部を持つ制御用処理装置において、 前記制御部は、前記
比較部の一致条件が成立したとき、前記出力部の出力端
子と出力値を設定するとともに、前記比較データと現在
時刻の差が予め定める所定時間より小さいときに、前記
予め定める所定時間を前記現在時刻に加算することによ
り新たな比較データとし前記出力値の動作時刻を設定す
ることを特徴とする制御用処理装置によって達成され
る。
SUMMARY OF THE INVENTION The above object is, constant frequency
Section for counting the number of pulses, and the counter section
A comparison data section for storing comparison data to be compared with
Output section and a comparison section that compares the comparison data with the counter section
And the output part that can specify the output value and the control that controls them
In the control processing device having a unit, the control unit is
When the matching condition of the comparison unit is satisfied, the output end of the output unit
The child and the output value are set, and the comparison data and the current
When the time difference is smaller than a predetermined time, the above
By adding a predetermined time to the current time
Set the operation time of the output value as new comparison data
It is achieved by a control processing device characterized in that

【0006】そして、本発明のより好ましい具体例とし
ては、前記制御用処理装置の、前記出力部の出力信号
が、燃料噴射信号または、点火信号または、PWM信号
であるものが挙げられる。
As a more preferable specific example of the present invention, the output signal of the output unit of the control processing device is a fuel injection signal, an ignition signal, or a PWM signal.

【0007】[0007]

【作用】前述の如く構成された本発明に係わる制御用処
理装置においては、仮想的なタイマ出力を実現するプロ
グラムにより、タイマ出力本数と出力する端子をフレキ
シブルに可変する事ができる。従って4気筒から12気
筒あるいはそれ以上の気筒まで1種類の制御用処理装置
で制御することが可能となる。
In the control processing apparatus according to the present invention having the above-described configuration, the number of timer outputs and the output terminals can be flexibly changed by the program for realizing the virtual timer output. Therefore, it is possible to control from 4 cylinders to 12 cylinders or more cylinders by one type of control processing device.

【0008】[0008]

【実施例】以下、図面により本発明の実施例を説明す
る。なお、以下の各実施例を説明するための図におい
て、同一機能を有する対応部材には同一符号を付し、重
複する説明は省略する。
Embodiments of the present invention will be described below with reference to the drawings. In the drawings for explaining each of the following embodiments, corresponding members having the same function are designated by the same reference numerals, and overlapping description will be omitted.

【0009】まず、図1〜図4により、本発明の一実施
例によるアクチュエータ制御システムについて説明す
る。
First, an actuator control system according to an embodiment of the present invention will be described with reference to FIGS.

【0010】図1は本発明によるアクチュエータ制御シ
ステムのハードウェア構成図の一例である。アクチュエ
ータ110は2本のPWM(Pulse Width Modulation)
信号PWM_aとPWM_bにより制御される。制御用
処理装置1は、一定周期でカウントアップするカウンタ
部16と、カウント値と比較するデータを記憶する比較
データ部14と、カウント値と比較データを比較する比
較部15と、出力端子1〜出力端子8までの出力端子と
出力値を設定できる出力部8と、前記出力部8の出力値
と出力端子データを記憶する出力バッファ10と、これ
らを制御する制御部2を持つ。
FIG. 1 is an example of a hardware configuration diagram of an actuator control system according to the present invention. The actuator 110 has two PWM (Pulse Width Modulation)
It is controlled by the signals PWM_a and PWM_b. The control processing device 1 includes a counter unit 16 that counts up in a constant cycle, a comparison data unit 14 that stores data to be compared with a count value, a comparison unit 15 that compares the count value and comparison data, and output terminals 1 to 1. The output unit 8 includes an output terminal up to the output terminal 8 and an output value that can be set, an output buffer 10 that stores the output value of the output unit 8 and output terminal data, and a control unit 2 that controls these.

【0011】次に、制御部2で行う処理ソフトウェアの
概要を説明する。制御部2は、カウント値が比較データ
と一致したときに、割り込み応答や一致フラグの検索に
よる応答などの応答手段を有する。このことにより制御
部2は、カウント値と比較データの一致を検出する事が
できる。このとき制御部2は、出力バッファ10に従い
出力処理を行い、この次に何時どの端子を立上げるべき
かまたは立下げるべきか判別する処理を行う。次にこの
結果に従い、比較データ部14に出力したい時刻、出力
バッファ10に、出力値と出力端子の設定を行う。
Next, the outline of the processing software executed by the control unit 2 will be described. The control unit 2 has a response unit such as an interrupt response or a response by searching a match flag when the count value matches the comparison data. As a result, the control unit 2 can detect the match between the count value and the comparison data. At this time, the control unit 2 performs an output process in accordance with the output buffer 10, and then performs a process of determining which terminal should be activated or deactivated at what time. Next, according to this result, the output value and the output terminal are set in the output buffer 10 at the time to be output to the comparison data unit 14.

【0012】図2は、タイムチャートである。PWM_
a信号の周期はTp_a,デューティはTd_aで、P
WM_b信号の周期はTp_b,デューティはTd_b
であるとする。カウンタ部16へは一定周期のパルスを
入力しカウント値は一定の傾きで上昇する。ここで、比
較データ部14へ書き込むデータを図に示すように変化
させることにより2本のPWM信号の立ち上がりと立ち
下がりのタイミングが得られ、このタイミングで出力部
8へ適切な出力値と出力端子の設定を行えば2本のPW
M信号を出力することができる。
FIG. 2 is a time chart. PWM_
The period of the a signal is Tp_a, the duty is Td_a, and P
The cycle of the WM_b signal is Tp_b and the duty is Td_b.
Suppose A pulse having a constant cycle is input to the counter unit 16 and the count value increases at a constant slope. Here, by changing the data to be written to the comparison data section 14 as shown in the figure, the rising and falling timings of the two PWM signals can be obtained. At this timing, an appropriate output value and output terminal to the output section 8 can be obtained. If you set up two PW
An M signal can be output.

【0013】従って、制御部2は、カウント値と比較デ
ータが一致したタイミングで、まず、出力バッファ10
にもとずき出力部8へ出力値と出力端子の指令を出し、
次に起こるのはPWM_aの立上げ,PWM_aの立下
げ,PWM_bの立上げ,PWM_bの立下げのいずれ
であるか判別し以下の処理を行う。例えば、処理aで
は、出力バッファ10に従い出力端子2を立上げる。次
にPWM_bパルスを立上げる時刻と立下げる時刻を計
算する。その後、次に行うべきパルス処理を検索し、こ
こではPWM_aを立上げる処理であるため、この立上
げ時刻を比較データ部14に、出力端子1が立ち上がる
ような出力設定を出力バッファ10に記憶する。また、
処理bでは、出力バッファ10に従い出力端子1を立上
げる。次にPWM_aパルスを立上げる時刻と立下げる
時刻を計算する。その後、次に行うべきパルス処理を検
索し、ここではPWM_bを立下げる処理であるため、
この立下げ時刻を比較データ部14に、出力端子2が立
ち下がるような出力設定を出力バッファ10に記憶す
る。処理cでは、出力バッファ10に従い出力端子2を
立下げる。その後、次に行うべきパルス処理を検索し、
ここではPWM_aを立下げる処理であるため、この立
下げ時刻を比較データ部14に、出力端子1が立ち下が
るような出力設定を出力バッファ10に記憶する。処理
dでは、出力バッファ10に従い出力端子1を立下げ
る。その後、次に行うべきパルス処理を検索し、ここで
はPWM_bを立上げる処理であるため、この立上げ時
刻を比較データ部14に、出力端子2が立ち上がるよう
な出力設定を出力バッファ10に記憶する。
Therefore, the control unit 2 first outputs the output buffer 10 at the timing when the count value and the comparison data match.
The output value and the command of the output terminal are given to the output unit 8
Next, it is determined whether PWM_a is rising, PWM_a is falling, PWM_b is rising, or PWM_b is falling, and the following processing is performed. For example, in the process a, the output terminal 2 is activated according to the output buffer 10. Next, the time when the PWM_b pulse rises and the time when it falls are calculated. After that, a pulse process to be performed next is searched for, and since this is the process of raising PWM_a, the rise time is stored in the comparison data unit 14, and the output setting for raising the output terminal 1 is stored in the output buffer 10. . Also,
In process b, the output terminal 1 is activated according to the output buffer 10. Next, the time at which the PWM_a pulse rises and the time at which it falls are calculated. After that, the pulse processing to be performed next is searched, and here, since it is the processing for lowering PWM_b,
The fall time is stored in the comparison data section 14, and the output setting that causes the output terminal 2 to fall is stored in the output buffer 10. In process c, the output terminal 2 is pulled down according to the output buffer 10. After that, search for the next pulse processing to be performed,
Since the processing here is the fall of PWM_a, the fall time is stored in the comparison data section 14, and the output setting that causes the output terminal 1 to fall is stored in the output buffer 10. In process d, the output terminal 1 is turned off according to the output buffer 10. After that, a pulse process to be performed next is searched for, and since this is the process of raising PWM_b, the rise time is stored in the comparison data section 14, and the output setting for raising the output terminal 2 is stored in the output buffer 10. .

【0014】しかし、各PWM信号の変化タイミングが
時間的に近くなると処理が間に合わなくなることが考え
られる。この場合は、例えば図3で示すように立上げタ
イミングにTerrが発生した場合は次の立下げ時刻に
Terrを加算、立下げタイミングにTerrが発生し
た場合は次の立上げ時刻にTerrを加算することによ
り平均的なデューティは一定になるように補正すること
が可能である。
However, it is conceivable that the processing may be delayed if the change timings of the respective PWM signals become close in time. In this case, for example, as shown in FIG. 3, when Terr occurs at the rising timing, Terr is added at the next fall time, and when Terr occurs at the falling timing, Terr is added at the next rise time. By doing so, the average duty can be corrected to be constant.

【0015】即ち、この場合はPWMパルス信号の周期
はランダムに変化するが、n個のPWMパルスの平均値
は指令と等しくなる。
That is, in this case, the cycle of the PWM pulse signal changes randomly, but the average value of the n PWM pulses becomes equal to the command.

【0016】図4は、フローチャートである。処理50
0では、後述する処理506で作られる出力バッファの
データを出力部8へ転送する。ここで出力部8は一般的
なマイクロコンピュータの出力ポート手段を想定してお
り、転送されたデータはそのまま端子に出力できる。こ
のため、次に処理501で今回の処理がPWM_aの立
上げまたは立下げで起きたものか判断する。もし、PW
M_aの立上げまたは立下げで起きたものであれば処理
502により次にPWM_aがオンする時刻(Ton_a
)とオフする時刻(Toff_a)を計算する。同様に処理
504で今回の処理がPWM_bの立上げまたは立下げ
で起きたものか判断する。もし、PWM_bの立上げま
たは立下げで起きたものであれば処理505により次に
PWM_bがオンする時刻(Ton_b )とオフする時刻
(Toff_b)を計算する。次に処理506では、算出し
たTon_a,Toff_a,Ton_b,Toff_bのうちで最も
現在の時刻に近いものを検索し、比較データ部14に格
納する。このとき、Ton_aが選ばれた場合は出力バッ
ファのビットの中でPWM_a端子(出力端子1)に対
応するビットをセットし、Toff_aが選ばれた場合は出
力バッファのビットの中でPWM_a端子(出力端子
1)に対応するビットをクリアする。同様に、Ton_b
が選ばれた場合は出力バッファのビットの中でPWM_
b端子(出力端子2)に対応するビットをセットし、To
ff_bが選ばれた場合は出力バッファのビットの中でP
WM_b端子(出力端子2)に対応するビットをクリア
する。ただし、オンオフに関係しないビットは、前の状
態を保持しなければならない。次に、処理507では、
比較データと現在時刻の差がTminより小さいかどうか判
断する。小さい場合は比較データの設定処理が間に合わ
ないと判断し次の処理を行う。まず、処理508で、比
較データ部に記憶した時間の処理が立上げであるか立下
げであるか判別する。もし、立上げであれば、処理51
0により立上げ時刻(Ton_x)を処理可能な時間(現在
時刻+Tmin )まで遅らせ、これによる遅れ時間(Terr)
を立下げ時刻(Toff_x)に加算し再度処理506に戻
り検索をやり直す。また、立下げであれば、処理509
により立下げ時刻(Toff_x)を処理可能な時間(現在
時刻+Tmin )まで遅らせ、これによる遅れ時間(Terr)
を立上げ時刻(Ton_x)に加算し再度処理506に戻
り検索をやり直す。
FIG. 4 is a flowchart. Processing 50
At 0, the data in the output buffer created in the processing 506 described later is transferred to the output unit 8. Here, the output unit 8 is assumed to be an output port unit of a general microcomputer, and the transferred data can be output to the terminal as it is. Therefore, next, in process 501, it is determined whether or not the current process is caused by the rise or fall of PWM_a. If PW
If it is caused by the rise or fall of M_a, the time (Ton_a) at which PWM_a is turned on next by process 502.
) And the time to turn off (Toff_a). Similarly, in process 504, it is determined whether or not the process this time is caused by the rise or fall of PWM_b. If it occurs due to the rise or fall of PWM_b, the next time PWM_b turns on (Ton_b) and the time it turns off (Toff_b) are calculated by processing 505. Next, in process 506, the calculated Ton_a, Toff_a, Ton_b, Toff_b that is closest to the current time is searched and stored in the comparison data unit 14. At this time, when Ton_a is selected, the bit corresponding to the PWM_a terminal (output terminal 1) is set in the output buffer bits, and when Toff_a is selected, the PWM_a terminal (output Clear the bit corresponding to pin 1). Similarly, Ton_b
If is selected, the PWM_
Set the bit corresponding to the b terminal (output terminal 2), and
If ff_b is selected, P among the bits of the output buffer
The bit corresponding to the WM_b terminal (output terminal 2) is cleared. However, bits that are not related to ON / OFF must retain the previous state. Next, in process 507,
Judge whether the difference between the comparison data and the current time is smaller than Tmin. If it is smaller, it is determined that the comparison data setting process is not in time, and the next process is performed. First, in process 508, it is determined whether the process of the time stored in the comparison data portion is a start-up or a fall. If it is startup, process 51
The start time (Ton_x) is delayed by 0 to the processable time (current time + Tmin), and the delay time (Terr) due to this
Is added to the fall time (Toff_x), the process returns to step 506 and the search is performed again. If it is a fall, processing 509
Delays the fall time (Toff_x) until it can be processed (current time + Tmin), and the delay time (Terr)
Is added to the startup time (Ton_x), the process returns to the processing 506 and the search is performed again.

【0017】ただし、前記実施例では、出力部8を一般
的なマイクロコンピュータの出力ポート手段を想定して
説明したが、より最適な出力部8の回路として、図5が
あげられる。ラッチ回路38は、アドレス信号をデコー
ダ34でデコードして得たチップセレクト(CS)信号
とデータが有効であることを示すデータストローブ(D
S)信号をアンドゲート36で処理した信号のタイミン
グでデータバスのデータを取り込む。同様に、ラッチ回
路39は、アドレス信号をデコーダ35でデコードして
得たチップセレクト(CS)信号とデータが有効である
ことを示すデータストローブ(DS)信号をアンドゲー
ト37で処理した信号のタイミングでデータバスのデー
タを取り込む。また、JKフリップフロップ40〜47
は前記比較部15が一致を検出したタイミングで動作す
る。図6は前記JKフリップフロップ40〜47の真理
値表である。出力Qを1にしたければ、入力J(ラッチ
回路38のデータ)を1、入力K(ラッチ回路39のデ
ータ)を0にして比較部15の一致を待つ。また、出力
Qを0にしたければ、入力J(ラッチ回路38のデー
タ)を0、入力K(ラッチ回路39のデータ)を1にし
て比較部15の一致を待つ。また、出力Qを変化させた
くなければ入力J(ラッチ回路38のデータ)入力K
(ラッチ回路39のデータ)共に0にすれば良い。従っ
て、前記処理506で行っていたオンオフに関係しない
ビットを前の状態のまま保持する処理は、入力J(ラッ
チ回路38のデータ)入力K(ラッチ回路39のデー
タ)共に0にするという簡単な処理で実現できるため制
御部2の処理負担を軽減することができる。
However, in the above embodiment, the output section 8 has been described assuming output port means of a general microcomputer, but as a circuit of the more optimal output section 8, FIG. 5 can be cited. The latch circuit 38 receives a chip select (CS) signal obtained by decoding the address signal by the decoder 34 and a data strobe (D) indicating that the data is valid.
S) The data of the data bus is taken in at the timing of the signal processed by the AND gate 36. Similarly, in the latch circuit 39, the timing of the chip select (CS) signal obtained by decoding the address signal by the decoder 35 and the signal obtained by processing the data strobe (DS) signal indicating that the data is valid by the AND gate 37 Take in the data of the data bus with. Also, JK flip-flops 40 to 47
Operates at the timing when the comparison unit 15 detects a match. FIG. 6 is a truth table of the JK flip-flops 40 to 47. If the output Q is desired to be 1, the input J (data of the latch circuit 38) is set to 1 and the input K (data of the latch circuit 39) is set to 0, and the comparison unit 15 waits for a match. If the output Q is desired to be 0, the input J (data of the latch circuit 38) is set to 0 and the input K (data of the latch circuit 39) is set to 1, and the comparison unit 15 waits for a match. If it is not desired to change the output Q, the input J (data of the latch circuit 38) input K
(Data of the latch circuit 39) may be set to 0. Therefore, the process of holding the bit not related to ON / OFF in the previous state performed in the process 506 is as simple as setting both the input J (data of the latch circuit 38) and the input K (data of the latch circuit 39) to 0. Since it can be realized by processing, the processing load on the control unit 2 can be reduced.

【0018】図7は、ラッチ回路38,39の具体的な
回路の例である。Dタイプフリップフロップ48〜55
からなり、クロック(CK)信号の立ち上がりタイミン
グ時点での入力Dが出力Qに現れる。Dフリップフロッ
プ48は出力端子1のオンオフを決定するものであり、
Dフリップフロップ49は出力端子2のオンオフを決定
するものである。同様に、Dフリップフロップ55の出
力端子8まで対応している。従って、出力端子の指定は
どのDフリップフロップにデータ記憶させるかで決定で
きる。
FIG. 7 shows an example of a concrete circuit of the latch circuits 38 and 39. D type flip-flop 48-55
The input D appears at the output Q at the rising timing of the clock (CK) signal. The D flip-flop 48 is for determining ON / OFF of the output terminal 1.
The D flip-flop 49 determines ON / OFF of the output terminal 2. Similarly, the output terminal 8 of the D flip-flop 55 is also supported. Therefore, the designation of the output terminal can be determined by which D flip-flop is to store the data.

【0019】本実施例によれば、図4に示す仮想PWM
処理の変数であるTon_x 及びToff_xとこれに関する
処理を必要な分だけ増やすことにより、同一のハードウ
ェアでPWM出力を必要な本数だけ必要な端子に出力す
ることが可能となり、多品種小量生産である場合でもハ
ードウェアを共通化できるため生産コストを低減するこ
とができる。また、PWMパルスに限らず、ステップモ
ータの駆動パルスや自動車用エンジンの燃料噴射信号,
点火信号などもキャリア周波数が同じPWM信号の集合
と考えることができ、同様に実現できる。特に、これら
は立上げ同士または立下げ同士のグループに分ければ、
それぞれのグループの処理は以下に説明する他の実施例
のように処理時間によるパルス出力の遅れを回避するこ
とができる。
According to this embodiment, the virtual PWM shown in FIG.
By increasing the processing variables Ton_x and Toff_x and the processing related thereto by the required amount, it is possible to output the PWM output to the required number of terminals with the same hardware, and in high-mix low-volume production. Even in some cases, the hardware can be shared, so that the production cost can be reduced. Not only the PWM pulse, but also the drive pulse of the step motor, the fuel injection signal of the automobile engine,
The ignition signal and the like can be considered as a set of PWM signals having the same carrier frequency, and can be similarly realized. Especially, if these are divided into groups of startups or shutdowns,
The processing of each group can avoid the delay of the pulse output due to the processing time as in the other embodiments described below.

【0020】次に、より具体的な他の実施例として、1
チップマイクロコンピュータを用いて自動車のエンジン
と自動変速機を制御する制御システムを図8〜図17を
用いて説明する。
Next, as another more specific embodiment, 1
A control system for controlling an automobile engine and an automatic transmission using a chip microcomputer will be described with reference to FIGS.

【0021】図8は本発明によるエンジン,自動変速機
制御システムのハードウェア構成図である。まず、エン
ジンの制御方法について説明する。本図示例の自動車用
エンジン制御システムに適用されるエンジンとして、4
気筒4サイクルエンジン101を例にして以下説明する。
センサとして、スロットル開度を検出するTVOセンサ
104と、吸入空気量を検出するAFMセンサ105
と、排気ガス中に含まれる酸素量を検出するO2 センサ
108と、エンジン101のクランク角180度毎のパ
ルスを発生するREFセンサ103と、クランク角2度
毎のパルスを発生するPOSセンサ102が設けられて
いる。なお、REFセンサ103のパルス信号は、その
パルス幅が気筒毎に異なるものであり、このパルス幅情
報を用いて気筒判別を行うことができる。
FIG. 8 is a hardware block diagram of the engine and automatic transmission control system according to the present invention. First, a method of controlling the engine will be described. As an engine applied to the automobile engine control system of this illustrated example, 4
The cylinder 4-cycle engine 101 will be described below as an example.
As sensors, a TVO sensor 104 for detecting the throttle opening and an AFM sensor 105 for detecting the intake air amount.
An O 2 sensor 108 for detecting the amount of oxygen contained in the exhaust gas, a REF sensor 103 for generating a pulse for every 180 ° crank angle of the engine 101, and a POS sensor 102 for generating a pulse for every 2 ° crank angle. Is provided. The pulse width of the pulse signal of the REF sensor 103 differs for each cylinder, and the cylinder discrimination can be performed using this pulse width information.

【0022】また、エンジン101を制御するための機
構として、燃料を噴射するインジェクタINJ106と、空気
と燃料の混合気を点火するイグニッションIGN107があ
る。なお、インジェクタINJとイグニッションIGN
は、この他各気筒におのおの1つずつ設けられるが同一
の動作を行うためここでは省略する。触媒109は排気
ガスを浄化するものである。このエンジン101を制御
する1チップマイクロコンピュータ1は、制御演算処理
を行うCPU2と、割り込みコントローラ3と、アナロ
グ信号をディジタル信号に変換するA/D変換手段4
と、制御プログラム及び仮想的にタイマ出力を拡張させ
る仮想OCRプログラムを記憶するROM9と、一時的
にデータを記憶するRAM10と、一定周期割り込みを
発生させるタイマ6と、パルス信号を入出力するフリー
ランニングタイマ7と、ディジタル信号を入出力するポ
ート手段5,8からなる。
Further, as a mechanism for controlling the engine 101, there are an injector INJ 106 for injecting fuel and an ignition IGN 107 for igniting a mixture of air and fuel. Injector INJ and ignition IGN
Are provided for each of the other cylinders, but the same operation is performed, and therefore the description thereof is omitted here. The catalyst 109 purifies exhaust gas. A one-chip microcomputer 1 that controls the engine 101 includes a CPU 2 that performs control calculation processing, an interrupt controller 3, and an A / D conversion unit 4 that converts an analog signal into a digital signal.
A ROM 9 for storing a control program and a virtual OCR program for virtually expanding the timer output, a RAM 10 for temporarily storing data, a timer 6 for generating a constant cycle interrupt, and a free running for inputting / outputting a pulse signal. It comprises a timer 7 and port means 5 and 8 for inputting and outputting digital signals.

【0023】次に自動変速機110に関係するハードウ
ェアについて説明する。自動変速機110は速度比を4
種類に切り替える事ができ、トルクコンバータを締結す
るロックアップ機能を有する。車速センサ111より車
速に比例した周波数のパルス信号を得る。このパルス信
号の立ち上がりエッジでフリーランカウンタFRC_a
16の値をインプットキャプチャレジスタICR_b2
0に取り込み、この情報をもとにCPU2で車速に変換
する。また、変速信号はデジタルポート出力手段8から
出力し、ソレノイドバルブ112を用いて変速用の油圧
を制御する。また、ロックアップの制御はPWM信号
(L/Uduty )で行う。また、変速機全体を制御する油
圧の圧力を制御するためにもPWM信号(PLduty)を用
いる。
Next, the hardware related to the automatic transmission 110 will be described. The automatic transmission 110 has a speed ratio of 4
It has a lock-up function that can be switched to different types and that fastens the torque converter. From the vehicle speed sensor 111, a pulse signal having a frequency proportional to the vehicle speed is obtained. At the rising edge of this pulse signal, the free-run counter FRC_a
The value of 16 is input capture register ICR_b2
It is taken into 0 and the CPU 2 converts it into the vehicle speed based on this information. In addition, the shift signal is output from the digital port output means 8 to control the hydraulic pressure for shifting using the solenoid valve 112. The lockup control is performed by the PWM signal (L / Uduty). The PWM signal (PLduty) is also used to control the hydraulic pressure that controls the entire transmission.

【0024】図9に、前記フリーランニングカウンタ7
の詳細なブロック図を示す。FRC_a16は内部クロ
ックCLKにより例えば3.2μs 程度の一定周期でカ
ウントアップされる。比較器_a15,比較器_b1
7,比較器_c21,比較器_d23,比較器_e25
は、それぞれアウトプットコンペアレジスタOCR_a
14,OCR_b18,OCR_c22,OCR_d2
4,OCR_e26のデータとFRC_a16のデータ
が等しくなると割り込み信号INT1,INT2,INT5,INT
6,INT7を発生する。インプットキャプチャーレジ
スタICR_a19は、REFセンサ103によるパル
ス信号の立ち上がりエッジでFRC_a16の値を取り
込み割り込み信号INT3を発生する。インプットキャ
プチャーレジスタICR_b20は、車速センサ111
によるパルス信号の立ち上がりエッジでFRC_a16
の値を取り込み割り込み信号INT4を発生する。カウ
ンタCNT_a29は、POSセンサ102によるパル
ス信号の立ち上がりエッジでカウントアップする。比較
器_f28,比較器_g30,比較器_h32は、それ
ぞれアウトプットコンペアレジスタOCR_f27,O
CR_g31,OCR_h33のデータとCNT_a2
9のデータが等しくなると割り込み信号INT8,IN
T9,INT10を発生する。
FIG. 9 shows the free running counter 7
2 shows a detailed block diagram of FIG. The FRC_a16 is counted up by the internal clock CLK at a constant cycle of, for example, about 3.2 μs. Comparator_a15, Comparator_b1
7, comparator_c21, comparator_d23, comparator_e25
Are output compare registers OCR_a, respectively.
14, OCR_b18, OCR_c22, OCR_d2
4, when the data of OCR_e26 and the data of FRC_a16 become equal, the interrupt signals INT1, INT2, INT5, INT
6 and INT7 are generated. The input capture register ICR_a19 captures the value of FRC_a16 at the rising edge of the pulse signal from the REF sensor 103 and generates an interrupt signal INT3. The input capture register ICR_b20 is a vehicle speed sensor 111.
At the rising edge of the pulse signal by FRC_a16
Value is taken in and an interrupt signal INT4 is generated. The counter CNT_a 29 counts up at the rising edge of the pulse signal from the POS sensor 102. The comparator_f28, the comparator_g30, and the comparator_h32 are output compare registers OCR_f27 and OCR, respectively.
Data of CR_g31 and OCR_h33 and CNT_a2
When the data of 9 become equal, the interrupt signals INT8, IN
T9 and INT10 are generated.

【0025】また、それぞれの割り込み要求では次の処
理を行う。まず、INT1ではインジェクタ(INJ)
パルスの立上げ処理,INT2ではインジェクタ(IN
J)パルスの立下げ処理,INT3ではエンジン回転数
Neの計測処理,INT4では車速の計測処理,INT
5ではオフセット1処理,INT6ではPWMパルスの
立上げ処理,INT7ではPWMパルスの立下げ処理,
INT8ではイグニッション(IGN)パルスの立上げ
処理,INT9ではイグニッション(IGN)パルスの
立下げ処理,INT10ではオフセット2処理を行う。
なお、パルス信号の立上げ処理,立下げ処理用のアウト
プットコンペアレジスタ(OCR)の構成は出力パルス
数にかかわらず一定であるため、エンジンの気筒数が8
あるいは12と増加した場合でも同一ハードウェアで実
現することができる。
The following processing is performed for each interrupt request. First, in INT1, the injector (INJ)
Pulse rise processing, injector (IN
J) Pulse fall processing, engine speed Ne measurement processing at INT3, vehicle speed measurement processing at INT4, INT
5, offset 1 processing, INT6 PWM pulse rising processing, INT7 PWM pulse falling processing,
The INT8 performs an ignition (IGN) pulse rising process, the INT9 performs an ignition (IGN) pulse falling process, and the INT10 performs an offset 2 process.
Since the configuration of the output compare register (OCR) for the rise and fall processes of the pulse signal is constant regardless of the number of output pulses, the number of cylinders of the engine is 8
Alternatively, even if the number is increased to 12, it can be realized by the same hardware.

【0026】以上でハードウェアの説明を終わり、次に
エンジン及び自動変速機の制御方法について説明する。
With the above description of the hardware, the control method of the engine and the automatic transmission will be described.

【0027】図10に、エンジン及び自動変速機の制御
ブロック図を示す。まず、自動変速機の制御ブロック2
16について説明する。ブロック200は車速センサ9
のパルス信号を周期計測あるいは一定時間内のパルス数
をカウントすることにより車速情報を検出し車速VSP
に換算する。スロットル開度信号はブロック201によ
り角度信号に換算する。この情報からブロック202で
ギア位置を決定する。これは図11に示した変速スケジ
ュールに従って行う。即ち、一定の周期(例えば40m
s)で現在の車速VSPとスロットル開度TVOをこの
変速スケジュールにあてはめ、該当する領域が示すギア
位置に変速させるものである。ただし、シフトアップと
シフトダウンはそれぞれ別のスケジュール線としヒステ
リシスを持たせ頻繁な変速を防止する。また、変速時に
エンジン出力を絞ると変速ショックを軽減させることが
できる。このため、ブロック204では変速時はギア位
置指令が変化することからこれを検出しエンジン制御へ
出力トルクダウン指令を出力する。ブロック203は得
られたギア位置を出力するためにディジタル出力ポート
手段8に値を設定する。これは図12に示したギア位置
と変速信号出力SOLA,SOLBの関係をもとに出力す
る。図示していないが自動変速機110は、この変速信
号により各ギア位置に変速する構造になっている。ま
た、ブロック212ではトルクコンバータをロックアップ
する条件を判断する。これは図14で示したマップよ
り、車速VSPとスロットル開度TVOよりロックアッ
プの度合い(L/U_duty)を検索する。ブロック21
3では、検索された前記LU_dutyをPWM信号にする
処理を行う。また、ブロック214では、自動変速機を
制御する油圧の圧力(ライン圧)を演算する。これは図
13で示したマップを用いて、スロットル開度TVOよ
りライン圧(PL_duty)を検索する。ブロック215で
は、検索された前記PL_dutyをPWM信号にする処理
を行う。
FIG. 10 shows a control block diagram of the engine and the automatic transmission. First, the control block 2 of the automatic transmission
16 will be described. Block 200 is a vehicle speed sensor 9
The vehicle speed information is detected by measuring the pulse signal of the vehicle in a cycle or counting the number of pulses within a certain time.
Convert to. The throttle opening signal is converted into an angle signal by the block 201. From this information, block 202 determines the gear position. This is performed according to the shift schedule shown in FIG. That is, a fixed cycle (for example, 40 m
In s), the current vehicle speed VSP and the throttle opening TVO are applied to this shift schedule, and the gear position is shifted to the gear position indicated by the corresponding region. However, upshift and downshift have separate schedule lines to have hysteresis to prevent frequent shifts. Further, by reducing the engine output during gear shifting, gear shifting shock can be reduced. Therefore, in block 204, the gear position command changes during shifting, and this is detected, and an output torque down command is output to the engine control. Block 203 sets a value in the digital output port means 8 to output the obtained gear position. This is output based on the relationship between the gear position and the shift signal outputs SOLA and SOLB shown in FIG. Although not shown, the automatic transmission 110 has a structure that shifts to each gear position by this shift signal. Further, in block 212, the condition for locking up the torque converter is determined. This searches the map shown in FIG. 14 for the lockup degree (L / U_duty) from the vehicle speed VSP and the throttle opening TVO. Block 21
In 3, the processing for converting the retrieved LU_duty into a PWM signal is performed. Further, in block 214, the hydraulic pressure (line pressure) for controlling the automatic transmission is calculated. This searches the line pressure (PL_duty) from the throttle opening TVO using the map shown in FIG. In block 215, a process of converting the retrieved PL_duty into a PWM signal is performed.

【0028】上記の自動変速機制御のフローチャートを
図15〜図22に示す。自動変速機の場合、自動車全体
の慣性は非常に大きいため制御の応答速度も特に高速で
ある必要が無い。このため全体の処理を比較的ゆっくり
したタイミング(40ms)で起動している。このた
め、CPUに対する演算負荷は比較的小さい。
Flowcharts of the above automatic transmission control are shown in FIGS. In the case of an automatic transmission, since the inertia of the entire vehicle is very large, the control response speed does not need to be particularly high. Therefore, the whole process is started at a relatively slow timing (40 ms). Therefore, the calculation load on the CPU is relatively small.

【0029】まず図15は、1チップマイクロコンピュ
ータ1がリセットされたときに動作するバックグラウン
ド処理プログラムのフローチャートである。まず、割り
込みを禁止するマスク処理300を行い、RAM10や
周辺機能レジスタの初期設定などのイニシャライズ処理
301を行う。この後、割り込みの禁止を解除する割り
込みマスク解除処理302を行う。
First, FIG. 15 is a flowchart of a background processing program which operates when the one-chip microcomputer 1 is reset. First, mask processing 300 for prohibiting interrupts is performed, and initialization processing 301 such as initial setting of the RAM 10 and peripheral function registers is performed. After that, the interrupt mask canceling process 302 for canceling the prohibition of the interrupt is performed.

【0030】次に、各種タイミングで起動要求割り込み
を発生するタスクについて詳細に説明する。
Next, a task for generating a start request interrupt at various timings will be described in detail.

【0031】まず図16に車速検出のフローチャートを
示す。本処理は、車速パルス信号VSPの立ち上がりエ
ッジで起動する。まず処理303でインプットキャプチ
ャーレジスタICR_b20の値をICRNEWに取り込む。
次に処理304でICRNEWからICROLD(1周期前のICRNE
W)を差し引き車速パルス信号の立ち上がりエッジ間の
周期PERIODを算出する。処理305は、次の周期の算出
のためにICROLDに現在のICRNEWを記憶させるものであ
る。処理306では、車速換算計数Lを車速パルスの周
期PERIODで除算し車速VSPを得る。
First, FIG. 16 shows a flowchart of vehicle speed detection. This process starts at the rising edge of the vehicle speed pulse signal VSP. First, in process 303, the value of the input capture register ICR_b20 is loaded into ICRNEW.
Next, in process 304, ICRNEW to ICROLD (ICRNE one cycle before
W) is subtracted to calculate the period PERIOD between the rising edges of the vehicle speed pulse signal. Process 305 stores the current ICRNEW in ICROLD for calculation of the next cycle. In process 306, the vehicle speed conversion count L is divided by the vehicle speed pulse period PERIOD to obtain the vehicle speed VSP.

【0032】図17は、40ms周期で行う処理であ
る。まず、処理307ではスロットル開度センサ104
をA/D変換器4により取り込む処理を行う。また、処
理308では、図13に示すライン圧制御マップの検索処
理を行いライン圧(PL_duty)を決定する。同様に処理
309では、図14に示すロックアップ制御マップの検
索処理を行いロックアップの度合い(L/U_duty)を
決定する。処理310では、図11に示す変速スケジュ
ールマップの検索を行いギア位置を決定する。処理31
1では、変速を検出しエンジンへトルク減指令を発生す
る。処理312では、決定されたギア位置になるように
図12で示した変速信号をポート出力手段8に出力す
る。
FIG. 17 shows a process performed in a 40 ms cycle. First, in process 307, the throttle opening sensor 104
Is taken in by the A / D converter 4. Further, in process 308, the line pressure control map shown in FIG. 13 is searched to determine the line pressure (PL_duty). Similarly, in the process 309, the lock-up control map shown in FIG. 14 is searched to determine the lock-up degree (L / U_duty). In process 310, the shift schedule map shown in FIG. 11 is searched to determine the gear position. Process 31
In 1, the shift is detected and a torque reduction command is generated to the engine. In process 312, the shift signal shown in FIG. 12 is output to the port output means 8 so that the determined gear position is reached.

【0033】次に、ライン圧(PL_duty)とロックア
ップ圧の(L/U_duty)を制御するためのPWM信号
の発生処理の詳細について説明する。
Next, the details of the generation processing of the PWM signal for controlling the line pressure (PL_duty) and the lockup pressure (L / U_duty) will be described.

【0034】図18は、アウトプットコンペアレジスタ
OCRが仮想的に多数あるように処理するために設ける
データテーブルである。これは、RAM10内に確保す
る。U仮想OCR_nへはn番目のパルスを立上げたい
時刻、U出力パターン_nには立上げたい端子、UVALID
_nにはこの立上げたいn番目の時刻データと出力パタ
ーンのデータが有効なものであるかどうかをあらわすフ
ラグを記憶する。同様にD仮想OCR_nへはn番目の
パルスを立下げたい時刻、D出力パターン_nには立下
げたい端子、DVALID_nにはこの立下げたいn番目の時
刻データと出力パターンのデータが有効なものであるか
どうかをあらわすフラグを記憶する。このデータテーブ
ルを用いて2本のPWM信号を出力するためにPWM信
号の立上げにはOCR_d24,立下げにはOCR_e
26による割込みを用いて処理する。
FIG. 18 is a data table provided for processing so that the output compare registers OCR are virtually many. This is secured in the RAM 10. U Virtual OCR_n is the time to start the nth pulse, U output pattern_n is the terminal to be started, UVALID
In _n, a flag indicating whether or not the n-th time data to be started and the data of the output pattern are valid is stored. Similarly, the D virtual OCR_n is the time at which the nth pulse is desired to fall, the D output pattern_n is the terminal at which it is desired to be fallen, and the DVALID_n is the nth time data and output pattern data at which it is desired to be fallen. The flag indicating whether or not there is stored is stored. Since two PWM signals are output using this data table, OCR_d24 is used for rising the PWM signal and OCR_e is used for falling.
Process using interrupt by 26.

【0035】図19は、PWM信号を立上げるために行
う処理でOCR_d24の割り込みINT6で起動す
る。まず、処理313で出力ポート8と立上げ出力パタ
ーンのビット毎の論理和をとる。これにより立上げたい
ビットに1が立つ。以後の処理で次回の出力パターンと
時刻の設定を行う。処理314では、出力したU仮想O
CRに対応するUVALIDフラグをクリアして検索の対象か
らはずす。次に、処理315ではこの割り込み処理がラ
イン圧のPWM信号の立上げのために発生したものかど
うか判断する。もしそうであれば処理316でU仮想O
CR_1に次のライン圧のPWM信号の立上げの時刻を
セットする。同様に、処理317ではD仮想OCR_1
に次のライン圧のPWM信号の立下げの時刻をセットす
る。なおここで示すTp_PLはライン圧PWM信号の
周期、Td_PLはライン圧PWM信号のオン時間であ
る。次に、処理318では、U出力パターン_1のライ
ン圧のPWM信号に対応するビットが1であり、その他
が0であるビットパターンをセットする。同様に、D出
力パターン_1はライン圧のPWM信号に対応するビッ
トが0であり、その他が1であるビットパターンをセッ
トする。次に処理320でセットしたデータが有効となる
ようにUVALID_1とDVALID_1にh′FFをセットす
る。処理321〜処理326についてはロックアップ用
PWM信号について同様の処理を行う。次に、処理3
27では立上げスケジュール処理を行う。これはUVALID
_nがh′FFで有効なU仮想OCR_nの中で現在の
時刻に一番近いU仮想OCR_nの値をOCR_d24
に記憶し、立上げ出力パターンバッファに選ばれたU出
力パターン_nを記憶するものである。次に処理328
では、処理329が多重に起動されたことを検出するた
めの準備を行う。処理329は立下げについても同様の
スケジュール処理を行う。処理330では処理329の
立下げスケジュール処理が多重に起動されたことを検出
して、多重に起動された場合は再度処理329の立下げ
スケジュール処理を行う。
FIG. 19 shows a process for raising the PWM signal, which is started by the interrupt INT6 of the OCR_d24. First, in process 313, the logical sum of the output port 8 and the rising output pattern is calculated for each bit. As a result, 1 is set to the bit to be started. The next output pattern and time are set in the subsequent processing. In process 314, the output U virtual O
Clear the UVALID flag corresponding to CR to remove it from the search target. Next, in process 315, it is determined whether or not this interrupt process is generated for the rise of the line pressure PWM signal. If so, in process 316, U virtual O
The rising time of the PWM signal of the next line pressure is set in CR_1. Similarly, in process 317, D virtual OCR_1
Is set to the time when the next PWM signal of line pressure falls. Note that Tp_PL shown here is the period of the line pressure PWM signal, and Td_PL is the on-time of the line pressure PWM signal. Next, in process 318, a bit pattern in which the bit corresponding to the PWM signal of the line pressure of the U output pattern_1 is 1 and the other bits are 0 is set. Similarly, the D output pattern_1 sets a bit pattern in which the bit corresponding to the line pressure PWM signal is 0 and the other bits are 1. Next, h'FF is set to UVALID_1 and DVALID_1 so that the data set in the process 320 becomes valid. Regarding the processes 321 to 326, the same process is performed for the lockup PWM signal. Next, process 3
At 27, a startup schedule process is performed. This is UVALID
In the valid U virtual OCR_n where _n is h'FF, the value of the U virtual OCR_n closest to the current time is set to OCR_d24.
And the U output pattern_n selected in the startup output pattern buffer is stored. Next, processing 328
Then, preparation is made for detecting that the processing 329 has been activated multiple times. In the process 329, the same schedule process is performed for the shutdown. In process 330, it is detected that the shutdown schedule processes of process 329 have been activated in a multiple manner, and when they are activated in a multiple manner, the shutdown schedule process of process 329 is performed again.

【0036】図20は、PWM信号を立下げるために行
う処理でOCR_e26の割り込みINT7で起動す
る。まず、処理331で出力ポート8と立上げ出力パタ
ーンのビット毎の論理積をとる。これにより立下げたい
ビットが0になる。次に処理314で出力したD仮想O
CRに対応するDVALIDフラグをクリアして検索の対象か
らはずす。処理329では次の立下げを探すために立下
げスケジュール処理を行う。処理332では、この処理
329が多重に割り込んだことを示すフラグをセットす
る。
FIG. 20 shows a process performed for falling the PWM signal, which is activated by the interrupt INT7 of the OCR_e26. First, in process 331, the logical product of the output port 8 and the rising output pattern is obtained for each bit. As a result, the bit to be lowered becomes 0. Next, the D virtual O output in processing 314
Clear the DVALID flag corresponding to CR to remove it from the search target. In process 329, a fall schedule process is performed to search for the next fall. In process 332, a flag indicating that this process 329 has been interrupted multiple times is set.

【0037】次に、立上げスケジュール処理327の詳
細について説明する。なお、本処理はCPU2で行う
が、CPU2はR0〜R15の16本の汎用レジスタを
持つものとする。まず、処理333でイニシャライズを
行い全体の準備をする。処理334では現在時刻をレジ
スタR10に記憶する。次に、処理335ではUVALIDフ
ラグが有効であるかどうか判別し、有効である場合は、
処理336で現在時刻とU仮想OCR_nの差を演算す
る。処理337では、処理336で出した差がレジスタ
R11より小さいかどうか判別する。レジスタR11の
内容は、処理341で決定され、このルートをたどって
処理342へ来る場合はU仮想OCR_nは現在時刻に
一番近いものとなる。従って、処理342では、レジス
タR14へU仮想OCR_nを記憶し、処理343でレジ
スタR5にU出力パターン_nを記憶し、出力の準備を
行う。また、処理339へ進む場合はU仮想OCR_n
が現在時刻に近くないか一番近いものと等しい場合であ
る。従って、処理339で、U仮想OCR_nが現在時
刻に一番近いものと等しいかどうか判断し、等しい場合
は処理340でR5にU出力パターン_nをマージす
る。処理334ではnをインクリメントし、処理345
でnが2かどうか判断する。これはPWM信号が2本で
あるためであり、この値を増やす事によりPWM信号出
力本数の増加に対応することができる。処理346で
は、処理343で準備しておいたレジスタR5の値を立
上げ出力パターンバッファに記憶する。同様に処理34
7では、処理342で準備しておいたレジスタR14の
値をOCR_d24に記憶し、次回の立上げ準備が完了
する。
Next, details of the startup schedule process 327 will be described. Although this processing is performed by the CPU 2, it is assumed that the CPU 2 has 16 general-purpose registers R0 to R15. First, in process 333, initialization is performed to prepare the whole. In process 334, the current time is stored in the register R10. Next, in process 335, it is determined whether the UVALID flag is valid, and if it is valid,
In process 336, the difference between the current time and the U virtual OCR_n is calculated. In process 337, it is determined whether the difference generated in process 336 is smaller than the register R11. The content of the register R11 is determined in the process 341, and when the route is followed to the process 342, the U virtual OCR_n becomes closest to the current time. Therefore, in the process 342, the U virtual OCR_n is stored in the register R14, and the U output pattern_n is stored in the register R5 in the process 343 to prepare for output. When proceeding to processing 339, U virtual OCR_n
Is not close to or equal to the current time. Therefore, in the process 339, it is determined whether the U virtual OCR_n is equal to the closest one to the current time, and if they are equal, the U output pattern_n is merged into R5 in the process 340. In process 334, n is incremented and process 345
Determines whether n is 2. This is because there are two PWM signals, and increasing this value can cope with an increase in the number of PWM signal outputs. In process 346, the value of the register R5 prepared in process 343 is stored in the startup output pattern buffer. Similarly, process 34
In 7, the value of the register R14 prepared in the process 342 is stored in the OCR_d24, and the next startup preparation is completed.

【0038】図22は立下げスケジュール処理329の
フローチャートである。処理内容は前記立上げスケジュ
ール処理327とほぼ同じであるため省略する。
FIG. 22 is a flowchart of the shutdown schedule processing 329. Since the processing contents are almost the same as those of the startup schedule processing 327, the description thereof will be omitted.

【0039】なお、本実施例では、説明を分かりやすく
するために図3で示す出力タイミングの遅れ補償は省略
している。
In this embodiment, the output timing delay compensation shown in FIG. 3 is omitted for the sake of clarity.

【0040】以上で自動変速機110の制御法の説明は
終わり、次にエンジン101の制御方法について説明す
る。まず図10のエンジンの制御ブロック217につい
て説明する。REFセンサ103で得られるエンジンの
回転に同期したパルス信号を用いてブロック208によ
りパルスの周期を計測してエンジン回転数Neを算出す
る。また、空気流量センサ105による信号をブロック
205で係数換算処理し、空気流入量Qaを算出する。
これらの値を用いて基本燃料噴射量TIの算出をブロッ
ク206で次式(1)に従い行う。
This completes the description of the control method for the automatic transmission 110. Next, the control method for the engine 101 will be described. First, the control block 217 of the engine shown in FIG. 10 will be described. An engine speed Ne is calculated by measuring a pulse cycle by a block 208 using a pulse signal synchronized with the engine rotation obtained by the REF sensor 103. Further, the signal from the air flow rate sensor 105 is subjected to coefficient conversion processing in block 205 to calculate the air inflow amount Qa.
Using these values, the basic fuel injection amount TI is calculated in block 206 according to the following equation (1).

【0041】[0041]

【数1】 [Equation 1]

【0042】ただし、K :補正係数 Ts:無効パルス幅 また、燃料噴射のタイミングTITMは、エンジン回転
数Neから決定することができ、具体的にはテーブル検
索等によって得る。また、ブロック201で得られるス
ロットル開度より、スロットル開度がある値以上の時、
燃料を増量するなどの補正を行っても良い。また、ブロ
ック209より得られるO2 センサ信号より理論空燃比
であるかどうか検出し、比例制御や積分制御などのフィ
ードバック制御を行うために燃料噴射量TIを制御して
も良い。このようにして得られた基本燃料噴射量TIと
燃料噴射タイミングTITMは、ブロック207により
噴射パルスとして出力される。
However, K: correction coefficient Ts: invalid pulse width, and the fuel injection timing TITM can be determined from the engine speed Ne, and is specifically obtained by a table search or the like. Further, when the throttle opening obtained by the block 201 is a certain value or more,
Correction such as increasing the amount of fuel may be performed. Further, the fuel injection amount TI may be controlled to detect whether or not the stoichiometric air-fuel ratio is the stoichiometric air-fuel ratio from the O 2 sensor signal obtained from the block 209 and to perform feedback control such as proportional control and integral control. The basic fuel injection amount TI and the fuel injection timing TITM obtained in this way are output as an injection pulse by the block 207.

【0043】次に、点火信号の生成について説明する。
ブロック205で得られる吸入空気量とブロック208
から得られるエンジン回転数Neからブロック210で
点火信号パルス幅DWELLと点火タイミングADVを
決定する。これは、予め設定しておいたデータテーブル
を検索することにより得ている。この点火信号パルス幅
DWELLと点火タイミングADVは、ブロック211
により点火パルスとして出力される。
Next, the generation of the ignition signal will be described.
Intake air amount obtained in block 205 and block 208
The ignition signal pulse width DWELL and the ignition timing ADV are determined in block 210 from the engine speed Ne obtained from the above. This is obtained by searching a preset data table. The ignition signal pulse width DWELL and the ignition timing ADV are stored in the block 211.
Is output as an ignition pulse.

【0044】図23に、エンジン制御のタイムチャート
を示す。上から順番に、POSセンサ102の信号波
形,REFセンサ103の信号波形,フリーランニング
カウンタFRC_a16の値、POSセンサ信号の立ち
上がりエッジでカウントアップするカウンタCNT_a
29の値,第1気筒の燃料噴射信号INJ#1の出力波
形,第2気筒の燃料噴射信号INJ#2の出力波形,第
3気筒の燃料噴射信号INJ#3の出力波形,第4気筒
の燃料噴射信号INJ#4の出力波形,第1気筒の点火
信号IGN#1の出力波形,第2気筒の点火信号IGN
#2の出力波形,第3気筒の点火信号IGN#3の出力
波形,第4気筒の点火信号IGN#4の出力波形,180d
eg処理のタイミング,OCR_a処理のタイミング,O
CR_b処理のタイミング,OCR_f処理のタイミン
グ,OCR_g処理のタイミングを示す。
FIG. 23 shows a time chart of engine control. In order from the top, the signal waveform of the POS sensor 102, the signal waveform of the REF sensor 103, the value of the free running counter FRC_a16, and the counter CNT_a that counts up at the rising edge of the POS sensor signal.
29, the output waveform of the fuel injection signal INJ # 1 of the first cylinder, the output waveform of the fuel injection signal INJ # 2 of the second cylinder, the output waveform of the fuel injection signal INJ # 3 of the third cylinder, the output waveform of the fourth cylinder Output waveform of fuel injection signal INJ # 4, output waveform of ignition signal IGN # 1 of first cylinder, ignition signal IGN of second cylinder
# 2 output waveform, third cylinder ignition signal IGN # 3 output waveform, fourth cylinder ignition signal IGN # 4 output waveform, 180d
eg processing timing, OCR_a processing timing, O
The timing of CR_b processing, the timing of OCR_f processing, and the timing of OCR_g processing are shown.

【0045】なお、第1気筒の燃料噴射信号INJ#1
から第4気筒の燃料噴射信号INJ#4までの燃料噴射パル
ス信号の立上げタイミングは、REF信号周期(エンジ
ン回転角180度周期)で発生する。従って、この立上
げタイミング同士は必ずある程度の時間間隔(例えば4
気筒4サイクルエンジンでエンジン回転数8000rpm
の場合、約3.75ms)を持っている。このため、こ
の時間でOCRの更新を行えば1本のOCRで立上げタ
イミングを制御することができる。また、この条件は、
燃料噴射パルスの立下げタイミング,第1気筒の点火信
号IGN#1から第4気筒の点火信号IGN#4までの
点火パルス信号の立上げタイミング、および点火パルス
信号の立下げタイミングについても同様である。このた
め、それぞれの立上げグループ及び立下げグループ毎に
1本のOCRを持つ事により、それぞれの立上げまたは
立下げタイミングを制御することができる。なお、この
ことはエンジンの気筒数が変化しても成立する条件であ
るため、エンジンの気筒数が変化してもOCRの本数を
変更する必要はない。
The fuel injection signal INJ # 1 for the first cylinder
The rising timing of the fuel injection pulse signal from the fuel injection signal INJ # 4 to the fourth cylinder is generated in the REF signal cycle (engine rotation angle cycle of 180 degrees). Therefore, these start-up timings must be separated by a certain time interval (for example, 4
Engine speed 8000 rpm with a 4-cylinder cylinder engine
In the case of, it has about 3.75 ms). Therefore, if the OCR is updated at this time, the startup timing can be controlled by one OCR. Also, this condition is
The same applies to the falling timing of the fuel injection pulse, the rising timing of the ignition pulse signal from the ignition signal IGN # 1 of the first cylinder to the ignition signal IGN # 4 of the fourth cylinder, and the falling timing of the ignition pulse signal. . Therefore, by having one OCR for each startup group and each shutdown group, the startup or shutdown timing of each can be controlled. Since this is a condition that holds even if the number of cylinders of the engine changes, it is not necessary to change the number of OCRs even if the number of cylinders of the engine changes.

【0046】次に、各処理の概要について説明する。18
0deg処理(r1)では、エンジン回転数Neの算出,基
本燃料噴射量TI及び燃料噴射タイミングTITMの算
出,点火タイミングADV,通電角DWELLの演算等
を行い、燃料噴射を開始する時刻(オフセット1)をO
CR_c22に、点火を開始する角度(オフセット2)を
OCR_h33に設定する。オフセット1処理(o1)
では、燃料噴射パルスの出力時刻(f1),(f2)と出
力パターンを生成し、最初に立上がりが発生する出力時
刻をOCR_a14に、立上げ出力パターンを立上げ出
力パターンバッファに設定する。また、最初に立下がり
が発生する出力時刻はOCR_b18に、立下げ出力パ
ターンを立下げ出力パターンバッファに設定する。オフ
セット2処理(s1)では、点火パルスの出力角度(c
1),(c2)と出力パターンを生成し、最初に立上がり
が発生する出力角度をOCR_f27に、立上げ出力パ
ターンを立上げ出力パターンバッファに設定する。ま
た、最初に立下がりが発生する出力角度はOCR_g3
1に、立下げ出力パターンを立下げ出力パターンバッフ
ァに設定する。
Next, the outline of each processing will be described. 18
In the 0 deg process (r1), the engine speed Ne is calculated, the basic fuel injection amount TI and the fuel injection timing TITM are calculated, the ignition timing ADV, the energization angle DWELL are calculated, and the time at which fuel injection is started (offset 1) O
In CR_c22, the angle (offset 2) at which ignition is started is set in OCR_h33. Offset 1 processing (o1)
Then, the output times (f1) and (f2) of the fuel injection pulse and the output pattern are generated, and the output time at which the rising occurs first is set to OCR_a14 and the rising output pattern is set to the rising output pattern buffer. Further, the output time at which the fall occurs first is set to OCR_b18, and the fall output pattern is set to the fall output pattern buffer. In the offset 2 process (s1), the ignition pulse output angle (c
1) and (c2) are generated, and the output angle at which the rising occurs first is set in OCR_f27, and the rising output pattern is set in the rising output pattern buffer. Also, the output angle at which the fall occurs first is OCR_g3.
The fall output pattern is set to 1 in the fall output pattern buffer.

【0047】これらOCR_a14,OCR_b18,
OCR_f27,OCR_g31への設定により次の動
作を行う。まず、OCR_a処理(a1)では、燃料噴
射信号の立上げと立下げ時刻の設定。OCR_b処理
(b1)では、燃料噴射信号の立下げ。OCR_f処理
(f1)では、点火信号の立上げと立下げ角度の設定。
OCR_g処理(g1)では、点火信号の立下げを行う。
なお、180deg処理(r2),(r3),(r4)では前記18
0deg処理(r1)と、オフセット1処理(o2),(o
3),(o4)では、前記オフセット1処理(o1)と、
オフセット2処理(s2),(s3),(s4)では、前記
オフセット2処理(s1)と、OCR_a処理(a
2),(a3),(a4)では、前記OCR_a処理(a
1)と、OCR_b処理(b2),(b3),(b4)で
は、前記OCR_b処理(b1)と、OCR_f処理
(f2),(f3),(f4)では、前記OCR_f処理
(f1)と、OCR_g処理(g2),(g3),(g4)で
は、前記OCR_g処理(g1)と同様の処理を行う。
These OCR_a14, OCR_b18,
The following operation is performed by setting the OCR_f27 and OCR_g31. First, in the OCR_a process (a1), the rise and fall times of the fuel injection signal are set. In the OCR_b process (b1), the fall of the fuel injection signal. In the OCR_f process (f1), the rise and fall angles of the ignition signal are set.
In the OCR_g process (g1), the ignition signal is lowered.
In the 180 deg processing (r2), (r3), (r4), the above 18
0 deg processing (r1) and offset 1 processing (o2), (o
3) and (o4), the offset 1 process (o1) and
In the offset 2 processing (s2), (s3), (s4), the offset 2 processing (s1) and the OCR_a processing (a
2), (a3), (a4), the OCR_a process (a
1) and OCR_b processes (b2), (b3), and (b4), the OCR_b process (b1) and the OCR_f processes (f2), (f3), and (f4) are the OCR_f processes.
In (f1) and OCR_g processing (g2), (g3), and (g4), the same processing as the OCR_g processing (g1) is performed.

【0048】次に、図24〜図31により、本発明によ
るエンジン制御フローチャートについて説明する。
Next, the engine control flowchart according to the present invention will be described with reference to FIGS.

【0049】図24は、クランク角180deg毎に起動要求
が発生するタスクのフローチャートである。処理362
では、REF信号の立ち上がりタイミングの時間が記憶
されるICR_a19の値を用いてREF信号のパルス
周期を求めエンジン回転数を演算する。処理363で
は、エンジン回転数や吸入空気量などから基本燃料噴射
量TI及び燃料噴射タイミングTITMを演算する。処
理364では、エンジン回転数や吸入空気量などから点
火角ADVや通電角DWELLを演算する。処理365
では、クランク角1回転を検出し1rev 起動要求を発生
する。処理366では、燃料噴射時刻(オフセット1)
をOCR_c22に、通電開始角度(オフセット2)を
OCR_h33にセットする。
FIG. 24 is a flow chart of a task for which an activation request is generated for each crank angle of 180 deg. Process 362
Then, the pulse cycle of the REF signal is obtained using the value of ICR_a19 in which the time of the rising timing of the REF signal is stored, and the engine speed is calculated. In process 363, the basic fuel injection amount TI and the fuel injection timing TITM are calculated from the engine speed, the intake air amount, and the like. In process 364, the ignition angle ADV and the energization angle DWELL are calculated from the engine speed and the intake air amount. Process 365
Then, one revolution of the crank angle is detected and a 1rev start request is generated. In process 366, the fuel injection time (offset 1)
Is set to OCR_c22, and the energization start angle (offset 2) is set to OCR_h33.

【0050】図25は、前記タイマ6で発生する10m
s周期で起動要求が発生するタスクのフローチャートで
ある。ここでは、処理367により、AFMセンサ10
5から信号を取り込み吸入空気量データを取得する。
FIG. 25 shows 10 m generated by the timer 6.
It is a flowchart of the task which an activation request generate | occur | produces in s period. Here, the AFM sensor 10 is processed by the process 367.
The signal is taken in from 5 and intake air amount data is acquired.

【0051】図26は、1rev 周期で起動要求が発生す
るタスクのフローチャートである。処理368では、O
2 センサ108の信号の取り込み処理を行う。処理36
9では、取り込んだO2 センサ信号をもとに燃料噴射時
間の増減を行い、空燃比が14.7 になるように制御す
る。
FIG. 26 is a flow chart of a task for which an activation request is generated in a cycle of 1 rev. In process 368, O
2 The signal of the sensor 108 is captured. Process 36
In No. 9, the fuel injection time is increased or decreased based on the captured O 2 sensor signal, and the air-fuel ratio is controlled to be 14.7.

【0052】次に燃料噴射と点火処理の中でアウトプッ
トコンペアレジスタOCR処理に関係する部分のフロー
チャートについて詳細に説明する。本実施例では、気筒
数の変化に対応しやすくするため、前記、図18で示し
た仮想化タイマデータ記憶形式と図21で示した立上げ
スケジュール処理327と図22で示した立下げスケジ
ュール処理329を用いて対策している。
Next, a detailed description will be given of the flow chart of the portion related to the output compare register OCR processing in the fuel injection and ignition processing. In the present embodiment, in order to easily respond to changes in the number of cylinders, the virtualization timer data storage format shown in FIG. 18, the startup schedule process 327 shown in FIG. 21, and the shutdown schedule process shown in FIG. 329 is used to take countermeasures.

【0053】図27は、オフセット1処理のフローチャ
ートである。処理370は、U仮想OCR_nに現在時
刻+ΔTの値をセットする。ΔTはごく小さな値であ
り、この処理のΔT時刻後にn気筒のインジェクタIN
J信号を立上げることを目的としている。処理371で
は、出力パターン_nのインジェクタnに対応するビッ
トが1であり、その他が0であるビットパターンをセッ
トする。また、処理372では、処理370,処理371
でセットしたデータが有効となるようにUVALID_nに
h′FFをセットする。その後処理327の立上げスケ
ジュール処理を行い、OCR_a14の設定を行う。処
理373〜処理377ではインジェクタnが噴射終了時
刻にオフするように立上げ時と同様の処理を行う。
FIG. 27 is a flowchart of the offset 1 process. The process 370 sets the value of the current time + ΔT to the U virtual OCR_n. ΔT is a very small value, and after the ΔT time of this process, the injector IN of the n-cylinder IN
The purpose is to raise the J signal. In process 371, a bit pattern in which the bit corresponding to the injector n in the output pattern_n is 1 and the other bits are 0 is set. Further, in process 372, process 370 and process 371.
Set h'FF in UVALID_n so that the data set in step 3 becomes valid. After that, the startup schedule process of the process 327 is performed, and the OCR_a14 is set. In processing 373 to processing 377, processing similar to that at the time of startup is performed so that the injector n is turned off at the injection end time.

【0054】図28はOCR_a14の割り込みで発生
する処理のフローチャートである。処理378では出力
ポート5と立上げ出力パターンバッファのビット毎の論
理和をとる。これにより立上げたいビットが1になる。
処理379〜処理384では、出力したU仮想OCRに
対応するUVALIDフラグをクリアして検索の対象からはず
す処理を行っている。
FIG. 28 is a flow chart of the processing generated by the interrupt of OCR_a14. In step 378, the logical sum of the output port 5 and the rising output pattern buffer is calculated for each bit. As a result, the bit to be activated becomes 1.
In steps 379 to 384, the UVALID flag corresponding to the output U virtual OCR is cleared to remove it from the search target.

【0055】図29はOCR_b18の割り込みで発生
する処理のフローチャートである。処理385では出力
ポート5と立下げ出力パターンバッファのビット毎の論
理積をとる。これにより立下げたいビットが0になる。
処理386〜処理391では、出力したD仮想OCRに
対応するDVALIDフラグをクリアして検索の対象からはず
す処理を行っている。次に処理329の立下げスケジュ
ール処理を行い、処理392で多重割り込みを知らせる
フラグをセットする。
FIG. 29 is a flow chart of the processing generated by the interruption of OCR_b18. In step 385, the logical product of the output port 5 and the falling output pattern buffer is calculated for each bit. As a result, the bit to be lowered becomes 0.
In steps 386 to 391, the DVALID flag corresponding to the output D virtual OCR is cleared to remove it from the search target. Next, the fall schedule process of process 329 is performed, and the flag notifying multiple interrupts is set in process 392.

【0056】図30〜図32については点火パルス発生
についてのフローチャートであるが、燃料噴射とほぼ同
じ処理であるため説明は省略する。
30 to 32 are flowcharts for the ignition pulse generation, the description thereof is omitted because the processing is almost the same as the fuel injection.

【0057】以上の処理により、立上げ用と立下げ用の
2本のOCRのペアでエンジンの燃料噴射信号や点火信
号を出力することができ、1チップマイクロコンピュー
タのハードウェア構成を簡素化でき、かつ、仮想OCR
プログラムを変更することで、同一仕様のマイクロコン
ピュータでエンジンの気筒数に関係なく制御することが
可能となる。
By the above processing, the fuel injection signal and the ignition signal of the engine can be output by the pair of two OCRs for start-up and fall, and the hardware configuration of the one-chip microcomputer can be simplified. , And virtual OCR
By changing the program, it becomes possible to control with the same specification microcomputer regardless of the number of cylinders of the engine.

【0058】なお、前記仮想OCR更新処理と前記OC
Rnの更新処理は、フリーランニングカウンタ16の入
力クロック周期が3.2μs 周期であるため、処理時間
も3.2μs 以下であることが望ましい。例えば、前記
仮想OCR更新処理は、処理ステップ数が64ステップ
程度必要であるため、クロック周波数が20MHz以上
のマイクロコンピュータを用いることが望ましい。
The virtual OCR update process and the OC
Since the input clock cycle of the free running counter 16 is 3.2 μs in the Rn update processing, the processing time is preferably 3.2 μs or less. For example, since the virtual OCR updating process requires about 64 processing steps, it is desirable to use a microcomputer having a clock frequency of 20 MHz or higher.

【0059】[0059]

【発明の効果】以上の説明から理解されるように、本発
明によれば、多数のパルス出力処理を可能とし、しか
も、パルス出力周辺機能を自在かつ広範に利用できるよ
うにするとともに、全体を安価な構成とすることがで
き、パルス信号の出力が非常に多い自動車総合制御等に
好適な制御用処理装置としても利用することができる。
As can be understood from the above description, according to the present invention, a large number of pulse output processes can be performed, and further, the pulse output peripheral functions can be freely and widely used, and the whole system can be used. It can have an inexpensive structure and can also be used as a control processing device suitable for vehicle integrated control and the like in which a lot of pulse signals are output.

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

【図1】出力機能と端子がフレキシブルな制御装置の構
成図。
FIG. 1 is a configuration diagram of a control device having flexible output functions and terminals.

【図2】PWM出力のタイムチャート。FIG. 2 is a time chart of PWM output.

【図3】出力タイミングずれ対策。FIG. 3 Measures against output timing deviation.

【図4】仮想PWM処理のフローチャート。FIG. 4 is a flowchart of virtual PWM processing.

【図5】出力部回路ブロック図。FIG. 5 is a block diagram of an output circuit.

【図6】真理値表。[6] truth Diagram Table.

【図7】ラッチ回路。FIG. 7 is a latch circuit.

【図8】エンジン,自動変速機制御システムのハードウ
ェア構成図。
FIG. 8 is a hardware configuration diagram of an engine and an automatic transmission control system.

【図9】フリーランニングタイマのブロック図。FIG. 9 is a block diagram of a free running timer.

【図10】エンジン,自動変速機の制御ブロック図。FIG. 10 is a control block diagram of an engine and an automatic transmission.

【図11】変速スケジュールマップ。FIG. 11 is a shift schedule map.

【図12】ギア位置と変速信号出力の関係。FIG. 12 shows the relationship between gear position and shift signal output.

【図13】ライン圧制御マップ。FIG. 13 is a line pressure control map.

【図14】ロックアップ制御マップ。FIG. 14 is a lockup control map.

【図15】バックグラウンド処理のフローチャート。FIG. 15 is a flowchart of background processing.

【図16】車速計測処理のフローチャート。FIG. 16 is a flowchart of vehicle speed measurement processing.

【図17】40ms処理のフローチャート。FIG. 17 is a flowchart of 40 ms processing.

【図18】仮想化タイマデータ記憶形式。FIG. 18 is a virtual timer data storage format.

【図19】OCR_d割込処理のフローチャート。FIG. 19 is a flowchart of OCR_d interrupt processing.

【図20】OCR_e割込処理のフローチャート。FIG. 20 is a flowchart of OCR_e interrupt processing.

【図21】立上げスケジュール処理のフローチャート。FIG. 21 is a flowchart of startup schedule processing.

【図22】立下げスケジュール処理のフローチャート。FIG. 22 is a flowchart of a shutdown schedule process.

【図23】エンジン制御のタイムチャート。FIG. 23 is a time chart of engine control.

【図24】180deg処理のフローチャート。FIG. 24 is a flowchart of 180 deg processing.

【図25】10ms処理のフローチャート。FIG. 25 is a flowchart of 10 ms processing.

【図26】1rev処理のフローチャート。FIG. 26 is a flowchart of 1rev processing.

【図27】オフセット1処理のフローチャート。FIG. 27 is a flowchart of offset 1 processing.

【図28】OCR_a割込処理のフローチャート。FIG. 28 is a flowchart of OCR_a interrupt processing.

【図29】OCR_b割込処理のフローチャート。FIG. 29 is a flowchart of OCR_b interrupt processing.

【図30】オフセット2処理のフローチャート。FIG. 30 is a flowchart of offset 2 processing.

【図31】OCR_f割込処理のフローチャート。FIG. 31 is a flowchart of OCR_f interrupt processing.

【図32】OCR_g割込処理のフローチャート。FIG. 32 is a flowchart of OCR_g interrupt processing.

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

1…1チップマイクロコンピュータ、2…制御部、6…
フリーランニングタイマ手段、8…出力部、10…出力
バッファ、14…比較データ部、15…比較部、16…
カウンタ部、38,39…ラッチ回路、101…エンジ
ン、110…アクチュエータ、ICR…インプットキャ
プチャーレジスタ、FRC…フリーランニングカウン
タ、OCR…アウトプットコンペアレジスタ、CNT…
パルスカウンタ、TVO…スロットル開度、AFM…空
気流量センサ、INJ…燃料噴射信号、IGN…点火信
号、REF…180degパルス信号、POS…2deg パルス
信号。
1 ... 1-chip microcomputer, 2 ... control unit, 6 ...
Free-running timer means, 8 ... Output unit, 10 ... Output buffer, 14 ... Comparison data unit, 15 ... Comparison unit, 16 ...
Counter section, 38, 39 ... Latch circuit, 101 ... Engine, 110 ... Actuator, ICR ... Input capture register, FRC ... Free running counter, OCR ... Output compare register, CNT ...
Pulse counter, TVO ... Throttle opening, AFM ... Air flow sensor, INJ ... Fuel injection signal, IGN ... Ignition signal, REF ... 180 deg pulse signal, POS ... 2 deg pulse signal.

───────────────────────────────────────────────────── フロントページの続き (72)発明者 渡部 満 茨城県ひたちなか市大字高場2520番地 株式会社 日立製作所 自動車機器事業 部内 (72)発明者 市橋 哲也 茨城県ひたちなか市大字高場字鹿島谷津 2477番地3日立オートモティブエンジニ アリング株式会社内 (72)発明者 佐々木 昭二 茨城県ひたちなか市大字高場2520番地 株式会社 日立製作所 自動車機器事業 部内 (56)参考文献 特開 昭62−151969(JP,A) 特開 平5−53417(JP,A) 特開 平3−161883(JP,A) 特開 平5−101196(JP,A) (58)調査した分野(Int.Cl.7,DB名) G05B 19/05 G06F 15/78 510 ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Inventor Mitsuru Watabe 2520 Takaba, Hitachinaka City, Ibaraki Prefecture Hitachi, Ltd. Automotive Equipment Division, Hitachi, Ltd. (72) Tetsuya Ichihashi 2477 Kashima Yatsu Kashima Yatsu, Hitachinaka City, Ibaraki Prefecture 3 Inside Hitachi Automotive Engineering Co., Ltd. (72) Inventor Shoji Sasaki 2520, Takaba, Hitachinaka City, Ibaraki Prefecture Hitachi, Ltd. Automotive Equipment Division (56) Reference JP 62-151969 (JP, A) Japanese Patent Laid-Open No. 5-53417 (JP, A) Japanese Patent Laid-Open No. 3-161883 (JP, A) Japanese Patent Laid-Open No. 5-101196 (JP, A) (58) Fields investigated (Int.Cl. 7 , DB name) G05B 19 / 05 G06F 15/78 510

Claims (4)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】一定周波数のパルスをカウントするカウン
タ部と、前記カウンタ部と比較する比較データを記憶す
る比較データ部と、前記カウンタ部と比較データを比較
する比較部と、出力端子と出力値を指定できる出力部
と、それらを制御する制御部を持つ制御用処理装置にお
いて、 前記制御部は、前記比較部の一致条件が成立したとき、
前記出力部の出力端子と出力値を設定するとともに、前
記比較データと現在時刻の差が予め定める所定時間より
小さいときに、前記予め定める所定時間を前記現在時刻
に加算することにより新たな比較データとし前記出力値
の動作時刻を設定することを特徴とする制御用処理装
置。
1. A counter section for counting pulses of a constant frequency, a comparison data section for storing comparison data for comparison with the counter section, a comparison section for comparing the counter section with comparison data, an output terminal and an output value. In the control processing device having an output unit capable of designating and a control unit for controlling them, the control unit, when the matching condition of the comparison unit is satisfied,
While setting the output terminal and output value of the output section ,
The difference between the comparison data and the current time is from a predetermined time
When it is small, the predetermined time is set to the current time.
And output value as new comparison data
Control device characterized by setting the operating time of
Place
【請求項2】請求項1に記載の制御用処理装置におい
て、前記出力部の出力信号が少なくとも1本以上のPW
Mパルス信号であることを特徴とする制御用処理装置。
2. The control processing device according to claim 1, wherein the output signal of the output unit is at least one PW.
A processing device for control, which is an M pulse signal.
【請求項3】請求項1に記載の制御用処理装置におい
て、前記出力部の出力信号が少なくとも1本以上の自動
車用エンジンの燃料噴射パルス信号であることを特徴と
する制御用処理装置。
3. The control processing apparatus according to claim 1, wherein the output signal of the output unit is a fuel injection pulse signal of at least one automobile engine.
【請求項4】請求項1に記載の制御用処理装置におい
て、前記出力部の出力信号が少なくとも1本以上の自動
車用エンジンの点火パルス信号であることを特徴とする
制御用処理装置。
4. The control processing device according to claim 1, wherein the output signal of the output section is an ignition pulse signal of at least one automobile engine.
JP11282495A 1995-05-11 1995-05-11 Processing unit for control Expired - Fee Related JP3400605B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP11282495A JP3400605B2 (en) 1995-05-11 1995-05-11 Processing unit for control

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP11282495A JP3400605B2 (en) 1995-05-11 1995-05-11 Processing unit for control

Publications (2)

Publication Number Publication Date
JPH08305420A JPH08305420A (en) 1996-11-22
JP3400605B2 true JP3400605B2 (en) 2003-04-28

Family

ID=14596459

Family Applications (1)

Application Number Title Priority Date Filing Date
JP11282495A Expired - Fee Related JP3400605B2 (en) 1995-05-11 1995-05-11 Processing unit for control

Country Status (1)

Country Link
JP (1) JP3400605B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4752807B2 (en) * 2007-05-08 2011-08-17 株式会社デンソー Microcomputer
JP6029433B2 (en) * 2012-11-26 2016-11-24 ルネサスエレクトロニクス株式会社 Microcomputer

Also Published As

Publication number Publication date
JPH08305420A (en) 1996-11-22

Similar Documents

Publication Publication Date Title
JPH0250304B2 (en)
JP4687640B2 (en) Fuel injection control device
US6679223B2 (en) Engine control system with cam sensor
JP3323655B2 (en) Control processing device and one-chip microcomputer
JPS598656B2 (en) fuel injector
JP3400605B2 (en) Processing unit for control
JP2630442B2 (en) Engine control device
JP2000199450A (en) Engine control device
US6832150B2 (en) Method and apparatus for controlling diesel engine
US5522366A (en) Fuel injection control apparatus for internal combustion engine
JP3350950B2 (en) Automotive electronic control unit
JPH09296743A (en) Internal combustion engine control device for vehicle
JPH01232134A (en) Engine control method
JP3357492B2 (en) Internal combustion engine control device for vehicles
EP0962640A2 (en) Control apparatus for controlling internal combustion engine
JP4475704B2 (en) Engine control device
JP2008128119A (en) Operating condition determination device for internal combustion engine
JPH0230961A (en) Device for controlling engine
JPH07139418A (en) Integrated control system for automobile
JP5794012B2 (en) Electronic control unit
JPH11352097A (en) Apparatus for deciding anomaly in oxygen concentration sensor
JP4752807B2 (en) Microcomputer
JPS6217340A (en) Air fuel ratio controller
JP2001273152A (en) Electronic controller
JP2518604B2 (en) Engine fuel cut device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080221

Year of fee payment: 5

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090221

Year of fee payment: 6

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090221

Year of fee payment: 6

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100221

Year of fee payment: 7

LAPS Cancellation because of no payment of annual fees