JP6522550B2 - Electronic control unit - Google Patents

Electronic control unit Download PDF

Info

Publication number
JP6522550B2
JP6522550B2 JP2016115583A JP2016115583A JP6522550B2 JP 6522550 B2 JP6522550 B2 JP 6522550B2 JP 2016115583 A JP2016115583 A JP 2016115583A JP 2016115583 A JP2016115583 A JP 2016115583A JP 6522550 B2 JP6522550 B2 JP 6522550B2
Authority
JP
Japan
Prior art keywords
processing
main ecu
electronic control
calculation load
microcomputer
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.)
Active
Application number
JP2016115583A
Other languages
Japanese (ja)
Other versions
JP2017218081A (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 Astemo Ltd
Original Assignee
Hitachi Automotive Systems 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 Automotive Systems Ltd filed Critical Hitachi Automotive Systems Ltd
Priority to JP2016115583A priority Critical patent/JP6522550B2/en
Publication of JP2017218081A publication Critical patent/JP2017218081A/en
Application granted granted Critical
Publication of JP6522550B2 publication Critical patent/JP6522550B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Combined Controls Of Internal Combustion Engines (AREA)

Description

本発明は、自動車に搭載される電子制御装置に関する。   The present invention relates to an electronic control unit mounted on a vehicle.

自動車に搭載される電子制御装置は、特開2016−23603号公報(特許文献1)に記載されるように、定期的に発生する定期処理、及び、非定期的に発生する割込処理を実行する。   An electronic control unit mounted on a vehicle executes periodic processing that occurs periodically and interrupt processing that occurs irregularly as described in JP-A-2016-23603 (Patent Document 1). Do.

特開2016−23603号公報JP, 2016-23603, A

しかしながら、電子制御装置において、例えば、加減速などの過渡期で割込処理が急増すると、定期処理に加えて割込処理が実行されるため、定期処理が所定の時間内に終了しなくなり、いわゆる処理抜けが発生するおそれがある。そして、処理抜けが発生すると、例えば、電子制御装置の制御対象機器が予期せぬ動作をしたり、プログラムが無限ループに陥って停止してしまう。このため、外部装置で電子制御装置の演算負荷を監視することが考えられるが、例えば、電子制御装置の演算負荷が高まると通信の同期をとることが困難となり、外部装置が演算負荷を監視することができなくなってしまう。   However, in the electronic control device, for example, when the interrupt processing sharply increases in a transition period such as acceleration or deceleration, the interrupt processing is executed in addition to the periodic processing, so that the periodic processing does not end within a predetermined time. Processing omission may occur. Then, when a process omission occurs, for example, the control target device of the electronic control device operates unexpectedly, or the program falls into an infinite loop and stops. For this reason, it is conceivable to monitor the calculation load of the electronic control device with an external device, but for example, when the calculation load of the electronic control device increases, it becomes difficult to synchronize communication, and the external device monitors the calculation load I can not do that.

そこで、本発明は、通信に依存せず、演算負荷を外部から監視可能な電子制御装置を提供することを目的とする。   Therefore, an object of the present invention is to provide an electronic control device capable of monitoring the calculation load from the outside without depending on communication.

このため、マイクロコンピュータを内蔵した電子制御装置は、マイクロコンピュータの演算負荷を測定する手段と、演算負荷をアナログ電圧値に変換する手段と、アナログ電圧値に応じた電圧を出力するアナログ入出力ポートと、電圧が所定のしきい値より高くなったときに、マイクロコンピュータで実行する複数の処理の中から、処理の優先度に応じて選択された処理の実行をスキップさせる手段と、を有する。 Therefore, the electronic control unit incorporating the microcomputer includes means for measuring the operation load of the microcomputer, means for converting the operation load into an analog voltage value, and an analog input / output port for outputting a voltage according to the analog voltage value. And means for skipping execution of a process selected from among a plurality of processes executed by the microcomputer according to the priority of the process when the voltage becomes higher than a predetermined threshold value .

本発明によれば、通信に依存せず、演算負荷を外部から監視することができる。   According to the present invention, the calculation load can be monitored from the outside without depending on communication.

電子制御システムの一例を示すシステム図である。It is a system figure showing an example of an electronic control system. マイクロコンピュータの具体的構造の一例を示すブロック図である。It is a block diagram which shows an example of the concrete structure of a microcomputer. マイクロコンピュータが実行する処理及びそこで発生する問題点の説明図である。It is explanatory drawing of the process which a microcomputer performs, and the problem which arises there. 演算負荷出力処理の一例を示すフローチャートである。It is a flowchart which shows an example of calculation load output processing. 演算負荷及び出力電圧の一例を示す図である。It is a figure which shows an example of calculation load and an output voltage. 演算負荷監視処理の一例を示すフローチャートである。It is a flowchart which shows an example of calculation load monitoring processing. 選択実行処理の一例を示すフローチャートである。It is a flowchart which shows an example of a selection execution process. 定期処理の優先度を設定した優先度テーブルの一例を示す図である。It is a figure which shows an example of the priority table which set the priority of regular processing. 割込処理の優先度を設定した優先度テーブルの一例を示す図である。It is a figure which shows an example of the priority table which set the priority of the interruption process. 自動車の運転状態変化に応じてしきい値を変更する方法の説明図である。It is explanatory drawing of the method of changing a threshold value according to the driving | running state change of a motor vehicle. 電子制御装置の第1変形例を示すシステム図である。It is a system figure showing the 1st modification of an electronic control unit. 電子制御装置の第2変形例を示すシステム図である。It is a system diagram showing the 2nd modification of an electronic control unit.

以下、添付された図面を参照し、本発明を実施するための実施形態について詳述する。
図1は、自動車に搭載された電子制御システムの一例を示す。
Hereinafter, embodiments of the present invention will be described in detail with reference to the attached drawings.
FIG. 1 shows an example of an electronic control system mounted on a car.

電子制御システム100は、燃料噴射装置,自動変速機,電動ブレーキ装置などの制御対象機器を制御する主系の電子制御装置(メインECU)200と、メインECU200とは異なる制御対象機器を制御しながら、メインECU200の演算負荷を監視する従系の電子制御装置(サブECU)300と、を有する。メインECU200は、被監視対象となるマイクロコンピュータ(マイコン)250を内蔵し、サブECU300は、メインECU200のマイコン250を監視する主体となるマイコン350を内蔵する。   The electronic control system 100 controls a control target device different from the main ECU 200 (main ECU) that controls a control target device such as a fuel injection device, an automatic transmission, and an electric brake device. , And a subordinate electronic control unit (sub ECU) 300 that monitors the calculation load of the main ECU 200. The main ECU 200 incorporates a microcomputer 250 to be monitored, and the sub ECU 300 incorporates a microcomputer 350 that monitors the microcomputer 250 of the main ECU 200.

メインECU200のマイコン250は、図2に示すように、CPU(Central Processing Unit)250A、不揮発性メモリの一例として挙げることができるROM(Read Only Memory)250B、揮発性メモリの一例として挙げることができるRAM(Random Access Memory)250C、ウォッチドッグタイマ250D、アナログ信号を入出力するアナログ入出力ポート250E、デジタル信号を入出力するデジタル入出力ポート250F及び他の電子制御装置などと通信するための通信回路250Gが1つのパッケージに封入された電子デバイスである。ここで、ROM250Bとしては、電気的にデータを消去及び書込み可能な、フラッシュROMを使用することができる。なお、サブECU300のマイコン350も、メインECU200のマイコン250と同様な構成をなしている。   As shown in FIG. 2, the microcomputer 250 of the main ECU 200 can be exemplified as an example of a CPU (central processing unit) 250A, a ROM (read only memory) 250B which can be cited as an example of a nonvolatile memory, and a volatile memory Communication circuit for communicating with RAM (Random Access Memory) 250C, watchdog timer 250D, analog input / output port 250E for inputting / outputting analog signals, digital input / output port 250F for inputting / outputting digital signals, and other electronic control devices 250 G is an electronic device enclosed in one package. Here, a flash ROM capable of electrically erasing and writing data can be used as the ROM 250B. The microcomputer 350 of the sub ECU 300 also has a configuration similar to that of the microcomputer 250 of the main ECU 200.

ここで、メインECU200において、マイコン250が実行する処理、及び、そこで発生する問題点について説明する。
メインECU200のマイコン250は、制御対象機器を制御するためのジョブとして、定期的に発生する定期処理と非定期的に発生する割込処理を夫々実行する。定期処理は、例えば、2ms周期,10ms周期など、所定時間ごとに実行する処理である。割込処理は、例えば、自動車の運転状態が変化する過渡期になったとき、変化する運転状態に対応するために発生する処理である。
Here, the processing executed by the microcomputer 250 in the main ECU 200 and the problems occurring there are described.
The microcomputer 250 of the main ECU 200 executes, as a job for controlling the control target device, periodic processing that occurs periodically and interrupt processing that occurs irregularly. The periodic process is, for example, a process that is executed at predetermined time intervals such as a 2 ms cycle, a 10 ms cycle, and the like. The interruption process is a process that occurs to cope with the changing operating condition, for example, when the operating condition of the vehicle changes in a transition period.

メインECU200のマイコン250が実行する処理として、定期処理A〜Dと割込処理a〜eを想定する。割込処理a〜eが発生しない場合、マイコン250は、図3に示すように、定期処理の実行間隔である定期処理時間内に、定期処理A〜Dを実行する。このとき、定期処理時間に対する定期処理A〜Dの実行に要する時間の割合は、例えば、約59%となり、マイコン250の演算負荷は約59%となる。また、割込処理a〜cが発生すると、マイコン250は、定期処理時間内に、定期処理A〜Dに加えて割込処理a〜cを実行する。この場合、定期処理時間に対する定期処理A〜D及び割込処理a〜cの実行に要する時間の割合は、例えば、約87%となり、マイコン250の演算負荷は約87%となる。   As processing executed by the microcomputer 250 of the main ECU 200, periodic processing A to D and interrupt processing a to e are assumed. When the interruption processes a to e do not occur, the microcomputer 250 executes the periodic processes A to D within a periodic process time which is an execution interval of the periodic process as shown in FIG. 3. At this time, the ratio of the time required to execute the periodic processing A to D to the periodic processing time is, for example, about 59%, and the calculation load of the microcomputer 250 is about 59%. Further, when the interrupt processes a to c occur, the microcomputer 250 executes the interrupt processes a to c in addition to the periodic processes A to D within the periodic process time. In this case, the ratio of the time required to execute the periodic processes A to D and the interrupt processes a to c to the periodic process time is, for example, about 87%, and the calculation load of the microcomputer 250 is about 87%.

さらに、自動車の運転状態変化に応じて割込処理a〜eが発生すると、マイコン250は、定期処理時間内に、定期処理A〜Dに加えて割込処理a〜eを実行する。このとき、例えば、定期処理A,割込処理a,定期処理B,割込処理b,定期処理C,割込処理c〜e,定期処理Dの順番で処理が実行されると、定期処理時間内に定期処理Dが終了せず、いわゆる処理あふれが発生してしまう。処理あふれが発生した場合、その処理が重要なものであると、制御対象機器が予期せぬ動作をしたり、プログラムが無限ループに陥って停止してしまうおそれがある。なお、割込処理eが発生しない場合には、定期処理時間内にすべての処理が実行される。   Furthermore, when the interrupt processes a to e occur according to the change in the driving state of the vehicle, the microcomputer 250 executes the interrupt processes a to e in addition to the periodic processes A to D within the periodic process time. At this time, for example, when processing is executed in the order of periodic process A, interrupt process a, periodic process B, interrupt process b, periodic process C, interrupt processes c to e, periodic process D, the periodic process time The periodic process D does not end within, and so-called process overflow occurs. When processing overflow occurs, if the processing is important, the device to be controlled may operate unexpectedly, or the program may stop in an infinite loop. When the interrupt processing e does not occur, all processing is executed within the periodic processing time.

このため、背景技術でも説明したように、外部装置でメインECU200のマイコン250の演算負荷を監視することが考えられるが、例えば、マイコン250の演算負荷が高まると通信の同期をとることが困難となり、外部装置が演算負荷を監視することができなくなってしまう。そこで、以下説明するように、マイコン250の演算負荷をアナログ電圧値に変換し、アナログ電圧値に応じた電圧をアナログ入出力ポート250Eから外部に出力することで、通信に依存せず、演算負荷を外部から監視できるようにする。   Therefore, as described in the background art, it is possible to monitor the calculation load of the microcomputer 250 of the main ECU 200 by an external device, but for example, when the calculation load of the microcomputer 250 increases, it becomes difficult to synchronize communication. The external device can not monitor the operation load. Therefore, as described below, the calculation load of the microcomputer 250 is converted into an analog voltage value, and a voltage corresponding to the analog voltage value is output from the analog input / output port 250E to the outside, thereby making the calculation load independent of communication. Allow external monitoring.

図4は、メインECU200が起動したことを契機として、そのマイコン250が所定時間t1ごとに繰り返し実行する、演算負荷出力処理の一例を示す。なお、マイコン250は、例えば、CPU250AがROM250Bに予め格納された制御プログラムを実行することで、演算負荷出力処理を実行する(以下同様)。また、以下の説明においては、説明を簡略化することを目的として、メインECU200のマイコン250をメインECU200と略記する(以下同様)。   FIG. 4 shows an example of the calculation load output process that the microcomputer 250 repeatedly executes at predetermined time intervals t1 when the main ECU 200 is activated. The microcomputer 250 executes arithmetic load output processing, for example, by the CPU 250A executing a control program stored in advance in the ROM 250B (the same applies to the following). Further, in the following description, the microcomputer 250 of the main ECU 200 is abbreviated as the main ECU 200 for the purpose of simplifying the description (the same applies in the following).

ステップ1(図4では、「S1」と略記する。以下同様。)では、メインECU200が、定期処理時間内に実行した処理(定期処理及び割込処理)の実行時間を計測し、定期処理時間に対する全処理時間である演算負荷(CPU使用率)を計測する。なお、演算負荷としては、CPU使用率に限らず、例えば、計測した処理時間そのもの、リソース使用率など、公知の指標を採用することができる。   In step 1 (abbreviated as "S1" in FIG. 4. The same applies hereinafter), the main ECU 200 measures the execution time of the processing (periodic processing and interrupt processing) executed within the periodic processing time, and the periodic processing time Measure the calculation load (CPU usage rate) which is the total processing time for. The calculation load is not limited to the CPU usage rate, and, for example, a known index such as the measured processing time itself or the resource usage rate can be adopted.

ステップ2では、メインECU200が、演算負荷0%〜100%が所定の電圧範囲、例えば、0V〜5Vに分布するように、演算負荷をアナログ電圧値に変換する。なお、演算負荷を分布させる電圧範囲は、例えば、CPU250Aの演算精度、アナログ入出力ポート250Eの出力特性などを考慮して決定することができる。   In step 2, the main ECU 200 converts the operation load into an analog voltage value such that 0% to 100% of the operation load is distributed in a predetermined voltage range, for example, 0V to 5V. The voltage range in which the calculation load is distributed can be determined in consideration of, for example, the calculation accuracy of the CPU 250A, the output characteristic of the analog input / output port 250E, and the like.

ステップ3では、メインECU200が、アナログ電圧値に応じた電圧を、アナログ入出力ポート250Eから外部に出力する。なお、メインECU200は、アナログ入出力ポート250Eから出力する電圧を任意の時点で参照可能とするため、この状態を持続するようにしてもよい。   In step 3, the main ECU 200 outputs a voltage corresponding to the analog voltage value from the analog input / output port 250E to the outside. Main ECU 200 may maintain this state in order to make it possible to refer to the voltage output from analog input / output port 250E at any time.

かかる演算負荷出力処理によれば、メインECU200は、所定時間t1ごとに、定期処理時間内に実行した処理の実行時間を計測し、これをアナログ電圧値に変化した後、アナログ電圧値に応じた電圧をアナログ入出力ポート250Eから出力する。このため、図5に示すように、メインECU200の起動直後から、演算負荷に相当する電圧が外部に出力され、メインECU200とサブECU300との間の通信が確立されていない状態でも、サブECU300はメインECU200の演算負荷を監視することができる。また、サブECU300は、メインECU200とサブECU300との通信に依存せず、その演算負荷を監視することができる。   According to the calculation load output processing, the main ECU 200 measures the execution time of the processing executed within the periodic processing time at every predetermined time t1, changes it to an analog voltage value, and then responds to the analog voltage value. The voltage is output from the analog input / output port 250E. Therefore, as shown in FIG. 5, the voltage corresponding to the calculation load is output to the outside immediately after activation of main ECU 200, and even if communication between main ECU 200 and sub ECU 300 is not established, sub ECU 300 The calculation load of the main ECU 200 can be monitored. Further, the sub ECU 300 can monitor the calculation load without depending on the communication between the main ECU 200 and the sub ECU 300.

図5に示す一例は、アナログ入出力ポート250Eは0V〜5Vの範囲で電圧を出力するものを前提として、定期処理時間内に実行した処理の実行時間[μs]を演算負荷とすると共に、演算負荷1000[μs]を200[mV]として出力したものである。この例を参照すると、メインECU200の起動直後は、例えば、各種の初期化処理によって演算負荷が比較的高く、演算負荷が約11000[μs]であり、これに相当する電圧が約2200[mV]となっていることが理解されよう。そして、メインECU200の初期化処理が完了すると、演算負荷が低下して約7000[μs]となり、これに相当する電圧が約1400[mV]となった後、定常状態に移行し、演算負荷が約6000[μs]、これに相当する電圧が約1200[mV]で安定することが理解されよう。   In the example shown in FIG. 5, assuming that the analog input / output port 250E outputs a voltage in the range of 0 V to 5 V, the execution time [μs] of the process executed within the periodic processing time is taken as the operation load and The load 1000 [μs] is output as 200 [mV]. Referring to this example, immediately after activation of main ECU 200, for example, the calculation load is relatively high due to various initialization processing, and the calculation load is about 11000 [μs], and the voltage corresponding to this is about 2200 [mV] It will be understood that Then, when the initialization processing of main ECU 200 is completed, the calculation load is reduced to about 7000 [μs], and after the voltage corresponding to this becomes about 1400 [mV], the steady state is entered and the calculation load is reduced. It will be understood that a voltage corresponding to about 6000 [μs] is stabilized at about 1200 [mV].

なお、メインECU200の演算負荷は、オシロスコープなどの汎用機器で視認できるため、例えば、メインECU200の実証実験などにおいて、その演算負荷が過度に高くなっているか否かを確認することができる。   In addition, since the calculation load of the main ECU 200 can be visually recognized by a general-purpose device such as an oscilloscope, it is possible to confirm whether the calculation load is excessively high, for example, in a demonstration experiment of the main ECU 200.

図6は、サブECU300が起動したことを契機として、そのマイコン350が所定時間t2ごとに繰り返し実行する、演算負荷監視処理の一例を示す。ここで、サブECU300は、メインECU200の電圧出力と同期して演算負荷を監視すべく、メインECU200の演算負荷出力処理と同一の所定時間t1で演算負荷監視処理を繰り返し実行することが望ましい。   FIG. 6 shows an example of the calculation load monitoring process that the microcomputer 350 repeatedly executes at predetermined time intervals t2 when the sub ECU 300 is activated. Here, in order to monitor the calculation load in synchronization with the voltage output of the main ECU 200, it is preferable that the sub ECU 300 repeatedly execute the calculation load monitoring process in the same predetermined time t1 as the calculation load output process of the main ECU 200.

ステップ11では、サブECU300が、メインECU200の演算負荷を監視すべく、そのアナログ入出力ポート250Eから電圧を読み込む。
ステップ12では、サブECU300が、電圧が所定のしきい値より高いか否かを判定する。ここで、所定のしきい値は、メインECU200の演算負荷が高まって、割込処理の発生によって処理抜けが発生する可能性があるか否かを判定するためのしきい値であって、例えば、制御対象機器の制御内容,メインECU200の処理能力などを考慮して適宜設定することができる。そして、サブECU300は、電圧が所定のしきい値より高いと判定すれば処理をステップ13へと進める一方(Yes)、電圧が所定のしきい値以下であると判定すれば処理をステップ15へと進める(No)。
In step 11, the sub ECU 300 reads a voltage from the analog input / output port 250E to monitor the calculation load of the main ECU 200.
In step 12, the sub ECU 300 determines whether the voltage is higher than a predetermined threshold. Here, the predetermined threshold value is a threshold value for determining whether the processing load of the main ECU 200 is increased and there is a possibility that the process omission may occur due to the occurrence of the interrupt process, for example, It can be set appropriately in consideration of the control content of the control target device, the processing capacity of the main ECU 200, and the like. Then, if the sub ECU 300 determines that the voltage is higher than the predetermined threshold value, the process proceeds to step 13 (Yes), while if it is determined that the voltage is lower than the predetermined threshold value, the process proceeds to step 15 And proceed (No).

ステップ13では、サブECU300が、例えば、内蔵した計時機能を利用して、電圧が所定のしきい値より高くなった状態が所定時間継続したか否かを判定する。ここで、所定時間は、一時的に演算負荷が高まったことを排除するためのしきい値であって、例えば、制御対象機器の制御内容,メインECU200の処理能力などを考慮して適宜設定することができる。そして、サブECU300は、上記状態が所定時間継続したと判定すれば処理をステップ14へと進める一方(Yes)、上記状態が所定時間継続していないと判定すれば処理をステップ15へと進める(No)。   In step 13, the sub ECU 300 determines, for example, using a built-in clocking function, whether or not the state in which the voltage is higher than the predetermined threshold has continued for a predetermined time. Here, the predetermined time is a threshold value for eliminating the temporary increase in the calculation load, and is appropriately set in consideration of, for example, the control content of the control target device, the processing capacity of the main ECU 200, etc. be able to. Then, sub-ECU 300 advances the process to step 14 if it is determined that the above-described state has continued for a predetermined time (Yes), or advances the process to step 15 if it is determined that the above-described state has not continued for a predetermined time ( No).

ステップ14では、サブECU300が、メインECU200の演算負荷が異常であると判定し、その判定結果をメインECU200に送信する。なお、サブECU300は、メインECU200の演算負荷が異常であると判定したとき、例えば、インストルメントパネルの警告灯などを点灯させ、運転者などに異常が発生したことを報知するようにしてもよい。   In step 14, the sub ECU 300 determines that the calculation load of the main ECU 200 is abnormal, and transmits the determination result to the main ECU 200. If the sub ECU 300 determines that the calculation load of the main ECU 200 is abnormal, for example, the warning light of the instrument panel may be turned on to notify the driver or the like that an abnormality has occurred. .

ステップ15では、サブECU300が、メインECU200の演算負荷は正常であると判定し、その判定結果をメインECU200に送信する。   In step 15, the sub ECU 300 determines that the calculation load of the main ECU 200 is normal, and transmits the determination result to the main ECU 200.

かかる演算負荷監視処理によれば、サブECU300は、メインECU200が出力する電圧が所定のしきい値より高いか否かを介して、メインECU200の演算負荷が過度に上昇したか否かを判定する。そして、サブECU300は、電圧が所定のしきい値より高い状態が所定時間継続したら、メインECU200の演算負荷が異常であると判定する。一方、サブECU300は、電圧が所定のしきい値より高い状態が所定時間継続していなければ、メインECU200の演算負荷が正常であると判定する。その後、サブECU300は、判定結果をメインECU200へ送信する。このとき、メインECU200は、起動直後又は演算負荷が高いときにも電圧を出力しているため、サブECU300は、メインECU200が起動している限り、その演算負荷を監視することができる。   According to the calculation load monitoring process, the sub ECU 300 determines whether the calculation load of the main ECU 200 is excessively increased through whether the voltage output from the main ECU 200 is higher than a predetermined threshold value. . Then, if the state where the voltage is higher than the predetermined threshold continues for a predetermined time, sub ECU 300 determines that the arithmetic load of main ECU 200 is abnormal. On the other hand, if the state in which the voltage is higher than the predetermined threshold does not continue for a predetermined time, sub ECU 300 determines that the calculation load of main ECU 200 is normal. Thereafter, the sub ECU 300 transmits the determination result to the main ECU 200. At this time, since the main ECU 200 outputs a voltage immediately after startup or even when the calculation load is high, the sub ECU 300 can monitor the calculation load as long as the main ECU 200 is started.

なお、サブECU300は、電圧が所定のしきい値より高くなったとき、その状態が所定時間継続したか否かを判定せずに、メインECU200の演算負荷が異常であると判定することもできる。但し、上記状態が所定時間継続したか否かを判定することで、メインECU200の演算負荷が異常であると判定する判定精度を向上させることができる。また、サブECU300は、メインECU200から出力された電圧の変化状態を介して、そのA/D変換器が正常であるか否かを診断することもできる。   When the voltage is higher than a predetermined threshold value, sub ECU 300 can also determine that the calculation load of main ECU 200 is abnormal without determining whether the state has continued for a predetermined time. . However, by determining whether or not the above-described state has continued for a predetermined time, it is possible to improve the determination accuracy of determining that the calculation load of main ECU 200 is abnormal. The sub ECU 300 can also diagnose whether the A / D converter is normal or not through the change state of the voltage output from the main ECU 200.

ところで、メインECU200の演算負荷が異常になったとき、これを放置しておくと、例えば、プログラムが無限ループに陥って、自動車の運転状態に応じて制御対象機器を制御できなくなってしまう。このため、サブECU300は、メインECU200の演算負荷が異常になったと判定したとき、メインECU200をリセットすることもできる。このようにすれば、メインECU200の処理状態を監視しているウォッチドッグタイマ250Dが不要となり、そのマイコン250の製造コストを低減することができる。   By the way, when the calculation load of the main ECU 200 becomes abnormal, if this is left, for example, the program falls into an infinite loop, and it becomes impossible to control the control target device according to the driving state of the vehicle. Therefore, the sub ECU 300 can also reset the main ECU 200 when it determines that the calculation load of the main ECU 200 becomes abnormal. In this way, the watchdog timer 250D that monitors the processing state of the main ECU 200 becomes unnecessary, and the manufacturing cost of the microcomputer 250 can be reduced.

しかし、メインECU200において、演算負荷が過度に高くなったとき、自動車の運転状態に応じた処理を特定し、各処理の優先度に応じて実行する処理を取捨選択するようにすれば、メインECU200をリセットせずに、制御対象機器を制御し続けることができる。以下、この方法について説明する。   However, when the calculation load in the main ECU 200 becomes excessively high, if the processing according to the driving state of the vehicle is specified and the processing to be executed is selected according to the priority of each processing, the main ECU 200 It is possible to keep controlling the control target device without resetting the. Hereinafter, this method will be described.

図7は、メインECU200が、定期処理又は割込処理が発生したことを契機として実行する、選択実行処理の一例を示す。ここで、選択実行処理を実行する前提として、メインECU200は、サブECU300から送信された判定結果を任意の時点で参照可能とするため、例えば、その判定結果をRAM250Cに格納する。なお、以下に説明する選択実行処理は、メインECU200が制御対象機器を制御するための定期処理及び割込処理と比較して演算負荷が軽いため、これを実行しても影響が少ない。   FIG. 7 shows an example of selection execution processing that the main ECU 200 executes in response to the occurrence of periodic processing or interrupt processing. Here, as a premise of executing the selection execution process, the main ECU 200 stores the determination result in, for example, the RAM 250C in order to make it possible to refer to the determination result transmitted from the sub ECU 300 at any time. The selection execution process described below is less affected by the execution of the selection execution process because the calculation load is lighter than the periodic process and the interrupt process for the main ECU 200 to control the control target device.

ステップ21では、メインECU200が、例えば、RAM250Cに格納された判定結果を参照し、演算負荷が所定のしきい値より高い異常が発生しているか否かを判定する。そして、メインECU200は、異常が発生していると判定すれば処理をステップ22へと進める一方(Yes)、異常が発生していないと判定すれば、発生した処理を実行すべく、処理をステップ27へと進める(No)。   In step 21, the main ECU 200 refers to, for example, the determination result stored in the RAM 250C, and determines whether or not an abnormality in which the calculation load is higher than a predetermined threshold value has occurred. Then, if the main ECU 200 determines that an abnormality occurs, the process proceeds to step 22 (Yes), while if it is determined that an abnormality does not occur, the process proceeds to the step to execute the generated process. Proceed to 27 (No).

ステップ22では、メインECU200が、自動車の所定箇所に取り付けられたセンサ出力などを読み込み、例えば、エンジン稼働状態で停止中か、アイドリングストップ状態で停車中か、所定車速以下の低速走行中か、所定車速よりも速い高速走行中かなど、自動車の運転状態を判定する。なお、自動車の運転状態としては、上記の4種類に限らず、3種類以下又は5種類以上とすることもできる。   In step 22, the main ECU 200 reads a sensor output attached to a predetermined location of the vehicle, for example, whether the engine is in operation or stopped, idling stop, or stopped at a low speed or less than a predetermined vehicle speed. It is determined whether the vehicle is driving, such as if it is traveling at high speed faster than the vehicle speed. In addition, as a driving | running state of a motor vehicle, not only said 4 types but 3 or less types or 5 types or more can also be used.

ステップ23では、メインECU200が、ステップ22で判定した運転状態で発生する可能性がある定期処理及び割込処理の各処理について、処理の重要度を示す優先度を特定する。即ち、メインECU200のROM250Bには、図8に示すような定期処理の優先度テーブル、図9に示すような割込処理の優先度テーブルが格納されている。定期処理及び割込処理の優先度テーブルには、夫々、定期処理A〜Dの各処理について、自動車の運転状態に応じた優先度高,中及び低が設定されている。ここで、優先度「高」は必ず実行しなければならない処理、優先度「中」は所定回数ごとに1回実行すればよい処理、優先度「低」は処理をスキップしても影響が少ない処理を示す(以下同様)。定期処理の優先度テーブルを参照すると、例えば、アイドリングストップ状態での停車中における定期処理Bの優先度は、必ず実行しなければならない「高」であることが特定できる。そして、メインECU200は、選択実行処理を実行する契機となった定期処理又は割込処理に応じた、ROM250Bに格納された優先度テーブルを参照し、自動車の運転状態及び処理に応じた優先度を特定する。   In step 23, the main ECU 200 specifies the priority indicating the importance of the process for each process of the periodic process and the interrupt process that may occur in the operation state determined in step 22. That is, the ROM 250B of the main ECU 200 stores a priority table for periodic processing as shown in FIG. 8 and a priority table for interrupt processing as shown in FIG. In the priority table for periodic processing and interrupt processing, high priority, medium priority, and low priority according to the driving state of the vehicle are set for each processing of periodic processing A to D, respectively. Here, the priority "high" is a process that must always be executed, the priority "medium" is a process that may be executed once every predetermined number of times, and the priority "low" has little effect even if the process is skipped Indicates processing (same below). With reference to the priority table for periodic processing, for example, it can be specified that the priority of periodic processing B while the vehicle is stopped in the idling stop state is "high" which must be executed. Then, the main ECU 200 refers to the priority table stored in the ROM 250B according to the periodic process or the interrupt process that has triggered the execution of the selection execution process, and selects the priority according to the operation state and the process of the vehicle. Identify.

ステップ24では、メインECU200が、ステップ23で特定した優先度が「低」、即ち、実行対象である処理はその実行をスキップしても影響が少ないか否かを判定する。そして、メインECU200は、優先度が「低」であると判定すれば(Yes)、その処理の実行をスキップして処理を終了させる。一方、メインECU200は、優先度が「低」でない、即ち、優先度が「中」又は「高」であると判定すれば(No)、処理をステップ25へと進める。   In step 24, the main ECU 200 determines whether the priority specified in step 23 is "low", that is, the process to be executed has little influence even if the execution is skipped. When the main ECU 200 determines that the priority is "low" (Yes), the main ECU 200 skips the execution of the process and ends the process. On the other hand, when the main ECU 200 determines that the priority is not “low”, that is, the priority is “medium” or “high” (No), the process proceeds to step 25.

ステップ25では、メインECU200が、ステップ23で特定した優先度が「中」、即ち、所定回数ごとに1回実行すればよい処理であるか否かを判定する。そして、メインECU200は、優先度が「中」であると判定すれば処理をステップ26へと進める一方(Yes)、優先度が「中」でない、即ち、優先度が「高」であると判定すれば処理をステップ27へと進める(No)。   In step 25, the main ECU 200 determines whether the priority specified in step 23 is “medium”, that is, processing that may be executed once every predetermined number of times. Then, if the main ECU 200 determines that the priority is "middle", the process proceeds to step 26 (Yes), while the priority is not "middle", that is, it is determined that the priority is "high". If so, the process proceeds to step 27 (No).

ステップ26では、メインECU200が、処理の優先度が「中」であるため、例えば、前回処理を実行してから所定回数経過したか否かを介して、その処理の実行をスキップ可能であるか否かを判定する。そして、メインECU200は、スキップ可能であると判定すれば処理を終了させる一方(Yes)、スキップ可能でないと判定すれば処理をステップ27へと進める(No)。   In step 26, since the main ECU 200 has “medium” processing priority, whether the processing can be skipped, for example, based on whether or not a predetermined number of times has elapsed since the previous processing was performed It is determined whether or not. Then, if it is determined that the main ECU 200 can skip, the process is ended (Yes), while if it is determined that the skip is not possible, the process proceeds to step 27 (No).

ステップ27では、メインECU200が、選択実行処理を実行する契機となった処理を実行する。   At step 27, the main ECU 200 executes the processing that has triggered the execution of the selection execution processing.

かかる選択実行処理によれば、メインECU200は、定期処理又は割込処理が発生したときに、演算負荷が正常であれば、その処理を無条件で実行する一方、演算負荷が異常であれば、その処理の優先度に応じて処理の実行をスキップする。このとき、処理の優先度は、自動車の運転状態に応じて特定されるため、実際の運転状態に適合した優先度を特定することができる。そして、優先度の低い処理の実行がスキップされるため、定期処理時間内に重要な処理を実行することができ、例えば、メインECU200をリセットしなくとも、制御対象機器の制御を続行することができる。なお、処理の優先度は、高,中及び低の3段階に限らず、少なくとも、高及び低の2段階であればよい。   According to the selection execution processing, when the periodic processing or the interrupt processing occurs, the main ECU 200 executes the processing unconditionally if the operation load is normal, while if the operation load is abnormal, Execution of processing is skipped according to the priority of the processing. At this time, since the priority of processing is specified according to the driving state of the vehicle, the priority suitable for the actual driving state can be specified. And since execution of a process with a low priority is skipped, important processing can be performed within regular processing time, for example, control of a control object apparatus may be continued without resetting the main ECU 200. it can. The priority of the process is not limited to the three levels of high, medium and low, and may be at least two levels of high and low.

以上の実施形態では、メインECU200の演算負荷が異常であるか否かを判定するための所定のしきい値は、固定値であったが、次のように、自動車の運転状態変化に応じて動的に変更することもできる。   In the above embodiment, the predetermined threshold value for determining whether or not the calculation load of main ECU 200 is abnormal is a fixed value, but as described below, according to the change in driving condition of the vehicle It can also be changed dynamically.

自動車の運転状態が変化するときは、定常状態で発生する定期処理に加え、運転状態変化に対応すべく、種々の割込処理が発生する。即ち、自動車の運転状態が過渡期になったとき、自動車の運転状態が切り替わるとき、メインECU200の演算負荷が変化する状態に移行するとき、発生する処理の数が増減するので、その増減を見越して所定のしきい値を変更する。ここで、自動車の運転状態が過渡期になる一例として、例えば、走行中にブレーキを作動させて減速させたとき、走行中にアクセルペダルを踏み込んで加速させたときなどを挙げることができる。また、自動車の運転状態が切り替わる一例として、例えば、停車時にアイドリングストップに移行するとき、アイドリングストップから復帰するときなどを挙げることができる。さらに、メインECU200の演算負荷が変化する状態に移行する一例として、例えば、電源投入時にメモリ診断を行うとき、アイドリングストップに移行するときなどを挙げることができる。なお、上記運転状態変化に応じて所定のしきい値を変更する大きさは、例えば、各状態変化により発生する割込処理の演算負荷などを考慮して適宜設定することができる。   When the operating condition of the vehicle changes, in addition to the periodic process occurring in the steady state, various interrupt processes occur in response to the operating condition change. That is, when the driving state of the vehicle changes to a transition period, when the driving state of the vehicle switches, and when the operation load of the main ECU 200 changes, the number of processes to be generated increases or decreases. Change the predetermined threshold. Here, as an example in which the driving state of the automobile is in a transition period, for example, when the brake is operated and decelerated during traveling, the accelerator pedal may be depressed during traveling and accelerated. Further, as an example of switching of the driving state of the vehicle, for example, when transitioning to idling stop when the vehicle is stopped, recovery from idling stop can be mentioned. Furthermore, as an example of transitioning to a state in which the calculation load of the main ECU 200 changes, for example, when performing memory diagnosis at power-on, transitioning to idling stop can be mentioned. In addition, the magnitude | size which changes a predetermined | prescribed threshold value according to the said driving | running state change can be suitably set up in consideration of the calculation load etc. of the interruption process which generate | occur | produces by each state change.

このようにすれば、図10に示すように、自動車の運転状態が変化する、過渡期,運転状態の切り替わり,演算負荷が変化する状態となったとき、所定のしきい値が変更されるので、運転状態変化に応じた異常判定を行うことができる。なお、図10に示す例では、所定のしきい値は、定期処理時間に対する処理時間の割合[%]となっている。   In this way, as shown in FIG. 10, the predetermined threshold value is changed when the driving state of the vehicle changes, the transition period, the switching of the driving state, or the calculation load changes. The abnormality determination can be performed according to the change in the driving state. In the example shown in FIG. 10, the predetermined threshold is the ratio [%] of the processing time to the periodic processing time.

電子制御システム100を構成するメインECU200が、図11に示すように、1つのパッケージに2つのマイクロコンピュータA及びBが封入されたデュアルコアプロセッサを内蔵する場合、例えば、一方のマイクロコンピュータBが他方のマイクロコンピュータAの演算負荷を監視することができる。また、電子制御システム100を構成するメインECU200が、図12に示すように、1つのマイクロコンピュータCのみを内蔵する場合、マイクロコンピュータCから出力される電圧を自己で読み込み、その電圧に基づいて演算負荷を自己診断することができる。   When the main ECU 200 constituting the electronic control system 100 incorporates a dual core processor in which two microcomputers A and B are enclosed in one package as shown in FIG. 11, for example, one microcomputer B is the other The computational load of microcomputer A can be monitored. Further, as shown in FIG. 12, when the main ECU 200 constituting the electronic control system 100 incorporates only one microcomputer C, the voltage output from the microcomputer C is read by itself and calculation is performed based on the voltage The load can be self-diagnosed.

ここで、上述した実施形態から把握し得る技術的思想について、以下に記載する。
(1)電子制御装置は、マイクロコンピュータの演算負荷を測定する手段と、前記演算負荷をアナログ電圧値に変換する手段と、前記アナログ電圧値に応じた電圧を外部に出力する手段と、を有する。
Here, technical ideas that can be grasped from the above-described embodiment will be described below.
(1) The electronic control unit has means for measuring the operation load of a microcomputer, means for converting the operation load into an analog voltage value, and means for outputting a voltage according to the analog voltage value to the outside. .

(2)前記電子制御装置は、前記電圧を入力する手段を更に有する。
(3)前記電子制御装置は、前記電圧が所定のしきい値より高くなったときに、前記マイクロコンピュータの演算負荷が異常であると判定する手段を更に有する。
(2) The electronic control unit further includes means for inputting the voltage.
(3) The electronic control unit further includes means for determining that the computing load of the microcomputer is abnormal when the voltage is higher than a predetermined threshold value.

(4)前記電子制御装置は、前記マイクロコンピュータの演算負荷が異常であると判定されたときに、前記マイクロコンピュータで実行する処理を取捨選択する手段を更に有する。
(5)前記電子制御装置は、自動車の運転状態に応じて、前記所定のしきい値を動的に設定する手段を更に有する。
(4) The electronic control unit further includes means for selecting and executing the process to be executed by the microcomputer when it is determined that the calculation load of the microcomputer is abnormal.
(5) The electronic control unit further includes means for dynamically setting the predetermined threshold according to the driving state of the vehicle.

(6)前記電子制御装置は、前記電圧が所定のしきい値より高くなったことに加え、その状態が所定時間継続したときに、前記マイクロコンピュータの演算負荷が異常であると判定する。 (6) In addition to the voltage being higher than a predetermined threshold value, the electronic control unit determines that the operation load of the microcomputer is abnormal when the state continues for a predetermined time.

(7)前記電子制御装置は、前記マイクロコンピュータの演算負荷が異常であると判定したとき、前記処理の優先度に応じて、前記マイクロコンピュータで実行する処理を取捨選択する。 (7) If the electronic control unit determines that the calculation load of the microcomputer is abnormal, the electronic control unit discards the process to be executed by the microcomputer according to the priority of the process.

(8)前記処理の優先度は、自動車の運転状態ごとに設定されている。
(9)前記演算負荷は、定期処理時間内に実行する処理の実行時間又は割合である。
(10)前記処理は、定期処理及び割込処理である。
(8) The priority of the process is set for each driving state of the vehicle.
(9) The calculation load is an execution time or a ratio of processing to be executed within a periodic processing time.
(10) The processing is periodic processing and interrupt processing.

200 メインECU
250 マイコン(マイクロコンピュータ)
250E アナログ入出力ポート
200 main ECU
250 microcomputers (microcomputers)
250E analog I / O port

Claims (5)

マイクロコンピュータを内蔵した電子制御装置であって、
前記マイクロコンピュータの演算負荷を測定する手段と、
前記演算負荷をアナログ電圧値に変換する手段と、
前記アナログ電圧値に応じた電圧を出力するアナログ入出力ポートと、
前記電圧が所定のしきい値より高くなったときに、前記マイクロコンピュータで実行する複数の処理の中から、当該処理の優先度に応じて選択された処理の実行をスキップさせる手段と、
を有することを特徴とする電子制御装置。
An electronic control unit incorporating a microcomputer,
It means for measuring a calculation load of the microcomputer,
Means for converting the computing load into an analog voltage value;
An analog input / output port that outputs a voltage corresponding to the analog voltage value;
Means for skipping execution of a process selected from among a plurality of processes executed by the microcomputer according to the priority of the process when the voltage becomes higher than a predetermined threshold value;
An electronic control unit characterized by having.
自動車の運転状態に応じて、前記所定のしきい値を動的に設定する手段を更に有する、
ことを特徴とする請求項1に記載の電子制御装置。
The system further comprises means for dynamically setting the predetermined threshold according to the driving condition of the vehicle.
The electronic control unit according to claim 1 , characterized in that:
前記処理の優先度は、自動車の運転状態ごとに設定されている、
ことを特徴とする請求項1又は請求項2に記載の電子制御装置。
The priority of the process is set for each driving condition of the vehicle.
The electronic control device according to claim 1 or 2, characterized in that:
前記演算負荷は、定期処理時間内に実行する処理の実行時間又は割合である、
ことを特徴とする請求項1〜請求項3のいずれか1つに記載の電子制御装置。
The calculation load is an execution time or a rate of processing to be performed within a periodic processing time,
The electronic control device according to any one of claims 1 to 3 , characterized in that :
前記処理は、定期処理及び割込処理である、
ことを特徴とする請求項1〜請求項4のいずれか1つに記載の電子制御装置。
The processing is periodic processing and interrupt processing.
The electronic control device according to any one of claims 1 to 4 , characterized in that :
JP2016115583A 2016-06-09 2016-06-09 Electronic control unit Active JP6522550B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016115583A JP6522550B2 (en) 2016-06-09 2016-06-09 Electronic control unit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016115583A JP6522550B2 (en) 2016-06-09 2016-06-09 Electronic control unit

Publications (2)

Publication Number Publication Date
JP2017218081A JP2017218081A (en) 2017-12-14
JP6522550B2 true JP6522550B2 (en) 2019-05-29

Family

ID=60658778

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016115583A Active JP6522550B2 (en) 2016-06-09 2016-06-09 Electronic control unit

Country Status (1)

Country Link
JP (1) JP6522550B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102085899B1 (en) * 2018-12-10 2020-03-06 현대오트론 주식회사 Operating Monitoring Method For CPU Of Vehicle ECU, And Monitoring Unit

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6320931A (en) * 1986-07-14 1988-01-28 Mitsubishi Electric Corp Data transmission equipment
JPH07141225A (en) * 1993-11-15 1995-06-02 Nec Home Electron Ltd Runaway monitor device
JP2005259023A (en) * 2004-03-15 2005-09-22 Denso Corp Vehicle control system
US8140750B2 (en) * 2005-09-29 2012-03-20 International Business Machines Corporation Monitoring performance of a storage area network
JP2012018219A (en) * 2010-07-06 2012-01-26 Aisin Aw Co Ltd Display device and program therefor

Also Published As

Publication number Publication date
JP2017218081A (en) 2017-12-14

Similar Documents

Publication Publication Date Title
JP6754743B2 (en) In-vehicle electronic control unit and its abnormal processing method
JP6311827B2 (en) Control device and control method for in-vehicle electronic device
JP4770602B2 (en) Electronics
JP5444852B2 (en) Traffic signal controller and traffic signal controller abnormality determination method
JP6522550B2 (en) Electronic control unit
US10710521B2 (en) Abnormality monitoring device and electric power steering device using same
US20180354581A1 (en) Control device for a bicycle
JP2016177423A (en) Control system having multi-core microcontroller and control method thereof
JP6020765B2 (en) Control device and control method for in-vehicle electronic device
JP2017228192A (en) Vehicle controller
WO2009040608A1 (en) Timer unit, system, computer program product and method for testing a logic circuit
JP5533777B2 (en) Program group
US20080282248A1 (en) Electronic computing device capable of specifying execution time of task, and program therefor
JP2010113419A (en) Multicore controller
JP6623191B2 (en) In-vehicle control device
US10514970B2 (en) Method of ensuring operation of calculator
JP2002041493A (en) Microcomputer
JP2014238661A (en) Controller
JP2016072731A (en) Automobile electronic control apparatus and diagnostic method
WO2022113155A1 (en) Vehicular onboard control system
JP6533489B2 (en) Vehicle controller
US20230409403A1 (en) Control device and control method
JP2016182873A (en) Failure diagnostic device
JP5392058B2 (en) Processing apparatus and control method
KR102075086B1 (en) Epm microtick generation emergency stop using dma

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180307

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20181206

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20181218

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20190213

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20190416

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190424

R150 Certificate of patent or registration of utility model

Ref document number: 6522550

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250