JP4419192B2 - Automotive control device - Google Patents
Automotive control device Download PDFInfo
- Publication number
- JP4419192B2 JP4419192B2 JP2005051152A JP2005051152A JP4419192B2 JP 4419192 B2 JP4419192 B2 JP 4419192B2 JP 2005051152 A JP2005051152 A JP 2005051152A JP 2005051152 A JP2005051152 A JP 2005051152A JP 4419192 B2 JP4419192 B2 JP 4419192B2
- Authority
- JP
- Japan
- Prior art keywords
- message
- control
- cycle
- reception
- ram
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
- 238000012546 transfer Methods 0.000 claims description 40
- 238000012545 processing Methods 0.000 claims description 27
- 230000001360 synchronised effect Effects 0.000 claims description 12
- 230000004913 activation Effects 0.000 claims description 10
- 230000001788 irregular Effects 0.000 claims description 7
- 230000000737 periodic effect Effects 0.000 claims description 4
- 238000000034 method Methods 0.000 description 32
- 230000008569 process Effects 0.000 description 24
- 230000006870 function Effects 0.000 description 17
- 238000010586 diagram Methods 0.000 description 11
- 101100328887 Caenorhabditis elegans col-34 gene Proteins 0.000 description 5
- 230000000694 effects Effects 0.000 description 5
- 238000004891 communication Methods 0.000 description 3
- 238000007796 conventional method Methods 0.000 description 2
- 238000002360 preparation method Methods 0.000 description 2
- 230000005856 abnormality Effects 0.000 description 1
- 239000000446 fuel Substances 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 238000005549 size reduction Methods 0.000 description 1
- 230000007704 transition Effects 0.000 description 1
Images
Landscapes
- Programmable Controllers (AREA)
Description
この発明は自動車用制御装置に関する。 The present invention relates to an automobile control device.
自動車には、各種機器(被制御要素)を制御するために、マイクロプロセッサ(ハードウェア制御主体)からなるECUが搭載されている。近年、自動車に搭載されるECUは処理容量(パラレル処理ビット数及びクロック周波数)に大きいものが使用されるようになってきており、1つのECUが、被制御要素の異なる複数のアプリケーションを並列に実行する状況が生じている(例えば特許文献1,2)。これら複数のアプリケーションは、上記ECUが接続されている車内ネットワークを介して、種々の制御情報を含んだ制御用メッセージを取得し、対応する被制御要素の制御処理を実施する。なお、本明細書において「メッセージ」は、通信によりECUに転送されてくるデータ列の概念として広義に定義されるものであり、言語的に結合された文字列からなる狭義一般の意味でのメッセージのみを意味するものではない。例えば、センサが検出した温度や速度などの数値パラメータの情報も、「メッセージ」の概念に属するものである。
In order to control various devices (controlled elements), an automobile is equipped with an ECU composed of a microprocessor (hardware control main body). In recent years, ECUs mounted on automobiles have been used with large processing capacities (number of parallel processing bits and clock frequency), and one ECU can parallelize multiple applications with different controlled elements in parallel. There is a situation of execution (for example,
ところで、ネットワークを介して外部から情報を取得するマイクロコンピュータでは、対応するアプリケーションに受信したデータが直ちに供されることはまれであり、多くはアプリケーション側でのジョブ待ちなどの要因によって、これを一時的に退避させておく必要があり、このような目的のために通信バスとマイクロコンピュータの内部バスとの間に受信バッファメモリを設ける構成が一般化している(例えば特許文献3)。 By the way, in a microcomputer that obtains information from the outside via a network, it is rare that the received data is immediately provided to the corresponding application, and in many cases, this is temporarily performed due to factors such as job waiting on the application side. For this purpose, a configuration in which a reception buffer memory is provided between a communication bus and an internal bus of a microcomputer has become common (for example, Patent Document 3).
ところで、ECUを主体とした自動車制御装置においては、1つのECUを複数の機能制御に兼用するために、各機能に対応した複数のアプリケーションをスケジューラによって順次起動する方式が採用されることも多い。車内ネットワークを介して受信した制御用メッセージは一旦受信バッファメモリに格納されるが、該受信バッファメモリ上の制御用メッセージは、スケジューラが規定する実行周期(以下、制御周期ともいう)毎にアプリケーション側に取得されることになる。この場合、制御用メッセージの受信周期が制御周期と同じかそれよりも長ければ、受信バッファメモリからのメッセージの転送はスムーズに行なうことができるが、アプリケーションの種類によっては、制御用メッセージの更新をよりきめ細かく行なうため、制御周期よりも短い周期で受信(更新)される制御用メッセージを用いるものがある。また、複数のアプリケーション間で制御用メッセージの受信周期が異なる状況もありえる。 By the way, in an automobile control apparatus mainly composed of an ECU, in order to use one ECU for a plurality of function controls, a system in which a plurality of applications corresponding to each function are sequentially activated by a scheduler is often employed. The control message received via the in-vehicle network is temporarily stored in the reception buffer memory. The control message on the reception buffer memory is stored in the application side every execution cycle (hereinafter also referred to as control cycle) defined by the scheduler. Will be acquired. In this case, if the control message reception cycle is equal to or longer than the control cycle, the message can be transferred smoothly from the reception buffer memory. However, depending on the type of application, the control message may be updated. In order to perform it more finely, there is one that uses a control message that is received (updated) at a cycle shorter than the control cycle. In addition, there may be situations in which the control message reception cycle differs among a plurality of applications.
上記のような短周期の制御用メッセージを受信した場合、従来は、その受信した制御用メッセージをアプリケーション側で取得する方式としては、(1)アプリケーションの実行周期毎にポーリングを行なって受信した制御用メッセージを取得する方式と、(2)上記実行周期内に受信した制御用メッセージを、受信割り込み処理によりことごとく取得する方式との2種類が考えられる。しかし、(1)の方式では、せっかく短周期でメッセージを受信しても、ポーリングはそれより長い周期でしか実施されないから、1つの制御周期に2回以上制御用メッセージを受信しても、古いメッセージが受信バッファメモリの上書きにより消されてしまい、利用できなくなる不具合につながる。他方、(2)の方法では、受信がある毎に割り込み処理を介在させてメッセージを取得するので、バッファメモリ上のデータ上書きによる古いメッセージの喪失は防止できるが、受信周期が短くなると割り込み処理の負荷が大きくなり、制御メインルーチンの実行に支障を来たす問題がある。また、メッセージの受信周期がまちまちなので、処理負荷が通信状態によって大きく変動し、特に異常発生時等において短時間に多数のメッセージ受信が集中したときの影響は大きい。 When a control message with a short cycle as described above is received, conventionally, as a method of acquiring the received control message on the application side, (1) control received by performing polling every execution cycle of the application There are two types: a method for acquiring a message for use and (2) a method for acquiring all the control messages received within the execution cycle by reception interrupt processing. However, in the method of (1), even if a message is received with a short period of time, polling is performed only with a longer period, so even if a control message is received more than once in one control period, it is old. The message is erased by overwriting the reception buffer memory, leading to a problem that the message cannot be used. On the other hand, in the method (2), every time there is reception, a message is acquired through intervening interrupt processing. Therefore, loss of an old message due to data overwriting on the buffer memory can be prevented. There is a problem that the load becomes large and hinders the execution of the control main routine. Also, since the message reception cycle varies, the processing load varies greatly depending on the communication state, and the influence is particularly great when a large number of message receptions are concentrated in a short time when an abnormality occurs.
本発明の課題は、制御用メッセージを制御周期よりも短周期にて受信・取得する処理を確実に行なうことができ、かつ、割り込み処理を利用する場合と比較してその処理負荷を大幅に低減できる自動車用制御装置を提供することにある。 An object of the present invention is to reliably perform processing for receiving and acquiring a control message in a cycle shorter than the control cycle, and to significantly reduce the processing load compared to the case of using interrupt processing. An object of the present invention is to provide an automotive control device that can be used.
上記の課題を解決するために、本発明の自動車用制御装置は、
自動車上の複数の被制御要素の電気的動作を制御するために被制御要素に対応して設けられた複数の制御手段を、各制御手段に対応した複数のアプリケーションにより機能実現する自動車用制御装置であって、
アプリケーションの実行主体となるCPUと、
複数のアプリケーションを実行するためのワークエリアとなるRAMと、
複数のアプリケーションを、予め定められた順序にて基準周期のサイクルにて順次起動するアプリケーション起動スケジューラと、
自動車用制御装置の制御主体を構成するハードウェア制御主体が車内ネットワークを介して受信する、アプリケーション上にて使用する制御用メッセージを一時的に格納するために、RAMとは別に設けられた受信バッファメモリと、
受信バッファメモリに格納された制御用メッセージを、基準周期よりも短く設定された転送周期にてRAM内に設けられたRAM内バッファ領域に転送するメッセージ転送スケジューラと、
基準周期と同期した予め定められたタイミングにて、RAM内バッファ領域から制御用メッセージを取得することを、対応するアプリケーションに指令するメッセージ取得指令手段と、を備え、
制御用メッセージとして、基準周期からなるアプリケーションの実行周期内にて、最新メッセージのみが使用される最新履歴採用型メッセージと、実行周期内にて受信した全メッセージを使用する全履歴採用型メッセージとを車内ネットワークから受信するようになっており、
RAM内バッファ領域は、制御用メッセージの最新のもののみが随時上書き更新される形で書き込まれる第一種バッファ領域と、受信メッセージを受信時系列順に個別に記憶する第二種バッファ領域とを有することを特徴とする。
In order to solve the above-described problems, a control apparatus for automobiles of the present invention
A control apparatus for an automobile that realizes functions of a plurality of control means provided corresponding to the controlled elements in order to control electrical operations of the controlled elements on the automobile by a plurality of applications corresponding to the respective control means Because
A CPU which is the execution subject of the application;
RAM as a work area for executing a plurality of applications;
An application activation scheduler that sequentially activates a plurality of applications in a cycle of a reference period in a predetermined order;
A reception buffer provided separately from the RAM for temporarily storing a control message used on an application received by the hardware control entity constituting the control entity of the vehicle control apparatus via the in-vehicle network. Memory,
A message transfer scheduler for transferring a control message stored in the reception buffer memory to a buffer area in the RAM provided in the RAM at a transfer period set shorter than the reference period;
At predetermined timing synchronized with the reference period, to obtain a control message from the RAM buffer region, e Preparations and message acquisition instruction means for instructing the corresponding application, and
As control messages, the latest history adoption type message that uses only the latest message within the execution cycle of the application consisting of the reference cycle, and the all history adoption type message that uses all messages received within the execution cycle. Receive from the in-car network,
The buffer area in the RAM has a first type buffer area in which only the latest control message is overwritten and updated as needed, and a second type buffer area for individually storing received messages in the order of reception time series. It is characterized by that.
上記本発明の自動車用制御装置の構成によると、自動車上の被制御要素を制御するための複数のアプリケーションを、アプリケーション起動スケジューラにより予め定められた順序にて基準周期のサイクルにて順次起動する。また、それらアプリケーションで使用する制御用パラメータを受信バッファメモリに一次格納するとともに、アプリケーションの実行領域を形成するRAM内には、上記受信バッファメモリとは別にRAM内バッファ領域が形成され、該受信バッファメモリから該RAM内バッファ領域へ、上記基準周期よりも短く設定された転送周期にて制御メッセージを転送するメッセージ転送スケジューラを設ける。RAM内バッファ領域に転送された制御用メッセージは、基準周期と同期した予め定められたタイミングにて、対応するアプリケーションにその取得が指令される。これにより、制御用パラメータの受信周期がアプリケーションの起動周期である基準周期より短くなった場合でも、メッセージ転送スケジューラが当該短い周期にてメッセージをRAM内バッファ領域に退避させる。その結果、前述の(1)の方式のごとく、古いメッセージが受信バッファメモリの上書きにより消されてしまう不具合は生じない。また、割り込み処理を用いずに、専用のメッセージ転送スケジューラの実行によりRAM内バッファ領域へのメッセージの退避処理を行なうので、(2)の方式のごとく、受信周期が短くなると割り込み処理の負荷が大きくなり、制御メインルーチンの実行に支障を来たす問題も効果的に回避できる。 According to the configuration of the automobile control device of the present invention, a plurality of applications for controlling controlled elements on the automobile are sequentially activated in a cycle of a reference period in a predetermined order by an application activation scheduler. In addition, the control parameters used in these applications are temporarily stored in the reception buffer memory, and a RAM buffer area is formed in the RAM forming the application execution area separately from the reception buffer memory. A message transfer scheduler is provided for transferring the control message from the memory to the buffer area in the RAM at a transfer cycle set shorter than the reference cycle. Acquisition of the control message transferred to the buffer area in the RAM is instructed to the corresponding application at a predetermined timing synchronized with the reference period. As a result, even when the reception period of the control parameter is shorter than the reference period that is the application activation period, the message transfer scheduler saves the message in the buffer area in the RAM at the short period. As a result, there is no problem that old messages are erased by overwriting the reception buffer memory as in the method (1) described above. In addition, since the message saving process is performed in the buffer area in the RAM by executing the dedicated message transfer scheduler without using the interrupt process, the load on the interrupt process increases as the reception cycle becomes shorter as in the method (2). Thus, problems that hinder the execution of the control main routine can be effectively avoided.
受信バッファメモリには、制御用メッセージの種別に対応した複数の記憶領域を設けることができる。また、受信バッファメモリの記憶領域は、対応する種別の制御用メッセージを、受信のたびに古いメッセージを上書き更新する形で記憶されるものとして構成することができる。受信バッファメモリのサイズを縮小してハードウェア構成を簡略化することができる。また、受信周期が基準周期よりも短い制御用メッセージは、メッセージ転送スケジューラにより上書き前に受信バッファメモリからRAM内バッファ領域へ転送されるので、上記のように受信バッファメモリのサイズを縮小しても、バッファ上書きによるメッセージデータ喪失を効果的に防止することができる。 The reception buffer memory can be provided with a plurality of storage areas corresponding to the types of control messages. Further, the storage area of the reception buffer memory can be configured to store a corresponding type of control message in such a manner that an old message is overwritten and updated each time it is received. The size of the reception buffer memory can be reduced to simplify the hardware configuration. Also, control messages whose reception cycle is shorter than the reference cycle are transferred from the reception buffer memory to the buffer area in the RAM before being overwritten by the message transfer scheduler, so even if the size of the reception buffer memory is reduced as described above, The loss of message data due to buffer overwriting can be effectively prevented.
受信バッファメモリのサイズをより縮小するには、RAM内バッファ領域に形成された少なくとも1つの制御用メッセージの記憶領域を、2種以上の制御用メッセージの格納領域に共用化することが有効である。従来の方法では、このような記憶領域の共用化により、先行するメッセージが、後続の種別の異なるメッセージにより上書き消去される不具合が生じやすかったが、本発明の構成を前提とすれば、後続のメッセージに上書きされる前に、先行するメッセージをメッセージ転送スケジューラにより受信バッファメモリからRAM内バッファ領域に転送することで、メッセージの喪失を防止することができ、受信バッファメモリのサイズ縮小効果を問題なく享受できるようになる。 In order to further reduce the size of the reception buffer memory, it is effective to share at least one control message storage area formed in the RAM buffer area with two or more control message storage areas. . In the conventional method, due to such sharing of the storage area, the preceding message is likely to be overwritten and erased by a message of a different type, but if the configuration of the present invention is assumed, the subsequent message Before the message is overwritten, the preceding message is transferred from the reception buffer memory to the buffer area in the RAM by the message transfer scheduler, so that the loss of the message can be prevented, and the size reduction effect of the reception buffer memory can be achieved without any problem. You can enjoy it.
以下、本発明の実施の形態を、図面を参照して説明する。
図1は、本発明の自動車用制御装置を構成するECUの電気的な構成図である。ECU1は、CPU3、ROM5、RAM4及び入出力部(I/Oポート)2がバス接続されたマイクロプロセッサからなる。ECU1は、本実施形態では自動車のボデー系の制御を司るボデー系ECUとして構成され、図2はその概略アーキテクチャを示すものである。マイクロプロセッサからなるハードウェア制御主体上に搭載されるソフトウェアは、プラットフォームと、そのプラットフォーム上で動作する、ボデー系機能を実現するための制御アプリケーション(以下、単にアプリケーションともいう)である。なお、複数のアプリケーションを区別するために、A,B,Cの記号を付して示した(もちろん、アプリケーションの数は複数であれば3つに限られるものではない:図2では、アプリケーションがn個の場合にて、より一般化した形で図示を行なっている)。プラットフォームは、ベースとなるハードウェアが相違する場合にも、各アプリケーションに共通の動作環境を与えるためのものであり、該アプリケーションに対する基本ソフト(OS)のほか、アプリケーションやハードウェアとの連携を図るインターフェースプログラムなどを含んで構成されるが、概念的には周知の部分なので説明の詳細は省略する。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is an electrical configuration diagram of an ECU constituting the automobile control apparatus of the present invention. The
アプリケーションは、車両利用者による車両各部の操作に係る機能であるボデー系機能を実現するものである。このボデー系機能とは、具体的には、ドア開閉に伴う制御、窓開閉に伴う制御、ライトスイッチのオン/オフに伴う制御、キーレスエントリ方式等に採用されるワイヤレスドアロック機構の制御、・・・といったものをいう。具体的には、以下のようなものを例示できる:
・運転席ドア、助手席ドア、後部右側座席ドア、後部左側座席ドア、ルーフなどのロック/ロック解除、パワーウィンドウ動作など。
・エアコン、カーオーディオ、カーナビゲーションシステムなどの電源動作など。
・ルームランプ、コックピットランプ、ヘッドライト、スモールランプ、ハザードランプ、テールランプなどのスイッチ点灯制御など。
The application realizes a body function that is a function related to operation of each part of the vehicle by the vehicle user. Specifically, the body system functions include control associated with opening / closing of a door, control associated with opening / closing of a window, control associated with turning on / off a light switch, control of a wireless door lock mechanism employed in a keyless entry system, etc.・ ・ Etc. Specific examples include the following:
-Driver door, passenger door, rear right seat door, rear left seat door, roof lock / unlock, power window operation, etc.
・ Power supply operation for air conditioners, car audio systems, car navigation systems, etc.
-Switch lighting control for room lamp, cockpit lamp, headlight, small lamp, hazard lamp, tail lamp, etc.
各アプリケーションA、B、CはROM5に記憶されており、RAM4の各アプリケーションに対応したワークエリア4A,4b,4c上でCPU3により実行される。これら複数のアプリケーションA,B,Cは、プラットフォームの機能の一部として形成されたアプリケーション起動スケジューラによって、図9に示すように、予め定められた順序にて基準周期T0のサイクルにて順次起動する。このとき、プラットフォーム内の状態管理プログラムが、一連のアプリケーションの状態をまとめて管理するようになっており、制御状態を判定して状態遷移処理を行なう。状態管理プログラムは、アプリケーションの状態として3つの状態、すなわち準備状態、制御状態、そして、制御開始監視状態を定義しており、上記アプリケーション起動スケジューラによる一連の起動処理毎に、各アプリケーションからの信号に基づき、必要に応じて状態を遷移させる。なお、1つのアプリケーションによる処理周期は、基準周期T0に一致させることもできるし、比較的大型のアプリケーション等において、基準周期T0の整数倍の処理周期を設定することも可能である(例えば、サブルーチン別に異なるサイクルでアプリケーションを実行する場合など)。本実施形態では、処理周期が基準周期T0(アプリケーションの実行周期(制御周期))一致している場合を例にとる。
Each application A, B, C is stored in the ROM 5 and is executed by the
ECU1は、車内ネットワーク(ネットワークバス)を介して受信する、各アプリケーションA〜C上にて使用する制御用メッセージを一時的に格納するために、RAM4とは別に設けられた受信バッファメモリ7を備えている。受信バッファメモリ7に格納された制御用メッセージは、図10に示すように、メッセージ転送スケジューラにより、前記基準周期T0よりも短く設定された転送周期T1にてRAM4内に設けられたRAM内バッファ領域4e,4fに転送される。上記の制御用メッセージを使用する対応するアプリケーションには、当該制御用メッセージをRAM内バッファ領域4e,4fから取得することが指令される(メッセージ取得指令手段)。メッセージ転送スケジューラの機能は、ROM5内に格納されたメッセージ転送制御プログラム5d(実行領域は、RAM4内のワークエリア4d)により機能実現される。また、メッセージ取得指令手段の機能は、本実施形態では、前述のアプリケーション起動スケジューラの中に組み入れられているが、メッセージ転送制御プログラム5d内のジョブとして取り扱うことも可能である。
The
上記の構成によると、制御用パラメータの受信周期T1がアプリケーションの起動周期(制御周期)である基準周期T0より短くなった場合に、メッセージ転送スケジューラが当該短い周期T1にてメッセージをRAM内バッファ領域4e,4fに退避させる。その結果、古いメッセージが受信バッファメモリ7への新しいメッセージの上書きにより、アプリケーション側での取得前に消されてしまう不具合が生じない。また、割り込み処理を用いずに、専用のメッセージ転送スケジューラの実行によりRAM内バッファ領域4e,4fへのメッセージの退避処理を行なうので、短い受信周期T1に同期して割り込み処理が繰り返し実施されることによる処理負荷の増大も回避できる。
According to the above configuration, when the reception period T1 of the control parameter is shorter than the reference period T0 that is the application activation period (control period), the message transfer scheduler sends a message in the RAM buffer area in the short period T1. Retreat to 4e, 4f. As a result, there is no problem that the old message is deleted before being acquired on the application side by overwriting the new message in the
以下、さらに詳しく説明する。
受信バッファメモリ7には、図3に示すように、制御用メッセージの種別(A,B,C)に対応した複数の記憶領域が設けられている。これら受信バッファメモリ7の記憶領域には、対応する種別の制御用メッセージを新たに受信すると、既に書き込まれている古い制御用メッセージを上書き消去する形でこれらは書き込まれる。なお、R受信バッファメモリ7に形成された少なくとも1つの制御用メッセージの記憶領域を、2種以上の制御用メッセージの格納領域に共用化することが有効である。従来の方法では、このような記憶領域の共用化により、先行するメッセージが、後続の種別の異なるメッセージにより上書き消去される不具合が生じやすかったが、後続のメッセージに上書きされる前に、先行するメッセージをメッセージ転送スケジューラにより受信バッファメモリ7からRAM内バッファ領域4e,4fに転送することで、メッセージの喪失を防止することができ、受信バッファメモリ7のサイズ縮小効果を問題なく享受できるようになる。
This will be described in more detail below.
As shown in FIG. 3, the
本実施形態においては、受信バッファメモリ7はバッファメモリコントローラ6を介してネットワークバスに接続されている。バッファメモリコントローラ6は、入出力部2とネットワークバスとの間に介在し、ネットワークバス上を送信されてくる制御用メッセージを受信して、受信バッファメモリ7に格納する。制御用メッセージはシリアルデータであり、先頭にメッセージの種別を識別するメッセージ種別コードが配置され、これに続く形でメッセージ本体が配置される。受信バッファメモリ7内の複数の制御用メッセージ格納領域(図3、[0],[1],[2],‥,[n−1])は、該メッセージ種別コードに個別に対応付けられている。図6は受信バッファ制御の流れを示すものであり(バッファメモリコントローラ6内のハードウェアロジックで処理される)、バッファメモリコントローラ6はメッセージ種別コードを識別して(S1)、該メッセージ種別コードに対応した格納領域に格納される(S2,S3)。図3では、[n−1]の格納領域が、2つの種別のメッセージX及びメッセージYの格納に兼用(つまり、共有化)されているが、どの格納領域を複数メッセージに兼用するかは任意であり、場合によっては全ての格納領域を複数メッセージに兼用するように構成してもよい。なお、このような共有化されたバッファメモリ7の格納領域から、種別の異なる2つのメッセージを、RAM内バッファ領域4eに基準周期T0よりも短い間隔で順次転送する場合、両メッセージのバッファメモリ7への受信タイミングの間にも、上記RAM内バッファ領域4eへの転送周期に相当する、基準周期T0よりも短い待機時間を設けておくことが望ましい。
In the present embodiment, the
制御用メッセージは、基準周期T0からなるアプリケーションの実行周期内にて、最新メッセージのみが使用される最新履歴採用型メッセージと、実行周期内にて受信した全メッセージを使用する全履歴採用型メッセージとを車内ネットワークから受信することができる。図7に概念図を示し(受信バッファメモリ7の構成は、図3とは異なるものを示している)、メッセージA,B,Cの3つが最新履歴採用型メッセージに該当し、メッセージK,X,Yが全履歴採用型メッセージに該当する。
The control message includes the latest history adoption type message in which only the latest message is used within the execution cycle of the application having the reference cycle T0, and the all history adoption type message in which all messages received within the execution cycle are used. Can be received from the in-vehicle network. FIG. 7 shows a conceptual diagram (the configuration of the
そして、RAM内バッファ領域4e,4fは、制御用メッセージの最新のもののみが随時上書き更新される形で書き込まれる第一種バッファ領域4e(メッセージ別バッファメモリ:図4)と、受信メッセージを受信時系列順に個別に記憶する第二種バッファ領域4fとを有するものとして構成されている。このようにすると、最新履歴採用型メッセージA,B,Cについては、第一種バッファ領域4eへの上書きにより最新メッセージを確実に取得することができ、かつ第一種バッファ領域4eのサイズも縮小できる。他方、全履歴採用型メッセージK,X,Yについては、第二種バッファ領域4fに受信メッセージを受信時系列順に個別に記憶することができる。最新履歴採用型メッセージの実例としては、 例えば、ある制御要求が発生した際に、その要求を受け付けてよいかを判断するために使用する情報を含むメッセージ(例えば、各種SWのon/off状態を通知するメッセージなど)等を例示できる。また、全履歴採用型メッセージの実例としては、燃費や車速等、受信した情報の積算結果を制御に用いるメッセージ等を例示できる。なお、これらはあくまで例示であって、複数のECUが、ある同じメッセージを受信してその情報を制御に用いる場合、それぞれのECUの制御内容によって、そのメッセージを「最新履歴採用型メッセージ」とするか「全履歴採用型メッセージ]とするかが異なる場合もありうる。
The
本実施形態では、第二種バッファ領域4fが、図5に示すFIFO(First In First Out)メモリとして構成されている。このようにすると、全履歴採用型メッセージK,X,Yを受信時系列の早いものから先に記憶し、かつ、受信時系列の早いものから先に取り出す機能を簡単に実現でき、アプリケーション側でメッセージ格納領域の、受信時系列に対応した煩雑なアドレス指定を行なう必要がなくなる。
In the present embodiment, the second
一方、制御用メッセージは、基準周期T0と同等もしくはそれよりも長い受信間隔を有する長周期更新型メッセージと、該基準周期T0よりも短い受信間隔を有する短周期更新型メッセージとを車内ネットワークから受信することもできる。この場合、転送スケジューラは、短周期更新型メッセージを選択的にRAM内バッファ領域4e,4fに転送するものとして構成することができる。図7において、メッセージΩが長周期更新型メッセージに該当し、メッセージA,B,C,K,X,Yが短周期更新型メッセージに該当する。
On the other hand, the control message receives a long-period update type message having a reception interval equal to or longer than the reference period T0 and a short-period update type message having a reception interval shorter than the reference period T0 from the in-vehicle network. You can also In this case, the transfer scheduler can be configured to selectively transfer the short cycle update type message to the
メッセージ取得指令手段は、長周期更新型メッセージΩを受信バッファメモリ7に受信した場合は、基準周期T0と同期した予め定められたタイミングにて、受信バッファメモリ7から長周期更新型メッセージΩを取得することを、対応するアプリケーションに指令する(第一処理)。一方、短周期更新型メッセージA,B,C,K,X,Yを受信バッファメモリ7に受信した場合は、基準周期T0と同期した予め定められたタイミングにて、RAM内バッファ領域4e,4fから制御用メッセージを取得することを、対応するアプリケーションに指令する(最新履歴採用型メッセージA,B,Cについては、第一種バッファ領域4eが指定される第二処理、全履歴採用型メッセージK,X,Yについては、第二種バッファ領域4fが指定される第三処理)。これにより、短周期更新型メッセージA,B,C,K,X,YについてのみRAM内バッファ領域4e,4fを確保すればよいのでメモリの節約に貢献し、また、転送スケジューラによるメッセージの転送処理負荷も軽減できる。
When the long-period update message Ω is received by the
なお、以下の説明では、長周期更新型メッセージΩを第一種メッセージ、短周期更新型メッセージであって最新履歴採用型メッセージであるメッセージA,B,Cを第二種メッセージ、短周期更新型メッセージであって全履歴採用型メッセージであるメッセージK,X,Yを第三種メッセージとも称する。 In the following description, the long-period update type message Ω is the first type message, the short-cycle update type message and the latest history adoption type messages A, B, and C are the second type message, the short-cycle update type. Messages K, X, and Y that are messages and are all history-adopted messages are also referred to as third-type messages.
なお、本実施形態では、受信バッファメモリ7内に長周期更新型メッセージ専用の記憶領域と、短周期更新型メッセージ専用の記憶領域とを個別に設けられている。そして、長周期更新型メッセージ用の転送スケジューラ及びメッセージ取得指令手段の機能実現処理と、短周期更新型メッセージ用の転送スケジューラ及びメッセージ取得指令手段の機能実現処理とは、記憶領域毎に各々一義的に起動されるようにしておけば、ソフトウェア構成の明確化及び簡略化を図ることができ、処理効率も向上する。具体的には、[0]には、長周期更新型メッセージΩに対応した種別コードのメッセージのみが格納され、[1]〜[n−1]には短周期更新型メッセージA,B,C,K,X,Yの種別コードのメッセージのみが格納されるようにしておく。そして、各アプリケーションにメッセージ取得を指示する際には、長周期更新型メッセージΩについてはメッセージ取得先として常に、受信バッファメモリ7の領域[0]を指定し、短周期更新型メッセージA,B,C,K,X,Yについては、メッセージ取得先として常に、受信バッファメモリ7の領域[1]〜[n−1]に対応するRAM内バッファ領域を指定するようにしておけばよいのである。
In the present embodiment, a storage area dedicated to long-period update type messages and a storage area dedicated to short-period update type messages are individually provided in the
また、制御用メッセージは、一定の受信間隔を有する定期更新型メッセージと、受信間隔が不定の不定期更新型メッセージとを車内ネットワークから受信することもできる。図7において、メッセージΩ,A,B,C,K,X,Yが定期更新型メッセージ、メッセージZが不定期更新型メッセージに該当する。メッセージ取得指令手段は、定期更新型メッセージΩ,A,B,C,K,X,Yについてのみ、基準周期と同期した予め定められたタイミングにて、対応するアプリケーションに対し、RAM内バッファ領域4e,4fから制御用メッセージを取得することを指令するものとして構成することができる。
In addition, the control message can be received from the in-vehicle network a regular update type message having a fixed reception interval and an irregular update type message having an indefinite reception interval. In FIG. 7, messages Ω, A, B, C, K, X, and Y correspond to regular update messages, and message Z corresponds to irregular update messages. The message acquisition command means sends the
また、不定期更新型メッセージZ(以下、第四種メッセージともいう)を受信した場合に、その受信タイミングと同期させた割り込み処理により、当該不定期更新型メッセージの受信バッファメモリ7からの取得を、対応するアプリケーションに指令する割り込み指令手段(メッセージ転送制御プログラム5dにより機能実現される)が設けられる。受信した制御用メッセージは、バッファメモリコントローラ6(図1)における種別コードの照合により、不定期更新型メッセージであるか否かを直ちに判断することができる。そして、不定期更新型メッセージであった場合には、バッファメモリコントローラ6が割り込み信号を入出力部2の割り込み端子INTに入力する。メッセージ転送制御プログラム5dは割り込み端子INTへの入力を監視しており、入力があった場合には対応するアプリケーションに対し、割り込み時にアクセス先として定められている受信バッファメモリの格納領域(図7の[n])から、制御用メッセージZを取得することを指令する。
In addition, when an irregularly updated message Z (hereinafter also referred to as a fourth type message) is received, acquisition of the irregularly updated message from the
上記の方法では、予不定期更新型メッセージZとして予め定められたものについてのみ、受信タイミングと同期させた割り込み処理により、当該不定期更新型メッセージの取得を対応するアプリケーションに指令するようにしたから、例えば更新優先度の特に高いメッセージを不定期更新型メッセージZとして指定することで、そのメッセージ内容更新の頻度と信頼性を向上できる。それ以外の定期更新型メッセージについては、転送スケジューラによりRAM内バッファ領域4e,4fにメッセージを転送し、そのRAM内バッファ領域4e,4fからのメッセージ取得を指令する形となるので、割り込み処理の頻度が過剰となって処理負荷が増大してしまう不具合の回避を図る効果も同時に達成できる。
In the above method, only a predetermined message as the pre-regular update type message Z is instructed to the corresponding application to acquire the irregular update type message by interrupt processing synchronized with the reception timing. For example, by designating a message having a particularly high update priority as the irregular update type message Z, the frequency and reliability of the message content update can be improved. For other periodic update type messages, the transfer scheduler transfers the message to the
図8は、図7の実施形態に対応したメッセージ転送制御プログラム5dの処理概要を示すフローチャートである。S101では、受信したメッセージの種別を種別コードから特定する。第一種メッセージの場合は、図9に示すごとく、アプリケーション起動スケジューラの実行周期T0の先頭で、受信バッファメモリ7の格納領域[0]からのメッセージ取得が、対応するアプリケーションに通知される(第一処理:このジョブは、本実施形態では、アプリケーション起動スケジューラ内に組み入れられており、ただし、前者であれば、スケジューラの起動トリガをメッセージ転送制御プログラム5d側にも与える必要がある)。
FIG. 8 is a flowchart showing an outline of processing of the message transfer control program 5d corresponding to the embodiment of FIG. In S101, the type of the received message is specified from the type code. In the case of the first type message, as shown in FIG. 9, at the beginning of the execution period T0 of the application startup scheduler, message acquisition from the storage area [0] of the
また、第二種メッセージであれば、S103からS108に進み、バッファメモリコントローラ7に対し、受信バッファメモリ7の格納領域[1]〜[4]に格納されたメッセージの転送を指令し、S109では、その転送されてくるメッセージを、第一種バッファ領域4e(メッセージ別バッファメモリ)の対応する格納領域に格納する(第二処理:メッセージ転送スケジューラの機能が実現している)。メッセージ転送制御プログラムの実行周期T1はこれで完了するが、図10に示す該周期T1は、図9のアプリケーション起動スケジューラの実行周期をなす基準周期T0よりも短い。他方、第一種バッファ領域4eの対応する格納領域からのメッセージ取得を、対応するアプリケーションに通知する処理は、図9のアプリケーション起動スケジューラの先頭で実施され、結果としてその通知処理の実行間隔は、基準周期T0、つまりアプリケーションの実行周期と一致することとなる。なお、第三種メッセージの場合の処理も、転送されてくるメッセージの格納先が第二種バッファ領域4f(FIFOバッファメモリ)となる点を除き、第二種メッセージの場合と同じである(第三処理)。さらに、第四種メッセージの場合は、バッファメモリコントローラ6が主体となって前述の割り込み処理が実行される(第四処理)。
If it is the second type message, the process proceeds from S103 to S108, and the
図12は、上記の第一処理〜第四処理を対比して示す模式的なタイミング図である。第二処理及び第三処理が、メッセージ転送スケジューラにより基準周期T0よりも短い周期T1にてRAM内バッファ領域に転送・退避されるので、短周期のメッセージ受信/取得にも問題なく対応できることがわかる。他方、メッセージ取得の間隔をより短くする必要がある特殊なメッセージについては、割り込み処理を用いる第四処理により対応可能である。 FIG. 12 is a schematic timing chart showing the first to fourth processes in comparison. Since the second process and the third process are transferred and saved to the buffer area in the RAM at a cycle T1 shorter than the reference cycle T0 by the message transfer scheduler, it can be understood that the message reception / acquisition with a short cycle can be handled without any problem. . On the other hand, a special message that requires a shorter message acquisition interval can be handled by the fourth process using the interrupt process.
1 ECU(ハードウェア制御主体:自動車用制御装置)
4 RAM
4e,4f RAM内バッファ領域
5 ROM
5d メッセージ転送制御プログラム
7 受信バッファメモリ
1 ECU (Hardware control subject: Automotive control device)
4 RAM
4e, 4f RAM buffer area 5 ROM
5d Message
Claims (6)
前記アプリケーションの実行主体となるCPUと、
前記複数のアプリケーションを実行するためのワークエリアとなるRAMと、
複数の前記アプリケーションを、予め定められた順序にて基準周期のサイクルにて順次起動するアプリケーション起動スケジューラと、
前記自動車用制御装置の制御主体を構成するハードウェア制御主体が車内ネットワークを介して受信する、前記アプリケーション上にて使用する制御用メッセージを一時的に格納するために、前記RAMとは別に設けられた受信バッファメモリと、
前記受信バッファメモリに格納された制御用メッセージを、前記基準周期よりも短く設定された転送周期にて前記RAM内に設けられたRAM内バッファ領域に転送するメッセージ転送スケジューラと、
前記基準周期と同期した予め定められたタイミングにて、前記RAM内バッファ領域から前記制御用メッセージを取得することを、対応するアプリケーションに指令するメッセージ取得指令手段と、を備え、
前記制御用メッセージとして、前記基準周期からなる前記アプリケーションの実行周期内にて、最新メッセージのみが使用される最新履歴採用型メッセージと、前記実行周期内にて受信した全メッセージを使用する全履歴採用型メッセージとを前記車内ネットワークから受信するようになっており、
前記RAM内バッファ領域は、前記制御用メッセージの最新のもののみが随時上書き更新される形で書き込まれる第一種バッファ領域と、前記受信メッセージを受信時系列順に個別に記憶する第二種バッファ領域とを有することを特徴とする自動車用制御装置。 Vehicle control for realizing a plurality of control means provided corresponding to the controlled elements in order to control electric operations of the controlled elements on the vehicle by a plurality of applications corresponding to the respective control means A device,
A CPU that is the execution subject of the application;
RAM serving as a work area for executing the plurality of applications;
An application activation scheduler that sequentially activates the plurality of applications in a cycle of a reference period in a predetermined order;
In order to temporarily store a control message used on the application, which is received by the hardware control main body constituting the control main body of the vehicle control apparatus, via the in-vehicle network, it is provided separately from the RAM. Receive buffer memory,
A message transfer scheduler for transferring a control message stored in the reception buffer memory to a buffer area in the RAM provided in the RAM at a transfer period set shorter than the reference period;
Message acquisition instruction means for instructing a corresponding application to acquire the control message from the buffer area in the RAM at a predetermined timing synchronized with the reference period ,
As the control message, the latest history adoption type message that uses only the latest message within the execution cycle of the application consisting of the reference cycle, and the entire history adoption that uses all messages received within the execution cycle. Type message from the in-vehicle network,
The buffer area in RAM is a first type buffer area in which only the latest control message is overwritten and updated as needed, and a second type buffer area for individually storing the received messages in the order of reception time series. And a control apparatus for an automobile.
前記メッセージ取得指令手段は、前記長周期更新型メッセージを前記受信バッファメモリに受信した場合は、前記基準周期と同期した予め定められたタイミングにて、前記受信バッファメモリから前記長周期更新型メッセージを取得することを、対応するアプリケーションに指令する一方、前記短周期更新型メッセージを前記受信バッファメモリに受信した場合は、前記基準周期と同期した予め定められたタイミングにて、前記RAM内バッファ領域から前記制御用メッセージを取得することを、対応するアプリケーションに指令する請求項1ないし請求項4のいずれか1項に記載の自動車用制御装置。 As the control message, a long cycle update type message having a reception interval equal to or longer than the reference cycle and a short cycle update type message having a reception interval shorter than the reference cycle are received from the in-vehicle network. The transfer scheduler is configured to selectively transfer the short cycle update type message to the buffer area in the RAM,
When the long-period update type message is received by the reception buffer memory, the message acquisition command means sends the long-period update type message from the reception buffer memory at a predetermined timing synchronized with the reference period. When the corresponding application is instructed to be acquired and the short cycle update type message is received in the reception buffer memory, the buffer is stored in the RAM buffer area at a predetermined timing synchronized with the reference cycle. The automobile control device according to any one of claims 1 to 4 , which instructs a corresponding application to acquire the control message.
他方、前記不定期更新型メッセージを受信した場合に、その受信タイミングと同期させた割り込み処理により、当該不定期更新型メッセージの前記受信バッファメモリからの取得を、対応するアプリケーションに指令する割り込み指令手段が設けられている請求項1ないし請求項5のいずれか1項に記載の自動車用制御装置。 As the control message, a periodic update type message having a constant reception cycle and an irregular update type message having an indefinite reception cycle are received from the in-vehicle network. Only for the periodic update type message, at a predetermined timing synchronized with the reference period, the corresponding application is instructed to acquire the control message from the buffer area in the RAM,
On the other hand, when the irregularly updated message is received, interrupt command means for commanding the corresponding application to acquire the irregularly updated message from the reception buffer memory by interrupt processing synchronized with the reception timing. The control apparatus for motor vehicles of any one of Claim 1 thru | or 5 provided with these.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005051152A JP4419192B2 (en) | 2005-02-25 | 2005-02-25 | Automotive control device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005051152A JP4419192B2 (en) | 2005-02-25 | 2005-02-25 | Automotive control device |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2006236089A JP2006236089A (en) | 2006-09-07 |
JP4419192B2 true JP4419192B2 (en) | 2010-02-24 |
Family
ID=37043656
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005051152A Expired - Fee Related JP4419192B2 (en) | 2005-02-25 | 2005-02-25 | Automotive control device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP4419192B2 (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5029123B2 (en) * | 2007-04-25 | 2012-09-19 | 株式会社デンソー | Electronic control device and communication system |
DE112011105318T5 (en) * | 2011-06-09 | 2014-03-06 | Mitsubishi Electric Corporation | Programmable controller system |
KR101821068B1 (en) * | 2013-06-25 | 2018-01-22 | 미쓰비시덴키 가부시키가이샤 | Programmable controller |
JP2018160851A (en) * | 2017-03-23 | 2018-10-11 | 株式会社オートネットワーク技術研究所 | On-vehicle communication device, computer program, and message determination method |
-
2005
- 2005-02-25 JP JP2005051152A patent/JP4419192B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2006236089A (en) | 2006-09-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10678454B2 (en) | Vehicle information communication system | |
US20170197631A1 (en) | System and method for applying vehicle settings in a vehicle | |
WO2018142750A1 (en) | Control device, program updating method, and computer program | |
US10850685B2 (en) | Onboard relay device, information processing method, storage medium storing program, relay device, and information processing system | |
JP2007028632A (en) | Communication method and apparatus for automobile | |
JP2005132131A (en) | Software updating device, and software updating method | |
US20080104438A1 (en) | Microcomputer, program and on-vehicle electronic controller | |
US20090234514A1 (en) | Method and Device for Executing Prioritized Control Processes | |
JP2021048477A (en) | Vehicle network system | |
JP4419192B2 (en) | Automotive control device | |
JP7503013B2 (en) | Electronic control device and method for starting electronic control device | |
EP4122775A1 (en) | Software update device, software update method, and software update processing program | |
JP2014028547A (en) | On-vehicle network system | |
US20240004640A1 (en) | Computer-Implemented Method And Device For The Automated Update Of A Communication Unit Of A Control Unit Of A Vehicle | |
JP2006150999A (en) | Control device for automobile | |
US11620125B2 (en) | Software update device, software update method, non-transitory storage medium, and vehicle | |
US20220300274A1 (en) | Program update control apparatus, program update control method, and computer-readable storage medium | |
JP4457306B2 (en) | Automotive control unit | |
US12074952B2 (en) | Software update device, software update method, and center | |
JP4446170B2 (en) | Automotive sleep control system | |
JP4446169B2 (en) | Automotive control device | |
JP2007001420A (en) | Control unit for vehicle | |
EP3971708B1 (en) | In-vehicle device, software update method, non-transitory storage medium, vehicle, and electronic control unit | |
Yi et al. | Power saving using Partial Networking in automotive system | |
WO2024111370A1 (en) | Update management device, update management system, and computer program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20070416 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20090710 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20090716 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20090902 |
|
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: 20091109 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20091122 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20121211 Year of fee payment: 3 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 4419192 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20121211 Year of fee payment: 3 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20131211 Year of fee payment: 4 |
|
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 |
|
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 |
|
LAPS | Cancellation because of no payment of annual fees |