JP2009018773A - Electronic control device and method for writing in memory - Google Patents

Electronic control device and method for writing in memory Download PDF

Info

Publication number
JP2009018773A
JP2009018773A JP2007184828A JP2007184828A JP2009018773A JP 2009018773 A JP2009018773 A JP 2009018773A JP 2007184828 A JP2007184828 A JP 2007184828A JP 2007184828 A JP2007184828 A JP 2007184828A JP 2009018773 A JP2009018773 A JP 2009018773A
Authority
JP
Japan
Prior art keywords
data
writing
memory
microcomputer
write 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.)
Withdrawn
Application number
JP2007184828A
Other languages
Japanese (ja)
Inventor
Masanori Akaza
雅憲 赤座
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 JP2007184828A priority Critical patent/JP2009018773A/en
Publication of JP2009018773A publication Critical patent/JP2009018773A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide an electronic control device capable of preventing loss of data due to simultaneous generation of writing processing in a memory and a reset processing by a watchdog timer to improve reliability of data conserved in the memory. <P>SOLUTION: This electronic control device 3 is provided with a microcomputer 10, a watchdog timer part 25 and a stand-by RAM 29. The watchdog timer part 25 includes a timer 28 to be cleared by a watchdog pulse from the microcomputer 10 and a reset processing part 27 for resetting the microcomputer 10 when a count value of the timer 28 reaches a reset threshold value V<SB>R</SB>. The electronic control device 3 is provided with a writing control means 24 for canceling writing in the stand-by RAM 29 when the count value of the timer 28 reaches a prescribed writing control threshold value V<SB>W</SB>and executing writing in the stand-by RAM 29 when the count value does not reach the threshold value V<SB>W</SB>, in relation to a writing request in the stand-by RAM 29. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、電子制御装置に係り、特にマイクロコンピュータの暴走時にこれをリセットするためのウォッチドッグタイマを備えた電子制御装置に関するものである。また、本発明は、かかる電子制御装置におけるメモリへの書込み方法に関するものでもある。   The present invention relates to an electronic control device, and more particularly to an electronic control device including a watchdog timer for resetting a microcomputer when the microcomputer runs away. The present invention also relates to a method for writing to a memory in such an electronic control device.

マイクロコンピュータ(以下、適宜マイコンと略する)により制御される電子機器においては、ノイズ等の影響によりプログラムが暴走することがある。マイコンが暴走した場合には、マイコンをリセットするなどの対策がなされており(例えば特許文献1参照)、このようなマイコン暴走時のリセット制御装置としてはウォッチドッグタイマが知られている。このウォッチドッグタイマは、マイコンから所定の周期で出力されるように構成されたパルスを監視し、このパルスの周期性の異常からマイコンの暴走(異常)を検出し、暴走を検出した場合にマイコンをリセットするものである(例えば特許文献2参照)。   In an electronic device controlled by a microcomputer (hereinafter abbreviated as a microcomputer as appropriate), a program may run away due to the influence of noise or the like. When the microcomputer runs away, a countermeasure such as resetting the microcomputer is taken (for example, refer to Patent Document 1), and a watchdog timer is known as a reset control device for such a microcomputer runaway. This watchdog timer monitors pulses that are configured to be output from the microcomputer at a predetermined cycle, detects microcomputer runaway (abnormality) from the periodic abnormality of this pulse, and detects a runaway microcomputer. Is reset (see, for example, Patent Document 2).

また、多くの電子制御装置(Electronic Control Unit:ECU)においては、動作中に様々な制御データ(例えば車両用ECUにあっては車両の経年変化を通じて蓄積された燃焼噴射のタイミングデータなど)がRAM(Random Access Memory)やEEPROM(Electrically Erasable Programmable Read-Only Memory)などのメモリに書き込まれ、保存されている(例えば特許文献3参照)。これらの制御データは制御中に適宜参照され、最適な制御のために利用されている。   In many electronic control units (ECUs), various control data (for example, timing data of combustion injection accumulated through aging of a vehicle in a vehicle ECU) is stored in a RAM during operation. (Random Access Memory) and EEPROM (Electrically Erasable Programmable Read-Only Memory) and the like are written and stored (see, for example, Patent Document 3). These control data are referred to as appropriate during the control and are used for optimal control.

ここで、上述したメモリにデータを書き込む際には、保存すべきデータに加えて、このデータの信頼性を保証するための冗長データも保存データとともにメモリに書き込まれることがある。例えば、図1(a)に示されるように、「0x01」というデータをRAM500に書き込む場合、「0x01」のミラー値(逆数)である「0xFE」も「0x01」とともにRAM500に書き込まれる。車両用の電子制御装置では、イグニッションスイッチがオンになったときや所定の時間間隔で、RAM500に保存されたデータの整合性(すなわち保存されたデータとそれに対応するミラー値が正しく保存されているか)がチェックされ、データが破壊されていると判断された場合には、RAM500の初期化(リフレッシュ)が行われる。   Here, when data is written to the memory described above, in addition to the data to be stored, redundant data for ensuring the reliability of the data may be written to the memory together with the stored data. For example, as shown in FIG. 1A, when data “0x01” is written to the RAM 500, “0xFE”, which is a mirror value (reciprocal) of “0x01”, is also written to the RAM 500 together with “0x01”. In the vehicle electronic control device, when the ignition switch is turned on or at a predetermined time interval, the consistency of the data stored in the RAM 500 (that is, whether the stored data and the corresponding mirror value are stored correctly). ) Is checked and if it is determined that the data is destroyed, the RAM 500 is initialized (refreshed).

しかしながら、上述したウォッチドッグタイマを有する電子制御装置の場合には以下のような問題が生じる。すなわち、メモリにデータを書き込んでいる途中でマイコンが暴走すると、ウォッチドッグタイマがそれを検出しマイコンをリセットしてしまう。この場合には、データの書込みが途中で中断され、メモリにデータが正しく書き込まれないおそれがある。例えば、図1(b)に示されるように、データ「0x01」の書込み処理中にマイコンが暴走した場合、RAM500にミラー値「0xFE」を書き込む前にウォッチドッグタイマによりマイコンがリセットされてしまう場合がある。この場合には、ミラー値「0xFE」がRAM500に書き込まれず、RAM500に保存されたデータ「0x01」に対応するミラー値が不定値になってしまう。このため、データの整合性のチェックにおいて、保存されたデータが破壊されていると判断され、RAM500のデータ内容が初期化され失われてしまう。この場合の初期化はRAM500のすべての領域に対して行われるため、1つのデータが破壊されると破壊されていないデータまでも初期化されてしまう。   However, the following problems arise in the case of the electronic control device having the above-described watchdog timer. That is, if the microcomputer runs out of control while data is being written to the memory, the watchdog timer detects it and resets the microcomputer. In this case, data writing may be interrupted and data may not be correctly written to the memory. For example, as shown in FIG. 1B, when the microcomputer runs out of control during the writing process of the data “0x01”, the microcomputer is reset by the watchdog timer before the mirror value “0xFE” is written in the RAM 500. There is. In this case, the mirror value “0xFE” is not written to the RAM 500, and the mirror value corresponding to the data “0x01” stored in the RAM 500 becomes an indefinite value. For this reason, in the data consistency check, it is determined that the stored data is destroyed, and the data contents of the RAM 500 are initialized and lost. Since initialization in this case is performed on all areas of the RAM 500, even if one data is destroyed, even undestructed data is initialized.

特開平4−55901号公報Japanese Patent Laid-Open No. 4-55901 特開2003−97345号公報JP 2003-97345 A 特開2002−195094号公報JP 2002-195094 A

本発明は、このような従来技術の問題点に鑑みてなされたもので、メモリへの書込み処理とウォッチドッグタイマによるリセット処理とが同時に生じることによるデータの喪失を防止し、メモリに保存されるデータの信頼性を向上することができる電子制御装置を提供することを第1の目的とする。   The present invention has been made in view of such problems of the prior art, and prevents data loss due to simultaneous occurrence of write processing to the memory and reset processing by the watchdog timer, and is stored in the memory. A first object is to provide an electronic control device capable of improving the reliability of data.

また、本発明は、メモリへの書込み処理とマイクロコンピュータのリセット処理とが同時に生じることを防止して、データの喪失の防止とデータの信頼性の向上を実現することができるメモリへの書込み方法を提供することを第2の目的とする。   Further, the present invention prevents a data write process and a microcomputer reset process from occurring at the same time, thereby preventing data loss and improving data reliability. The second object is to provide the above.

かかる目的を達成するために本発明の電子制御装置は、マイクロコンピュータから出力されるウォッチドッグパルスによりクリアされるタイマと、前記タイマのカウント値が所定のリセット閾値に達したときに前記マイクロコンピュータの動作が異常であると判断して該マイクロコンピュータをリセットするリセット部とを有するウォッチドッグタイマ部と、データを記憶するメモリと、前記メモリへの書込み要求に対して、前記タイマのカウント値が前記リセット閾値に達するまでに該メモリへの書込みを完了することができる範囲内で設定された書込み制御閾値に前記タイマのカウント値が達しているか否かを判断し、前記書込み制御閾値に達していない場合には前記メモリへの書込みを実行し、前記書込み制御閾値に達している場合には前記メモリへの書込みをキャンセルする書込み制御を実行する書込み制御手段と、を備える構成としている。   In order to achieve such an object, an electronic control device of the present invention includes a timer that is cleared by a watchdog pulse output from a microcomputer, and a microcomputer that has a count value of the timer that reaches a predetermined reset threshold. In response to a watchdog timer unit having a reset unit that determines that the operation is abnormal and resets the microcomputer, a memory that stores data, and a write request to the memory, the count value of the timer is It is determined whether or not the count value of the timer has reached the write control threshold set within a range in which writing to the memory can be completed before reaching the reset threshold, and the write control threshold has not been reached. If the write to the memory is executed and the write control threshold is reached It has a configuration comprising a write control means for performing write control to cancel the writing to the memory.

本発明によれば、メモリへのデータの書込み要求があっても、メモリにデータを書き込んでいる最中にウォッチドッグタイマ部によるマイクロコンピュータのリセットが起こる可能性がある場合には、書込み制御手段によりデータの書込みがキャンセルされる。したがって、データ書込み中にマイクロコンピュータのリセットが起きることによるデータの破壊を防止することができ、メモリに保存されたデータの信頼性を高めることができる。   According to the present invention, even if there is a request to write data to the memory, if there is a possibility that the microcomputer is reset by the watchdog timer unit while writing the data to the memory, the write control means This cancels the data writing. Accordingly, it is possible to prevent the data from being destroyed due to the resetting of the microcomputer during the data writing, and to improve the reliability of the data stored in the memory.

上記電子制御装置において、前記記書込み制御閾値を前記範囲内の任意の値に設定する書込み設定手段をさらに備えていてもよい。
これにより、メモリに対するデータの書込み制御を必要に応じて調整することが容易になる。
The electronic control device may further include write setting means for setting the write control threshold value to an arbitrary value within the range.
This makes it easy to adjust the data write control to the memory as necessary.

上記電子制御装置において、前記書込み制御手段は、前記書込み要求のあったデータが冗長データを含むデータであるか否かを判定し、前記冗長データを含むデータの場合には前記書込み制御を実行し、前記冗長データを含まないデータの場合には書込み制御を行わずに前記メモリへの書込みを実行するとよい。
これにより、冗長データを含むデータに対しては、データの信頼性を高めることができ、冗長データを含まないデータに対しては、メモリへのデータの書込みに遅延を生じさせない。
In the electronic control device, the write control means determines whether or not the data requested to be written is data including redundant data, and executes the write control when the data includes redundant data. In the case of data that does not include the redundant data, it is preferable to perform writing to the memory without performing write control.
As a result, the reliability of data can be improved for data including redundant data, and no delay occurs in writing data to the memory for data not including redundant data.

本発明のメモリへの書込み方法は、マイクロコンピュータから出力されるウォッチドッグパルスによりタイマを繰り返しクリアし、前記タイマのカウント値が所定のリセット閾値に達したときに前記マイクロコンピュータの動作が異常であると判断して該マイクロコンピュータをリセットするウォッチドッグタイマ部を備えた電子制御装置におけるメモリへの書込み方法であって、前記タイマのカウント値が前記リセット閾値に達するまでに前記メモリへの書込みを完了することができる範囲内で書込み制御閾値を設定するステップと、前記メモリへの書込み要求に対して、前記タイマのカウント値が前記書込み制御閾値に達しているか否かを判定するステップと、前記書込み制御閾値に達していない場合には前記メモリへの書込みを実行し、前記書込み制御閾値に達している場合には前記メモリへの書込みをキャンセルする書込み制御を実行するステップと、を有している。   According to the method of writing to the memory of the present invention, the timer is repeatedly cleared by a watchdog pulse output from the microcomputer, and the operation of the microcomputer is abnormal when the count value of the timer reaches a predetermined reset threshold value. A method of writing to a memory in an electronic control unit having a watchdog timer unit that determines that the microcomputer is reset, and completes the writing to the memory before the count value of the timer reaches the reset threshold value Setting a write control threshold within a range that can be performed, determining whether a count value of the timer has reached the write control threshold in response to a write request to the memory, and the write If the control threshold is not reached, write to the memory. If it has reached the write control threshold has, executing a write control for canceling the writing to the memory.

上記判定するステップは、前記書込み要求のあったデータが冗長データを含むデータであるか否かを判定するステップを有し、前記冗長データを含むデータの場合には前記書込み制御のステップを実行し、前記冗長データを含まないデータの場合には前記書込み制御のステップを行わずに前記メモリへの書込みを実行するとよい。   The determining step includes a step of determining whether or not the data requested to be written is data including redundant data. If the data includes redundant data, the write control step is executed. In the case of data that does not include the redundant data, it is preferable to perform writing to the memory without performing the write control step.

上述したように、本発明によれば、メモリへのデータの書込み要求があっても、メモリにデータを書き込んでいる最中にウォッチドッグタイマ部によるマイクロコンピュータのリセットが起こる可能性がある場合には、書込み制御手段によりデータの書込みがキャンセルされる。したがって、データ書込み中にマイクロコンピュータのリセットが起きることによるデータの破壊を防止することができ、メモリに保存されたデータの信頼性を高めることができる。   As described above, according to the present invention, even when there is a request to write data to the memory, there is a possibility that the microcomputer may be reset by the watchdog timer unit while the data is being written to the memory. Is canceled by the writing control means. Accordingly, it is possible to prevent the data from being destroyed due to the resetting of the microcomputer during the data writing, and to improve the reliability of the data stored in the memory.

以下、添付図面を参照しながら本発明の好適な実施例を説明する。   Hereinafter, preferred embodiments of the present invention will be described with reference to the accompanying drawings.

以下、第1実施例の車両用電子制御装置について説明する。なお、以下では、本発明を車両用電子制御装置に適用した例について説明するが、本発明は車両用電子制御装置に限られるものではなく、データを書き込むメモリを有しているその他の用途に用いられる電子制御装置にも適用できるものである。   Hereinafter, the vehicle electronic control device of the first embodiment will be described. In the following, an example in which the present invention is applied to an electronic control device for a vehicle will be described. However, the present invention is not limited to an electronic control device for a vehicle, and may be used for other applications having a memory for writing data. The present invention can also be applied to the electronic control device used.

図2は、本発明の第1実施例における車両用電子制御システム1の構成を示すブロック図である。図2に示されるように、この車両用電子制御システム1は、複数の電子制御装置(ECU)を備えている。図2に示す例では、車両用電子制御システム1は、エンジンの燃料噴射制御を行う電子制御式燃料噴射(Electronic Fuel Injection:EFI)用ECU2と、電力の供給や充電を制御するパワーマネジメントECU3と、エアバッグの展開を制御するエアバックECU4と、タコメータをはじめとする各種メータを制御するメータECU5と、ドアロックやパワーウィンドウなどを制御するボディECU6と、燃費向上やガス排気量の低減のためにエンジンを制御するエコランECU7と、車内への侵入や車両の傾斜などを検知し警報を発するためのセキュリティECU8とを含んでいる。   FIG. 2 is a block diagram showing the configuration of the vehicle electronic control system 1 according to the first embodiment of the present invention. As shown in FIG. 2, the vehicle electronic control system 1 includes a plurality of electronic control units (ECUs). In the example shown in FIG. 2, the vehicle electronic control system 1 includes an electronic fuel injection (EFI) ECU 2 that performs fuel injection control of the engine, and a power management ECU 3 that controls power supply and charging. An airbag ECU 4 that controls the deployment of the airbag, a meter ECU 5 that controls various meters such as a tachometer, a body ECU 6 that controls a door lock, a power window, and the like; In addition, an eco-run ECU 7 for controlling the engine and a security ECU 8 for detecting an intrusion into the vehicle, a vehicle inclination, and the like and issuing an alarm are included.

図3は、パワーマネジメントECU3の構成を示すブロック図である。図3に示されるように、パワーマネジメントECU3は、マイクロコンピュータ(マイコン)10と、マイコン10への電源供給を制御する電源回路12と、例えばバッテリの温度、電流、エンジン回転数、車速、トランスミッションの状態などを示す各種センサ信号の信号レベルを所望のレベルに変換してマイコン10に入力する信号レベル変換器14と、例えばヒータやファンのリレーのオンオフ信号、CAN(Controller Area Network)用データをはじめとするマイコン10からの出力を外部に出力する出力回路16とを備えている。   FIG. 3 is a block diagram showing the configuration of the power management ECU 3. As shown in FIG. 3, the power management ECU 3 includes a microcomputer 10, a power supply circuit 12 that controls power supply to the microcomputer 10, and, for example, battery temperature, current, engine speed, vehicle speed, and transmission. The signal level converter 14 that converts the signal level of various sensor signals indicating the state and the like into a desired level and inputs the signal to the microcomputer 10, for example, heater / fan relay ON / OFF signals, CAN (Controller Area Network) data, and the like And an output circuit 16 for outputting the output from the microcomputer 10 to the outside.

電源回路12とバッテリ18との間には、イグニッションキー(図示せず)の操作により開閉されるイグニッションスイッチIGSWが設けられている。このイグニッションスイッチIGSWがオンされると、バッテリ18から供給される電圧が電源回路12で所定の電圧に調整されてマイコン10に供給され、マイコン10が起動する。   An ignition switch IGSW that is opened and closed by operating an ignition key (not shown) is provided between the power supply circuit 12 and the battery 18. When the ignition switch IGSW is turned on, the voltage supplied from the battery 18 is adjusted to a predetermined voltage by the power supply circuit 12, supplied to the microcomputer 10, and the microcomputer 10 is activated.

マイコン10は、ソフトウェア制御によって実現されるソフトウェア処理部21と、制御処理プログラムの暴走を検知しマイコン10をリセットするウォッチドッグタイマ部25と、各種制御データを保存するスタンバイRAM29とを含んでいる。なお、本実施例では、ウォッチドッグタイマ部25がマイコン10の内部に設けられているが、ウォッチドッグタイマ部25をマイコン10の外部に設けてもよい。   The microcomputer 10 includes a software processing unit 21 realized by software control, a watchdog timer unit 25 that detects a runaway control processing program and resets the microcomputer 10, and a standby RAM 29 that stores various control data. In this embodiment, the watchdog timer unit 25 is provided inside the microcomputer 10, but the watchdog timer unit 25 may be provided outside the microcomputer 10.

ソフトウェア処理部21は、図4に示すハードウェアによって実現される。ECUによる制御処理を実現するためのプログラムや後述するメモリの書込み制御のためのプログラムなどが格納されたROM32と、ROM32に格納されたプログラムを読み込んで実行する中央処理装置(CPU)31と、プログラムを実行する際に使用される一時的なデータを保存するRAM33と、データの入出力部34などから構成される。   The software processing unit 21 is realized by the hardware shown in FIG. A ROM 32 storing a program for realizing control processing by the ECU and a program for controlling writing of a memory to be described later, a central processing unit (CPU) 31 for reading and executing the program stored in the ROM 32, and a program Are composed of a RAM 33 for storing temporary data used when executing the above, a data input / output unit 34, and the like.

イグニッションスイッチIGSWがオンにされると、マイコン10が起動し、ROM32に格納されたプログラムがRAM33にロードされCPU31により実行される。このプログラムによって、信号レベル変換器14からの信号等に基づいて所定の制御処理が行われる。また、この制御処理中に様々な制御データが学習され、これらの学習によって得られた制御データはスタンバイRAM29に保存され、その後の制御処理に利用される。
また、ROM32に格納されたプログラムのCPU31による演算によって、図3に示す通知パルス出力手段22、書込み設定手段23、書込み制御手段24が構成される。
通知パルス出力手段22は、後述するウォッチドッグタイマ部25にCPU31が正常に動していることを通知するパルスを出力する手段である。
書込み設定手段23は、後述する書込み制御閾値Vを設定する。また、書込み制御手段24は、スタンバイRAM29へのデータ書込みを制御する。これらの手段の詳細については後述する。
When the ignition switch IGSW is turned on, the microcomputer 10 is activated, and the program stored in the ROM 32 is loaded into the RAM 33 and executed by the CPU 31. By this program, a predetermined control process is performed based on the signal from the signal level converter 14 and the like. Various control data are learned during the control process, and the control data obtained by the learning is stored in the standby RAM 29 and used for the subsequent control process.
Further, the notification pulse output means 22, the write setting means 23, and the write control means 24 shown in FIG. 3 are configured by calculation by the CPU 31 of the program stored in the ROM 32.
The notification pulse output means 22 is a means for outputting a pulse for notifying the later-described watchdog timer section 25 that the CPU 31 is operating normally.
Writing setting means 23 sets the write control threshold V W to be described later. The write control unit 24 controls data writing to the standby RAM 29. Details of these means will be described later.

ウォッチドックタイマ部25は、通知パルス出力手段22から出力される通知パルス(ウォッチドッグパルス)を入力するパルス入力部26と、制御処理プログラムが暴走した場合にCPU31にリセット信号を出力しマイコン10をリセットするリセット処理部27と、時間の経過とともにカウントアップするタイマ28とを有している。
マイコン10が正常に動作しているときには、通知パルスが一定の周期でパルス入力部26に入力され、リセット処理部27によってタイマ28が一定の周期でクリアされる。
The watchdog timer unit 25 inputs a notification pulse (watchdog pulse) output from the notification pulse output means 22, and outputs a reset signal to the CPU 31 when the control processing program runs out of control. A reset processing unit 27 for resetting and a timer 28 for counting up as time elapses are provided.
When the microcomputer 10 is operating normally, a notification pulse is input to the pulse input unit 26 at a constant cycle, and the timer 28 is cleared at a constant cycle by the reset processing unit 27.

スタンバイRAM29には、バッテリ18から常時電圧が供給され、これにより、イグニッションスイッチIGSWの操作とは関係なく、スタンバイRAM29に保存された制御データが保持されるようになっている。また、マイコン10の外部には、スタンバイRAM29の初期化(リフレッシュ)に用いるデータを格納したEEPROM30が設けられており、スタンバイRAM29の初期化時には、EEPROM30からのデータがソフトウェアの制御によって書き込まれるようになっている。   The standby RAM 29 is always supplied with a voltage from the battery 18, whereby the control data stored in the standby RAM 29 is held regardless of the operation of the ignition switch IGSW. Further, an EEPROM 30 that stores data used for initialization (refresh) of the standby RAM 29 is provided outside the microcomputer 10, and when the standby RAM 29 is initialized, data from the EEPROM 30 is written under software control. It has become.

図5は、ウォッチドッグタイマ部25のタイマ28のカウント値の推移を示すタイミングチャートである。図5に示されるように、マイコン10の処理負荷が低く制御処理プログラムが正常に動作しているときは、通知パルスが一定の周期でウォッチドッグタイマ部25に入力され、リセット処理部27によってタイマ28が一定の周期でクリアされる。
一方、マイコン10の処理負荷が高くなると、ソフトウェア処理部21は通知パルスを所定の周期で出力できなくなり、タイマ28のカウント値が増え続ける。ここで、ウォッチドッグタイマ部25には、マイコン10のリセットの必要性を判断する基準となるリセット閾値V(図5参照)が設定されており、タイマ28のカウント値がリセット閾値Vに達すると、マイコン10の動作が異常であると判断し、リセット処理部27からリセット信号がCPU31に出力される。これによりマイコン10がリセットされる。なお、リセットされたマイコン10は一般的に初期化処理から再スタートされる。
FIG. 5 is a timing chart showing the transition of the count value of the timer 28 of the watchdog timer unit 25. As shown in FIG. 5, when the processing load of the microcomputer 10 is low and the control processing program is operating normally, a notification pulse is input to the watchdog timer unit 25 at a constant cycle, and the timer 27 is reset by the reset processing unit 27. 28 is cleared at regular intervals.
On the other hand, when the processing load of the microcomputer 10 increases, the software processing unit 21 cannot output the notification pulse at a predetermined cycle, and the count value of the timer 28 continues to increase. Here, the watchdog timer section 25, the reset threshold V R as a criterion for determining the need for resetting the microcomputer 10 (see FIG. 5) is set, the count value of the timer 28 is reset threshold V R When it reaches, the operation of the microcomputer 10 is determined to be abnormal, and a reset signal is output from the reset processing unit 27 to the CPU 31. Thereby, the microcomputer 10 is reset. Note that the reset microcomputer 10 is generally restarted from the initialization process.

しかしながら、スタンバイRAM29にデータを書き込んでいる最中にウォッチドッグタイマ部25によるマイコン10のリセットが起こると、スタンバイRAM29に保存されたデータが破壊される恐れがある。   However, if the microcomputer 10 is reset by the watchdog timer unit 25 while data is being written to the standby RAM 29, the data stored in the standby RAM 29 may be destroyed.

このような問題を解決するために本実施例では、スタンバイRAM29へのデータ書込み中にウォッチドッグタイマ部25によるマイコン10のリセットが起きないように、スタンバイRAM29へのデータ書込みを書込み制御手段24により制御している。   In order to solve such a problem, in this embodiment, the write control means 24 writes data to the standby RAM 29 so that the microcomputer 10 is not reset by the watchdog timer unit 25 during the data write to the standby RAM 29. I have control.

具体的には、図6に示されるように、タイマ28のカウント値に対して、タイマ28のカウント値がリセット閾値Vに達するまでにスタンバイRAM29への書込みを完了することができる範囲内で書込み制御閾値Vが設定される。書込み制御閾値Vよりも小さいカウント値のときにはスタンバイRAM29へのデータ書込みが許可され、書込み制御閾値Vよりも大きいカウント値のときにはスタンバイRAM29への書込みが禁止される。すなわち、図6に示されるデータ書込み禁止期間Pがデータ書込み処理に必要とされる時間Wよりも大きくなるように書込み制御閾値Vが設定される。この書込み制御閾値Vの設定は書込み設定手段23により行われ、書込み設定手段23は書込み制御閾値Vを上記範囲内の任意の値に設定(または変更)することができるようになっている。 Specifically, as shown in FIG. 6, the count value of the timer 28, until the count value of the timer 28 reaches the reset threshold V R in a range capable of completing the write to the standby RAM29 The write control threshold value VW is set. When the smaller count value than the write control threshold V W are permitted data writing to the standby RAM 29, writing to the standby RAM 29 when the larger count than the write control threshold V W is prohibited. That is, the write control threshold value V W is set so that the data write prohibition period P shown in FIG. 6 is longer than the time W required for the data write process. The setting of the write control threshold value V W is performed by the write setting unit 23, and the write setting unit 23 can set (or change) the write control threshold value V W to an arbitrary value within the above range. .

図7に示すフローチャートを参照しながら、書込み制御手段24の処理手順を説明する。
スタンバイRAM29にデータの書込み要求があると、書込み制御手段24はまずウォッチドッグタイマ部25のタイマ28のカウント値を取得し(ステップS1)、取得したカウント値と上述の書込み制御閾値Vとを比較する(ステップS2)。上記書込み制御閾値Vよりもカウント値が小さいときには(ステップS2/NO)、スタンバイRAM29へのデータ書込みが完了するまでにカウント値がリセット閾値Vに達することはない。したがってマイコン10のリセットが起こることがないので、書込み制御手段24は通常通りにデータをスタンバイRAM29に書き込む(ステップS3)。一方、書込み制御閾値Vよりもカウント値が大きい場合には(ステップS2/YES)、スタンバイRAM29にデータを書き込んでいる最中にウォッチドッグタイマ部25によるマイコン10のリセットが起こる可能性があるため、書込み制御手段24はスタンバイRAM29への書込みをキャンセルし、そのまま書込み処理を終了する。
The processing procedure of the write control means 24 will be described with reference to the flowchart shown in FIG.
When there is a data write request in the standby RAM 29, the write control means 24 first acquires the count value of the timer 28 of the watchdog timer unit 25 (step S1), and uses the acquired count value and the above-described write control threshold value V W. Compare (step S2). When the count value is smaller than the write control threshold V W (step S2 / NO), it does not count until the data writing is completed to the standby RAM29 reaches the reset threshold V R. Therefore, since the microcomputer 10 is not reset, the write control means 24 writes data to the standby RAM 29 as usual (step S3). On the other hand, when the count value than the write control threshold V W is large, there may occur the reset (step S2 / YES), the microcomputer 10 by the watchdog timer section 25 in the middle of writing the data to the standby RAM29 Therefore, the writing control means 24 cancels writing to the standby RAM 29 and ends the writing process as it is.

このように、スタンバイRAM29へのデータの書込み要求があっても、スタンバイRAM29にデータを書き込んでいる最中にウォッチドッグタイマ部25によるマイコン10のリセットが起こる可能性がある場合には、書込み制御手段24によりデータの書込みがキャンセルされる。従って、データ書込み中のマイコン10のリセットによるデータの破壊を防止することができ、スタンバイRAM29に保存されたデータの信頼性を高めることができる。   As described above, even when there is a request for writing data to the standby RAM 29, if there is a possibility that the microcomputer 10 is reset by the watchdog timer unit 25 while data is being written to the standby RAM 29, the write control is performed. The data writing is canceled by the means 24. Therefore, it is possible to prevent the destruction of data due to the reset of the microcomputer 10 during data writing, and the reliability of data stored in the standby RAM 29 can be improved.

データの書込みに際して、保存すべきデータとともにこのデータの信頼性を保証する冗長データ(例えばミラー値)も書き込まれるような場合には、保存すべきデータの書込みと冗長データの書込みとの間にマイコン10のリセットが生じることを防止する必要があるため、上述した書込み制御が特に必要となるが、冗長データを有していない単一のデータであればマイコン10のリセットによりデータが破壊される可能性が低いため、上述した書込み制御を行わなくてもよい場合がある。このような場合には、以下に述べる本発明の第2実施例を適用することができる。   When writing data, redundant data (for example, a mirror value) that guarantees the reliability of the data is written together with the data to be saved, the microcomputer between the data to be saved and the redundant data is written. Since it is necessary to prevent 10 resets from occurring, the above-described write control is particularly necessary. However, if the single data does not have redundant data, the data can be destroyed by resetting the microcomputer 10 In some cases, it is not necessary to perform the write control described above. In such a case, the second embodiment of the present invention described below can be applied.

図8は、本発明の第2の実施例に係るパワーマネジメントECU103の構成を示すブロック図である。図8に示すパワーマネジメントECU103のマイコン110においては、書込み要求のあったデータが書込み制御を行う必要のあるデータか否かを判断するデータ判断手段140aが書込み制御手段140に設けられている。その他の構成は第1実施例と同様であるので、以下では書込み制御手段140を中心として説明し、その他の構成についての説明を省略する。   FIG. 8 is a block diagram showing the configuration of the power management ECU 103 according to the second embodiment of the present invention. In the microcomputer 110 of the power management ECU 103 shown in FIG. 8, the write control means 140 is provided with data judgment means 140a for judging whether or not the data requested to be written is data that needs to be written. Since the other configuration is the same as that of the first embodiment, the following description will focus on the write control unit 140, and description of the other configuration will be omitted.

図9は、本実施例における書込み制御手段140の処理手順を示すフローチャートである。スタンバイRAM29に対するデータの書込み要求があると、この書込み要求のあったデータが書込み制御を行う必要のあるデータであるかを書込み制御手段140のデータ判断手段140aによって判断する(ステップS11)。ここで、書込み制御を行う必要のあるデータとしては、上述したように、保存すべきデータに加えてこのデータの信頼性を保証するミラー値などの冗長データを有するデータなどが挙げられる。   FIG. 9 is a flowchart showing the processing procedure of the write control means 140 in this embodiment. When there is a data write request to the standby RAM 29, the data determination unit 140a of the write control unit 140 determines whether the data for which the write request has been made is data that needs to be subjected to write control (step S11). Here, as described above, the data that needs to be subjected to write control includes data having redundant data such as a mirror value that guarantees the reliability of the data in addition to the data to be stored.

書込み要求のあったデータが書込み制御を行う必要のあるデータであれば、上述した第1実施例のステップS1以降の処理が行われる。すなわち、書込み制御手段140によりウォッチドッグタイマ部25のタイマ28のカウント値が取得され(ステップS12)、取得したカウント値と書込み制御閾値Vとが比較される(ステップS13)。上記書込み制御閾値Vよりもカウント値が小さいときには(ステップS13/NO)、書込み制御手段140によって通常通りにデータがスタンバイRAM29に書き込まれる(ステップ14)。また、書込み制御閾値Vよりもカウント値が大きい場合には(ステップS13/YES)、書込み制御手段140によるスタンバイRAM29への書込みがキャンセルされる。 If the data requested to be written is data that needs to be subjected to write control, the processing after step S1 in the first embodiment described above is performed. That is, the write control unit 140 the count value of the watchdog timer section 25 of the timer 28 is obtained by (step S12), the are compared with acquired count value with a write control threshold V W (step S13). When the count value is smaller than the write control threshold V W (step S13 / NO), the data in the usual way by a write control means 140 is written into the standby RAM 29 (step 14). Further, when the count value than the write control threshold V W is larger (step S13 / YES), the writing to the standby RAM29 by the write control unit 140 is canceled.

一方、書込み要求のあったデータが書込み制御を行う必要のないデータである場合には、上述したステップ12〜13の処理は行われず、そのままスタンバイRAM29にデータが書き込まれる(ステップS14)。   On the other hand, if the data requested to be written is data that does not need to be written, the processing in steps 12 to 13 described above is not performed, and the data is written as it is to the standby RAM 29 (step S14).

このように、本実施例では、書込み時のリセットによりデータの破壊が起きやすいデータ(例えばミラー値などの冗長データを有するデータ)についてのみ書込み制御を行い、その他のデータについては書込み制御を行うことなく通常の書込み動作を行うことができる。したがって、すべてのデータについて書込み制御をする場合に比べてマイコンの処理負荷が軽減される。   As described above, in this embodiment, write control is performed only for data (for example, data having redundant data such as a mirror value) that is likely to be destroyed by reset at the time of write, and write control is performed for other data. Normal write operation can be performed. Therefore, the processing load on the microcomputer is reduced as compared with the case where write control is performed for all data.

本実施例は、上述した第1実施例をハードウェアによって実現した実施例である。
図10を参照しながら本実施例の構成を説明する。図10に示すように、本実施例は、クロック発生部120で発生するクロックを分周器121で分周して所定周波数のクロックとし、ウォッチドックタイマカウンタ(以下、WDTカウンタと表記する)122でこのクロックをカウントしている。このWDTカウンタ122には、第1レジスタ123及び第2レジスタ128の保持する設定値が入力される。
第1レジスタ123からWDTカウンタ122には、リセット閾値保持部124の保持する上述したリセット閾値(V)が出力される。第2レジスタ128からWDTカウンタ122には、書込み制御閾値保持部129の保持する上述した書込み制御閾値(V)が出力される。
WDTカウンタ122は、書込み制御閾値(V)のクロックをカウントすると、第2レジスタ128に所定の信号を出力する。所定の信号を入力した第2レジスタ128は、ON保留フラグ130をONに設定する。このON保留フラグ130をONにすることで、第2レジスタ128からSRAM29にデータの書込み禁止信号が出力される。ソフトウェア処理部127の制御によってSRAM29へのデータ書込みが指示されても、書込み禁止信号がSRAM29に出力されているので、SRAM29へのデータ書込みは実行されない。
This embodiment is an embodiment in which the first embodiment described above is realized by hardware.
The configuration of this embodiment will be described with reference to FIG. As shown in FIG. 10, in this embodiment, a clock generated by the clock generator 120 is divided by a frequency divider 121 to obtain a clock having a predetermined frequency, and a watchdog timer counter (hereinafter referred to as a WDT counter) 122 is used. This clock is counted. The WDT counter 122 receives the set values held by the first register 123 and the second register 128.
The reset threshold (V R ) held by the reset threshold holding unit 124 is output from the first register 123 to the WDT counter 122. The above-described write control threshold value (V W ) held by the write control threshold value holding unit 129 is output from the second register 128 to the WDT counter 122.
The WDT counter 122 outputs a predetermined signal to the second register 128 when counting the clock of the write control threshold (V W ). The second register 128 that has input a predetermined signal sets the ON hold flag 130 to ON. By turning on the ON hold flag 130, a data write prohibition signal is output from the second register 128 to the SRAM 29. Even if data writing to the SRAM 29 is instructed by the control of the software processing unit 127, the data write to the SRAM 29 is not executed because the write inhibit signal is output to the SRAM 29.

また、WDTカウンタ122は、リセット閾値(V)のクロックをカウントすると、図10に示すスイッチ126の設定に従って、マイコン10のリセット端子にリセット信号を出力するか、又はソフトウェア処理部127へ割込み信号を出力する。第1レジスタ123には、マイコン10をリセットするか、ソフトウェアへの割込み信号を出力するかを設定するリセット又は割込み設定保持部125が用意されており、第1レジスタ123は、リセット又は割込み設定保持部125の設定に従って、スイッチ126を設定する。
なお、リセット閾値保持部124、リセット又は割込み設定保持部125、書込み制御閾値保持部129の保持する設定情報は、ソフトウェア処理部127によって設定される。
Further, when the WDT counter 122 counts the clock of the reset threshold (V R ), it outputs a reset signal to the reset terminal of the microcomputer 10 or interrupt signal to the software processing unit 127 according to the setting of the switch 126 shown in FIG. Is output. The first register 123 is provided with a reset or interrupt setting holding unit 125 for setting whether to reset the microcomputer 10 or output an interrupt signal to software. The first register 123 holds a reset or interrupt setting. The switch 126 is set according to the setting of the unit 125.
The setting information held by the reset threshold holding unit 124, the reset or interrupt setting holding unit 125, and the write control threshold holding unit 129 is set by the software processing unit 127.

上述した実施例においては、パワーマネジメントECU3に本発明を適用した場合について説明したが、本発明はパワーマネジメントECUに限られるものではなく、他のECUにも適用できるものであることは言うまでもない。   In the above-described embodiments, the case where the present invention is applied to the power management ECU 3 has been described. However, it is needless to say that the present invention is not limited to the power management ECU and can be applied to other ECUs.

また、ECUが単一のマイコンを有する構成について説明したが、これに限られるものではない。例えば、ECUにメインマイコンとサブマイコンとを設け、これらのマイコンにより制御処理を分散して行うようにしてもよい。この場合において、上述したウォッチドッグタイマ部25は、メインマイコンの内部または外部、サブマイコンの内部または外部のいずれの場所に設けてもよい。   Moreover, although the configuration in which the ECU has a single microcomputer has been described, the present invention is not limited to this. For example, the ECU may be provided with a main microcomputer and a sub-microcomputer, and control processing may be performed by these microcomputers in a distributed manner. In this case, the above-described watchdog timer unit 25 may be provided in any location inside or outside the main microcomputer and inside or outside the sub-microcomputer.

また、上述した実施例では、タイマ28としてカウント値をカウントアップするカウントアップタイマを用い、このカウント値がリセット閾値V以上になるとマイコンをリセットするオーバーフロー型ウォッチドッグタイマ部を用いた例について説明したが、本発明に係るウォッチドッグタイマ部はオーバーフロー型に限られるものではない。例えば、図11に示されるように、タイマ28としてカウント値をカウントダウンするカウントダウンタイマを用い、このカウント値がリセット閾値V以下になるとマイコンをリセットするアンダーフロー型ウォッチドッグタイマ部にも用いることができる。なお、オーバーフロー型ウォッチドッグタイマ部を用いた場合には、「カウント値がリセット閾値に達する」というのはカウント値がリセット閾値以上になることを意味するが、アンダーフロー型ウォッチドッグタイマ部を用いた場合には、「カウント値がリセット閾値に達する」というのはカウント値がリセット閾値以下になることを意味する。
また、図12に示すようにリセット閾値Vとして上限値(図12に示すV(上限))と下限値(図12に示すV(下限))とを設けて範囲設定し、この設定範囲内でソフトウェア処理部21から通知パルスを入力した場合に、タイマ28をリセットし、設定範囲内でソフトウェア処理部21から通知パルスを入力できなかった場合にマイコンをリセットするウィンドーコンパレートタイプにも用いることもできる。
さらに、上述した実施例の書込み制御閾値(V)は、メモリに書き込むデータの大きさに応じて変更できる。
Further, in the embodiment described above, using a count-up timer which counts up the count value as the timer 28, an example of using an overflow-type watchdog timer to reset the microcomputer when the count value is equal to or larger than the reset threshold V R explanation However, the watchdog timer unit according to the present invention is not limited to the overflow type. For example, as shown in FIG. 11, using a countdown timer that counts down the count value as the timer 28, also it is used for underflow watchdog timer to reset the microcomputer when the count value falls below the reset threshold V R it can. When the overflow type watchdog timer unit is used, "the count value reaches the reset threshold value" means that the count value exceeds the reset threshold value, but the underflow type watchdog timer unit is used. In this case, “the count value reaches the reset threshold” means that the count value is equal to or less than the reset threshold.
In addition, the range set by providing the upper limit value as the reset threshold V R as shown in FIG. 12 lower limit value (V R (the upper limit) shown in FIG. 12) (V R shown in FIG. 12 (lower limit)), the setting When the notification pulse is input from the software processing unit 21 within the range, the timer 28 is reset, and when the notification pulse cannot be input from the software processing unit 21 within the setting range, the window comparator type that resets the microcomputer is also used. It can also be used.
Furthermore, the write control threshold value (V W ) of the above-described embodiment can be changed according to the size of data written to the memory.

これまで本発明の好ましい実施例について説明したが、本発明は上述の実施例に限定されず、その技術的思想の範囲内において種々異なる形態にて実施されてよいことは言うまでもない。
例えば、上述した実施例では、スタンバイRAMへのデータの保存時について説明してきたが、これ以外に、マイクロコンピュータに内蔵されたRAM、マイクロコンピュータの外部に設けられたRAM、マイクロコンピュータに内蔵されたEEPROM、マイクロコンピュータの外部に設けられたEEPROM、マイクロコンピュータに内蔵されたフラッシュROM、およびマイクロコンピュータの外部に設けられたフラッシュROMなど、種々のメモリに対して本発明を適用することができる。
Although the preferred embodiments of the present invention have been described so far, it is needless to say that the present invention is not limited to the above-described embodiments and may be implemented in various forms within the scope of the technical idea thereof.
For example, in the above-described embodiment, the description has been given of the case of storing data in the standby RAM. However, in addition to this, a RAM built in the microcomputer, a RAM provided outside the microcomputer, and a microcomputer built in the microcomputer. The present invention can be applied to various memories such as an EEPROM, an EEPROM provided outside the microcomputer, a flash ROM incorporated in the microcomputer, and a flash ROM provided outside the microcomputer.

図1(a)はRAMへのデータ書込み処理における動作を説明する模式図であり、図1(b)はRAMへのデータ書込み処理中にウォッチドッグタイマによるリセットが行われた場合の動作を説明する模式図である。FIG. 1A is a schematic diagram for explaining the operation in the data writing process to the RAM, and FIG. 1B shows the operation when the watchdog timer is reset during the data writing process to the RAM. It is a schematic diagram to do. 図2は、本発明の第1の実施例における車両用電子制御システムの構成を示すブロック図である。FIG. 2 is a block diagram showing the configuration of the vehicle electronic control system in the first embodiment of the present invention. 図3は、図2に示す車両用電子制御システムにおけるパワーマネジメントECUの構成を示すブロック図である。FIG. 3 is a block diagram showing a configuration of a power management ECU in the vehicle electronic control system shown in FIG. 図4は、パワーマネジメントECUのハードウェア構成を示す図である。FIG. 4 is a diagram illustrating a hardware configuration of the power management ECU. 図5は、図3に示すパワーマネジメントECUにおけるウォッチドッグタイマ部の動作を示すタイミングチャートである。FIG. 5 is a timing chart showing the operation of the watchdog timer unit in the power management ECU shown in FIG. 図6は、図3に示すウォッチドッグタイマ部の動作と書込み制御閾値との関係を示すタイミングチャートである。FIG. 6 is a timing chart showing the relationship between the operation of the watchdog timer unit shown in FIG. 3 and the write control threshold value. 図7は、図3に示すパワーマネジメントECUにおける書込み制御手段の処理を示すフローチャートである。FIG. 7 is a flowchart showing processing of the writing control means in the power management ECU shown in FIG. 図8は、本発明の第2実施例におけるパワーマネジメントECUの構成を示すブロック図である。FIG. 8 is a block diagram showing the configuration of the power management ECU in the second embodiment of the present invention. 図9は、図8に示すパワーマネジメントECUにおける書込み制御手段の処理を示すフローチャートである。FIG. 9 is a flowchart showing processing of the writing control means in the power management ECU shown in FIG. 図10は、図3又は図8のソフトウェア処理部をハードウェアにて構成した構成図である。FIG. 10 is a configuration diagram in which the software processing unit of FIG. 3 or FIG. 8 is configured by hardware. 図11は、アンダーフロー型ウォッチドッグタイマ部を本発明に適用した場合のタイミングチャートである。FIG. 11 is a timing chart when the underflow type watchdog timer unit is applied to the present invention. 図13は、ウィンドーコンパレートタイマ部を本発明に適用した場合のタイミングチャートである。FIG. 13 is a timing chart when the window comparator timer is applied to the present invention.

符号の説明Explanation of symbols

3、103 パワーマネジメントECU
10、110 マイクロコンピュータ
12 電源回路
14 信号レベル変換器
16 出力回路
18 バッテリ
21 ソフトウェア処理部
22 通知パルス出力手段
23 書込み設定手段
24、140 書込み制御手段
25 ウォッチドッグタイマ部
26 パルス入力部
27 リセット処理部
28 タイマ
29 SRAM
30 EEPROM
140a データ判断手段
IGSW イグニッションスイッチ
リセット閾値
書込み制御閾値
3, 103 Power management ECU
DESCRIPTION OF SYMBOLS 10,110 Microcomputer 12 Power supply circuit 14 Signal level converter 16 Output circuit 18 Battery 21 Software processing part 22 Notification pulse output means 23 Write setting means 24, 140 Write control means 25 Watchdog timer part 26 Pulse input part 27 Reset processing part 28 Timer 29 SRAM
30 EEPROM
140a data determination means IGSW ignition switch V R reset threshold V W write control threshold

Claims (5)

マイクロコンピュータから出力されるウォッチドッグパルスによりクリアされるタイマと、前記タイマのカウント値が所定のリセット閾値に達したときに前記マイクロコンピュータの動作が異常であると判断して該マイクロコンピュータをリセットするリセット部とを有するウォッチドッグタイマ部と、
データを記憶するメモリと、
前記メモリへの書込み要求に対して、前記タイマのカウント値が前記リセット閾値に達するまでに該メモリへの書込みを完了することができる範囲内で設定された書込み制御閾値に前記タイマのカウント値が達しているか否かを判断し、前記書込み制御閾値に達していない場合には前記メモリへの書込みを実行し、前記書込み制御閾値に達している場合には前記メモリへの書込みをキャンセルする書込み制御を実行する書込み制御手段と、
を備えたことを特徴とする電子制御装置。
A timer that is cleared by a watchdog pulse output from the microcomputer, and when the count value of the timer reaches a predetermined reset threshold value, the microcomputer determines that the operation of the microcomputer is abnormal and resets the microcomputer. A watchdog timer unit having a reset unit;
A memory for storing data;
In response to a write request to the memory, the count value of the timer is set to a write control threshold set within a range in which writing to the memory can be completed before the count value of the timer reaches the reset threshold. A write control that determines whether or not the write control threshold has been reached and executes writing to the memory if the write control threshold has not been reached, and cancels the write to the memory if the write control threshold has been reached Write control means for executing
An electronic control device comprising:
前記書込み制御閾値を上記範囲内の任意の値に設定する書込み設定手段をさらに備えたことを特徴とする請求項1記載の電子制御装置。   2. The electronic control device according to claim 1, further comprising write setting means for setting the write control threshold value to an arbitrary value within the range. 前記書込み制御手段は、前記書込み要求のあったデータが冗長データを含むデータであるか否かを判定し、前記冗長データを含むデータの場合には前記書込み制御を実行し、前記冗長データを含まないデータの場合には前記書込み制御を行わずに前記メモリへの書込みを実行することを特徴とする請求項1又は2記載の電子制御装置。   The write control means determines whether or not the data requested to be written is data including redundant data. If the data includes redundant data, the write control means executes the write control and includes the redundant data. 3. The electronic control unit according to claim 1, wherein when there is no data, the writing to the memory is executed without performing the writing control. マイクロコンピュータから出力されるウォッチドッグパルスによりタイマを繰り返しクリアし、前記タイマのカウント値が所定のリセット閾値に達したときに前記マイクロコンピュータの動作が異常であると判断して該マイクロコンピュータをリセットするウォッチドッグタイマ部を備えた電子制御装置におけるメモリへの書込み方法であって、
前記タイマのカウント値が前記リセット閾値に達するまでに前記メモリへの書込みを完了することができる範囲内で書込み制御閾値を設定するステップと、
前記メモリへの書込み要求に対して、前記タイマのカウント値が前記書込み制御閾値に達しているか否かを判定するステップと、
前記書込み制御閾値に達していない場合には前記メモリへの書込みを実行し、前記書込み制御閾値に達している場合には前記メモリへの書込みをキャンセルする書込み制御を実行するステップと、を有することを特徴とするメモリへの書込み方法。
The timer is repeatedly cleared by a watchdog pulse output from the microcomputer, and when the count value of the timer reaches a predetermined reset threshold, it is determined that the operation of the microcomputer is abnormal and the microcomputer is reset. A method of writing to a memory in an electronic control device having a watchdog timer unit,
Setting a write control threshold within a range in which writing to the memory can be completed before the count value of the timer reaches the reset threshold;
In response to a write request to the memory, determining whether the count value of the timer has reached the write control threshold;
Executing writing to the memory if the write control threshold has not been reached, and executing write control to cancel writing to the memory if the write control threshold has been reached. A method of writing to a memory characterized by
前記判定するステップは、前記書込み要求のあったデータが冗長データを含むデータであるか否かを判定するステップを有し、
前記冗長データを含むデータの場合には前記書込み制御のステップを実行し、前記冗長データを含まないデータの場合には前記書込み制御のステップを行わずに前記メモリへの書込みを実行することを特徴とする請求項4記載のメモリへの書込み方法。
The step of determining includes the step of determining whether the data requested to be written is data including redundant data;
In the case of data including the redundant data, the write control step is executed, and in the case of data not including the redundant data, the writing to the memory is executed without performing the write control step. 5. A method for writing to a memory according to claim 4.
JP2007184828A 2007-07-13 2007-07-13 Electronic control device and method for writing in memory Withdrawn JP2009018773A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007184828A JP2009018773A (en) 2007-07-13 2007-07-13 Electronic control device and method for writing in memory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007184828A JP2009018773A (en) 2007-07-13 2007-07-13 Electronic control device and method for writing in memory

Publications (1)

Publication Number Publication Date
JP2009018773A true JP2009018773A (en) 2009-01-29

Family

ID=40358777

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007184828A Withdrawn JP2009018773A (en) 2007-07-13 2007-07-13 Electronic control device and method for writing in memory

Country Status (1)

Country Link
JP (1) JP2009018773A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101801116B1 (en) 2011-11-28 2017-12-21 콘티넨탈 오토모티브 시스템 주식회사 Method and apparatus for driving pcu

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101801116B1 (en) 2011-11-28 2017-12-21 콘티넨탈 오토모티브 시스템 주식회사 Method and apparatus for driving pcu

Similar Documents

Publication Publication Date Title
US10346231B2 (en) Watchdog circuit, power IC and watchdog monitor system
JP4692318B2 (en) Electronic control unit
US6144887A (en) Electronic control unit with reset blocking during loading
JP3838055B2 (en) In-vehicle control device
JP6598592B2 (en) Semiconductor integrated circuit and electronic control unit
EP1975788B1 (en) Electronic control apparatus
JP4665846B2 (en) Microcomputer and electronic control device
JP3870751B2 (en) Electronic control unit
JP5962697B2 (en) Electronic control unit
TW202022878A (en) Data processing system and data processing method
JP2009018773A (en) Electronic control device and method for writing in memory
US6168321B1 (en) Electronic control unit having user breakable function
JP3923810B2 (en) Electronic control device for vehicle
JP4812699B2 (en) Power control device
JP3870974B2 (en) Electronic control unit
JP2018134964A (en) Electronic control unit for automobile
CN108073489B (en) Method for ensuring operation of calculator
JP6172040B2 (en) Electronic control unit
JP2001160004A (en) Electronic controller
JP5392058B2 (en) Processing apparatus and control method
JP2008309069A (en) Electronic control device for vehicle, electronic control system for vehicle and starting method of electronic control device for vehicle
JP2011100416A (en) In-vehicle electronic controller and memory control method
JPH0325813B2 (en)
JP6589767B2 (en) Electronic control unit
JPH04256038A (en) Watchdog timer inspecting device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100618

A072 Dismissal of procedure

Free format text: JAPANESE INTERMEDIATE CODE: A073

Effective date: 20111025

A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20111101