JP2019045951A - Vehicle information memory device - Google Patents

Vehicle information memory device Download PDF

Info

Publication number
JP2019045951A
JP2019045951A JP2017165456A JP2017165456A JP2019045951A JP 2019045951 A JP2019045951 A JP 2019045951A JP 2017165456 A JP2017165456 A JP 2017165456A JP 2017165456 A JP2017165456 A JP 2017165456A JP 2019045951 A JP2019045951 A JP 2019045951A
Authority
JP
Japan
Prior art keywords
storage area
rewrites
vehicle information
stored
volatile memory
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.)
Granted
Application number
JP2017165456A
Other languages
Japanese (ja)
Other versions
JP6975581B2 (en
Inventor
貴矩敬 寛
Kikutaka Hiroshi
貴矩敬 寛
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.)
Keihin Corp
Original Assignee
Keihin Corp
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 Keihin Corp filed Critical Keihin Corp
Priority to JP2017165456A priority Critical patent/JP6975581B2/en
Publication of JP2019045951A publication Critical patent/JP2019045951A/en
Application granted granted Critical
Publication of JP6975581B2 publication Critical patent/JP6975581B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

To provide a vehicle information memory device capable of securing reliability of stored data while reducing the use capacity of a non-volatile memory.SOLUTION: In a vehicle failure diagnosis system 10, a memory control unit 28 of an engine ECU 12 writes the number of rewrites Nr1 read from a first number storage area 30n in a volatile memory 26 before starting an update of a first information storage area 30v, and writes an unused value not used for counting the number of rewrites Nr1 in the first number storage area 30n. The memory control unit 28 performs memory control to count and update the number of rewrites Nr1 read from the volatile memory 26 after the update of the first information storage area 30v is completed and to write the same in the first number storage area 30n.SELECTED DRAWING: Figure 1

Description

本発明は、車両に搭載され、かつ、当該車両の状態を示す車両情報を記憶する車両情報記憶装置に関する。   The present invention relates to a vehicle information storage device mounted on a vehicle and storing vehicle information indicating the state of the vehicle.

従来から、車両に搭載され、かつ、当該車両の状態を示す車両情報を記憶する車両情報記憶装置が知られている。例えば、車両の自己診断機能(OBD;On-Board Diagnostics)に関して、不揮発性メモリに逐次記憶される故障診断情報の信頼性を高めるための技術が種々提案されている。   BACKGROUND Conventionally, a vehicle information storage device mounted on a vehicle and storing vehicle information indicating the state of the vehicle is known. For example, various techniques have been proposed for improving the reliability of failure diagnosis information sequentially stored in a non-volatile memory with respect to a vehicle self-diagnosis function (OBD; On-Board Diagnostics).

特許文献1では、同一の故障コード(DTC;Diagnostic Trouble Code)を3つの記憶領域に記憶させておき、データの多数決を採ることで、不揮発性メモリの記憶状態に関する異常を判定する装置が提案されている。   Patent Document 1 proposes an apparatus for determining an abnormality related to the storage state of a non-volatile memory by storing the same failure code (DTC; Diagnostic Trouble Code) in three storage areas and taking majority of data. ing.

特許第4475320号公報Patent 4475320 gazette

近時、OBD2に対応したエンジンECU(Electronic Control Unit;電子制御装置)が普及しつつある。このECUは、故障コードのみならず、当該故障コードを生成した瞬間のフリーズフレームデータを同時に記憶する。   Recently, engine ECUs (Electronic Control Units) compatible with the OBD 2 are becoming widespread. The ECU simultaneously stores not only the failure code but also freeze frame data at the moment when the failure code is generated.

しかしながら、特許文献1で提案された装置では、多数決のために3組の記憶領域を常に用意する必要があるため、2組の場合と比べて、不揮発性メモリの使用容量が50%だけ増加してしまう。この使用容量は、フリーズフレームデータのサイズに概ね比例するため、この問題が顕著に現われる。   However, in the device proposed in Patent Document 1, since it is necessary to always prepare three sets of storage areas for majority, the use capacity of nonvolatile memory is increased by 50% as compared with the case of two sets. It will This problem is noticeable because this used capacity is roughly proportional to the size of freeze frame data.

本発明は上記した問題を解決するためになされたものであり、不揮発性メモリの使用容量を減らしつつ、記憶データの信頼性を確保可能な車両情報記憶装置を提供することを目的とする。   The present invention has been made to solve the above-described problems, and it is an object of the present invention to provide a vehicle information storage device capable of securing the reliability of stored data while reducing the used capacity of the nonvolatile memory.

本発明に係る車両情報記憶装置は、車両に搭載され、かつ、前記車両の状態を示す車両情報を記憶する装置であって、第1記憶領域及び第2記憶領域を有する不揮発性メモリと、前記車両情報の書換回数を少なくとも記憶する揮発性メモリと、前記不揮発性メモリ及び前記揮発性メモリに対する記憶制御を行う記憶制御部と、を備え、前記第1記憶領域は、前記車両情報が格納される第1情報格納領域と、前記書換回数が格納される第1回数格納領域と、を含み、前記第2記憶領域は、前記車両情報が格納される第2情報格納領域と、前記書換回数が格納される第2回数格納領域と、を含み、前記記憶制御部は、前記第1情報格納領域の更新を開始する前に、前記第1回数格納領域から読み出した前記書換回数を前記揮発性メモリに書き込み、かつ、前記書換回数のカウントに使用しない不使用値を前記第1回数格納領域に書き込み、前記第1情報格納領域の更新が終了した後に、前記揮発性メモリから読み出した前記書換回数をカウント更新し、かつ、前記第1回数格納領域に書き込む記憶制御を行い、前記第2情報格納領域の更新を開始する前に、前記第2回数格納領域から読み出した前記書換回数を前記揮発性メモリに書き込み、かつ、前記書換回数のカウントに使用しない不使用値を前記第2回数格納領域に書き込み、前記第2情報格納領域の更新が終了した後に、前記揮発性メモリから読み出した前記書換回数をカウント更新し、かつ、前記第2回数格納領域に書き込む記憶制御を行う。   A vehicle information storage device according to the present invention is a device mounted on a vehicle and storing vehicle information indicating a state of the vehicle, the non-volatile memory having a first storage area and a second storage area, and A volatile memory storing at least the number of times of rewriting of vehicle information, and a storage control unit performing storage control for the non-volatile memory and the volatile memory, the first storage area stores the vehicle information A first information storage area and a first number storage area in which the number of rewrites is stored, the second storage area stores a second information storage area in which the vehicle information is stored, and the number of rewrites is stored And the storage control unit is configured to store the number of rewrites read from the first number storage area before starting the update of the first information storage area to the volatile memory. writing And writing a nonuse value not used for counting the number of rewrites in the first number storage area, counting and updating the number of rewrites read from the volatile memory after updating of the first information storage area is completed And performing storage control of writing in the first number storage area, and writing the number of rewrites read from the second number storage area in the volatile memory before starting updating the second information storage area; And writing a nonuse value not used for counting the number of rewrites in the second number storage area, counting and updating the number of rewrites read from the volatile memory after updating of the second information storage area is completed And performs storage control to write in the second number storage area.

このように構成することで、例えば、電力の瞬断によって揮発性メモリに一時的に記憶された情報が消失した場合であっても、現在格納されている2つの書換回数の数値関係(単独値又は相対値)に基づいて第1記憶領域及び第2記憶領域の更新状況を判別可能となり、その後に必要な対処を施すことで記憶データを適切に復旧することができる。これにより、不揮発性メモリの使用容量を減らしつつ、記憶データの信頼性を確保することができる。   By configuring in this way, for example, even when the information temporarily stored in the volatile memory is lost due to a momentary power loss, the numerical relationship between the number of times of rewriting currently stored (a single value Alternatively, the update status of the first storage area and the second storage area can be determined based on the relative value), and the stored data can be properly recovered by performing the necessary measures thereafter. Thereby, the reliability of stored data can be ensured while reducing the used capacity of the nonvolatile memory.

また、前記記憶制御部は、前記第1回数格納領域に格納された前記書換回数が前記不使用値であって、かつ、前記第2回数格納領域に格納された前記書換回数が前記不使用値でない場合、前記第2回数格納領域の前記書換回数を複製して前記第1回数格納領域に書き込むと共に、前記第2情報格納領域の前記車両情報を複製して前記第1情報格納領域に書き込む記憶制御を行い、前記第1回数格納領域に格納された前記書換回数が前記不使用値でなく、かつ、前記第2回数格納領域に格納された前記書換回数が前記不使用値である場合、前記第1回数格納領域の前記書換回数を複製して前記第2回数格納領域に書き込むと共に、前記第1情報格納領域の前記車両情報を複製して前記第2情報格納領域に書き込む記憶制御を行ってもよい。   In the storage control unit, the number of rewrites stored in the first number storage area is the nonuse value, and the number of rewrites stored in the second number storage area is the nonuse value If not, the number of rewrites in the second number storage area is copied and written in the first number storage area, and the vehicle information in the second information storage area is copied and written in the first information storage area The control is performed, and the number of rewrites stored in the first number storage area is not the nonuse value, and the number of rewrites stored in the second number storage area is the nonuse value. A storage control is performed in which the number of times of rewriting of the first number storage area is copied and written in the second number storage area, and the vehicle information of the first information storage area is copied and written in the second information storage area It is also good.

これにより、書換回数が不使用値である一方の記憶領域が更新中である状態において、他方の記憶領域から書換回数及び車両情報を複製することで直近の記憶状態に戻すことができる。   As a result, in a state in which one of the storage areas whose number of rewrites is an unused value is being updated, the number of rewrites and the vehicle information can be copied from the other storage area to restore the latest storage state.

また、前記記憶制御部は、前記第1回数格納領域に格納された前記書換回数が、前記第2回数格納領域に格納された前記書換回数よりも大きい場合、前記第1情報格納領域の前記車両情報を複製し、前記第2情報格納領域に書き込む記憶制御を行い、前記第1回数格納領域に格納された前記書換回数が、前記第2回数格納領域に格納された前記書換回数よりも小さい場合、前記第2情報格納領域の前記車両情報を複製し、前記第1情報格納領域に書き込む記憶制御を行ってもよい。   Further, the storage control unit is configured to, when the number of rewrites stored in the first number storage area is larger than the number of rewrites stored in the second number storage area, the vehicle of the first information storage area Storage control is performed to copy information and write in the second information storage area, and the number of rewrites stored in the first number storage area is smaller than the number of rewrites stored in the second number storage area The storage control may be performed to copy the vehicle information in the second information storage area and write it in the first information storage area.

これにより、書換回数が大きい一方の記憶領域が更新後であり、かつ、他方の記憶領域が更新前である状態において、一方の記憶領域から車両情報を複製することで最新の記憶状態に移行することができる。   As a result, in a state in which one storage area having a large number of rewrites is updated and the other storage area is before update, the vehicle information is copied from one storage area to shift to the latest storage state. be able to.

また、前記記憶制御部は、前記車両情報を複製する記憶制御が完了するまでの間、前記複製以外の前記第1記憶領域及び前記第2記憶領域への書き込みを行わないようにしてもよい。記憶データの復旧中に複製以外の書き込みを禁止することで、記憶状態に関する異常の発生を防止することができる。   Further, the storage control unit may not write to the first storage area and the second storage area other than the copy until the storage control for copying the vehicle information is completed. By prohibiting writing other than duplication during recovery of stored data, it is possible to prevent occurrence of an abnormality relating to the storage state.

また、当該車両情報記憶装置は、前記車両のイグニッションスイッチのオフ動作に応じて電力の供給を停止されてもよい。エンジンを切った後のセルフシャットダウン機能を備えていない車両では、揮発性メモリのデータバックアップを取得できないので特に効果的である。   Further, the vehicle information storage device may stop the supply of power in response to the turning-off operation of the ignition switch of the vehicle. Vehicles that do not have a self-shutdown function after the engine is turned off are particularly effective because they can not obtain volatile memory data backup.

本発明に係る車両情報記憶装置によれば、不揮発性メモリの使用容量を減らしつつ、記憶データの信頼性を確保することができる。   According to the vehicle information storage device of the present invention, it is possible to secure the reliability of stored data while reducing the used capacity of the non-volatile memory.

本発明の一実施形態における車両情報記憶装置が組み込まれた車両故障診断システムの全体構成図である。BRIEF DESCRIPTION OF THE DRAWINGS It is a whole block diagram of the vehicle failure diagnostic system incorporating the vehicle information storage apparatus in one Embodiment of this invention. 図1に示す不揮発性メモリ及び揮発性メモリの記憶状態に関する遷移図である。It is a transition diagram regarding the storage state of the non-volatile memory shown in FIG. 1, and volatile memory. 各々の区間における記憶制御の特徴を模式的に示す図である。It is a figure which shows typically the characteristic of the storage control in each area.

以下、本発明に係る車両情報記憶装置について好適な実施形態を挙げ、添付の図面を参照しながら説明する。   Hereinafter, preferred embodiments of a vehicle information storage device according to the present invention will be described and described with reference to the accompanying drawings.

[車両故障診断システム10の構成]
図1は、本発明の一実施形態における車両情報記憶装置が組み込まれた車両故障診断システム10の全体構成図である。車両故障診断システム10は、図示しない車両(例えば、二輪車又は四輪車)に搭載され、かつ、この車両の自己診断機能を有するシステムである。この車両故障診断システム10は、車両情報記憶装置としてのエンジンECU12と、センサ群14と、エンジン16と、電源18と、を含んで構成される。
[Configuration of Vehicle Failure Diagnosis System 10]
FIG. 1 is an overall configuration diagram of a vehicle failure diagnosis system 10 in which a vehicle information storage device according to an embodiment of the present invention is incorporated. The vehicle failure diagnosis system 10 is a system mounted on a vehicle (for example, a two-wheeled vehicle or a four-wheeled vehicle) not shown and having a self-diagnosis function of the vehicle. The vehicle failure diagnosis system 10 includes an engine ECU 12 as a vehicle information storage device, a sensor group 14, an engine 16, and a power supply 18.

センサ群14は、車両の状態を検出可能な1つ又は複数のセンサから構成される。センサの種類として、例えば、水温センサ、油温センサ、車速センサ、クランク角センサ、吸気圧センサ、大気圧センサ、スロットル開度センサ、O2センサが挙げられる。   The sensor group 14 includes one or more sensors capable of detecting the state of the vehicle. Examples of the sensor include a water temperature sensor, an oil temperature sensor, a vehicle speed sensor, a crank angle sensor, an intake pressure sensor, an atmospheric pressure sensor, a throttle opening sensor, and an O 2 sensor.

電源18は、車両の各部(エンジンECU12を含む)に対して電力を供給する。ここでは、電源18は、イグニッションスイッチ20のオン・オフに連動して、エンジンECU12に対して電力を供給し、又はその供給を停止する。   The power supply 18 supplies power to each part of the vehicle (including the engine ECU 12). Here, the power supply 18 supplies power to the engine ECU 12 or stops the supply thereof in conjunction with on / off of the ignition switch 20.

エンジンECU12は、車両の駆動源であるエンジン16の運転制御を行い、必要に応じて車両の状態を示す情報(以下、車両情報)を取得し保存する。具体的には、エンジンECU12は、演算処理装置22と、不揮発性メモリ24と、揮発性メモリ26と、を含んで構成される。   The engine ECU 12 performs operation control of the engine 16 which is a drive source of the vehicle, and acquires and stores information indicating the state of the vehicle (hereinafter, vehicle information) as needed. Specifically, the engine ECU 12 is configured to include an arithmetic processing unit 22, a non-volatile memory 24, and a volatile memory 26.

演算処理装置22は、例えば、CPU(Central Processing Unit)又はMPU(Micro-Processing Unit)から構成される。演算処理装置22は、図示しないROM(Read Only Memory)からプログラムを読み出し実行することで、不揮発性メモリ24及び揮発性メモリ26に対する記憶制御を行う記憶制御部28として機能する。   The arithmetic processing unit 22 includes, for example, a central processing unit (CPU) or a micro-processing unit (MPU). The arithmetic processing unit 22 functions as a storage control unit 28 which performs storage control on the nonvolatile memory 24 and the volatile memory 26 by reading and executing a program from a ROM (Read Only Memory) not shown.

不揮発性メモリ24は、電力を供給しなくても記憶データを保持可能なメモリであり、例えば、EEPROM(Electrically Erasable Programmable Read-Only Memory)、フラッシュメモリから構成される。不揮発性メモリ24は、領域サイズが等しい2つの記憶領域(以下、第1記憶領域30、第2記憶領域32)を有する。   The non-volatile memory 24 is a memory capable of holding stored data without supplying power, and is constituted of, for example, an EEPROM (Electrically Erasable Programmable Read-Only Memory) and a flash memory. The nonvolatile memory 24 has two storage areas (hereinafter, the first storage area 30 and the second storage area 32) having the same area size.

第1記憶領域30は、1個の書換回数Nr1が格納される第1回数格納領域30nと、M組(M≧1)の車両情報Iv1が格納される第1情報格納領域30vと、を含む。第2記憶領域32は、1個の書換回数Nr2が格納される第2回数格納領域32nと、M組(M≧1)の車両情報Iv2が格納される第2情報格納領域32vと、を含む。   The first storage area 30 includes a first count storage area 30n in which one rewrite count Nr1 is stored, and a first information storage area 30v in which M sets (M ≧ 1) of vehicle information Iv1 are stored. . The second storage area 32 includes a second count storage area 32n in which one rewrite count Nr2 is stored, and a second information storage area 32v in which M sets (M ≧ 1) of vehicle information Iv2 are stored. .

なお、書換回数Nr1は第1記憶領域30の書き換え(車両情報Iv1の更新)に成功した回数であり、書換回数Nr2は第2記憶領域32の書き換え(車両情報Iv2の更新)に成功した回数である。また、車両情報Iv1、Iv2は、例えば、故障コード(DTC)及びフリーズフレームデータ(センサ値の時系列)の1セット分の情報に相当する。   The number of rewrites Nr1 is the number of successful rewrites of the first storage area 30 (update of the vehicle information Iv1), and the number of rewrites Nr2 is the number of successful rewrites of the second storage area 32 (update of the vehicle information Iv2). is there. The vehicle information Iv1 and Iv2 correspond to, for example, information of one set of failure code (DTC) and freeze frame data (time series of sensor values).

揮発性メモリ26は、電力が供給された状態下にのみ記憶データを保持可能なメモリであり、例えば、DRAM(Dynamic Random Access Memory)又はSRAM(Static Random Access Memory)から構成される。揮発性メモリ26は、記憶制御に必要な情報(具体的には、第1書換回数A、第2書換回数B、最新車両情報Iv)が一時的に格納される記憶領域34を有する。   The volatile memory 26 is a memory that can hold stored data only when power is supplied, and is configured of, for example, a dynamic random access memory (DRAM) or a static random access memory (SRAM). The volatile memory 26 has a storage area 34 in which information necessary for storage control (specifically, the first rewrite frequency A, the second rewrite frequency B, and the latest vehicle information Iv) is temporarily stored.

[エンジンECU12の動作]
車両情報記憶装置としてのエンジンECU12は、以上のように構成される。続いて、エンジンECU12(特に、記憶制御部28)の動作について、図2及び図3を参照しながら詳細に説明する。
[Operation of engine ECU 12]
The engine ECU 12 as a vehicle information storage device is configured as described above. Subsequently, the operation of the engine ECU 12 (in particular, the storage control unit 28) will be described in detail with reference to FIGS. 2 and 3.

図2は、図1に示す不揮発性メモリ24及び揮発性メモリ26の記憶状態に関する遷移図である。より詳しくは、本図は、各々の処理ステップS0〜S10での、第1記憶領域30、第2記憶領域32及び記憶領域34における格納値の段階的変化を示す。なお、格納値の更新があった箇所(格納領域)を太線の矩形枠によって表記している。   FIG. 2 is a transition diagram related to storage states of the non-volatile memory 24 and the volatile memory 26 shown in FIG. More specifically, this figure shows the stepwise change of the stored values in the first storage area 30, the second storage area 32, and the storage area 34 at each of the processing steps S0 to S10. In addition, the part (storage area) where the stored value was updated is described by the thick rectangular frame.

ステップS0は、5回目の書き換えが正常に行われた記憶状態に相当する。この場合、第1記憶領域30の書換回数Nr1(=5)は、第2記憶領域32の書換回数Nr2(=5)に等しい。また、第1記憶領域30の車両情報Iv1は、第2記憶領域32の車両情報Iv2とすべて一致する。なお、記憶制御部28の初期化動作により、記憶領域34には「NULL」の値が格納されている。   Step S0 corresponds to the storage state in which the fifth rewrite is normally performed. In this case, the number of times of rewriting Nr1 (= 5) of the first storage area 30 is equal to the number of times of rewriting Nr2 (= 5) of the second storage area 32. Further, all the vehicle information Iv1 of the first storage area 30 matches the vehicle information Iv2 of the second storage area 32. Note that the value “NULL” is stored in the storage area 34 by the initialization operation of the storage control unit 28.

ステップS1において、記憶制御部28は、センサ群14からの最新の車両情報(以下、最新車両情報Iv)を揮発性メモリ26に書き込むことで、最新車両情報Ivを一時的に記憶させる制御を行う。これにより、記憶領域34の格納値(最新車両情報Iv)が、「NULL」から「6回目の情報」に更新される。   In step S1, the storage control unit 28 performs control to temporarily store the latest vehicle information Iv by writing the latest vehicle information (hereinafter referred to as the latest vehicle information Iv) from the sensor group 14 in the volatile memory 26. . As a result, the stored value (latest vehicle information Iv) of the storage area 34 is updated from "NULL" to "sixth information".

ステップS2において、記憶制御部28は、第1記憶領域30の書換回数Nr1を不揮発性メモリ24から読み出し、揮発性メモリ26の記憶領域34に書き込むことで、最新車両情報Ivを一時的に記憶させる制御を行う。これにより、記憶領域34の格納値(第1書換回数A)が、「NULL」から「5」に更新される。   In step S2, the storage control unit 28 temporarily stores the latest vehicle information Iv by reading out the number of rewrites Nr1 of the first storage area 30 from the non-volatile memory 24 and writing it in the storage area 34 of the volatile memory 26. Take control. As a result, the stored value (first rewrite count A) of the storage area 34 is updated from “NULL” to “5”.

ステップS3において、記憶制御部28は、第1記憶領域30(具体的には、第1回数格納領域30n)の書換回数Nr1を、カウントに使用しない値(以下、不使用値という)に更新する制御を行う。この不使用値は、例えば0を含む、書換回数Nr1の運用範囲から逸脱した任意の値(具体的には、上限値よりも大きい値)であってもよい。   In step S3, the storage control unit 28 updates the number of rewrites Nr1 of the first storage area 30 (specifically, the first number storage area 30n) to a value not used for counting (hereinafter referred to as an unused value). Take control. This non-use value may be an arbitrary value (specifically, a value larger than the upper limit value) deviating from the operation range of the number of times of rewriting Nr1 including, for example, 0.

このように、記憶制御部28は、第1情報格納領域30vの更新を開始する前に、第1回数格納領域30nから読み出した書換回数Nr1を揮発性メモリ26に書き込み、かつ、書換回数Nr1のカウントに使用しない不使用値を第1回数格納領域30nに書き込む記憶制御を行う(ステップS2、S3)。   As described above, the storage control unit 28 writes the number of rewrites Nr1 read from the first number of storage areas 30n to the volatile memory 26 before starting the update of the first information storage area 30v, and the number of rewrites Nr1. Storage control is performed to write an unused value not used for counting in the first count storage area 30n (steps S2 and S3).

ステップS4において、記憶制御部28は、一時的に記憶された最新車両情報Ivを揮発性メモリ26から読み出し、不揮発性メモリ24の第1記憶領域30に書き込む制御を行う。これにより、第1情報格納領域30vの格納値(車両情報Iv1)が、「5回目の情報」から「6回目の情報」に更新される。   In step S4, the storage control unit 28 performs control to read out the temporarily stored latest vehicle information Iv from the volatile memory 26 and write it in the first storage area 30 of the non-volatile memory 24. As a result, the storage value (vehicle information Iv1) of the first information storage area 30v is updated from the "fifth information" to the "sixth information".

ステップS5において、記憶制御部28は、一時的に記憶された第1書換回数Aを揮発性メモリ26から読み出し、カウント更新(A←A+1)した後に、不揮発性メモリ24の第1記憶領域30に書き込む制御を行う。これにより、第1回数格納領域30nの格納値(書換回数Nr1)が、「0」から「6」に更新される。   In step S5, the storage control unit 28 reads the temporarily stored first rewriting number A from the volatile memory 26, updates the count (A (A + 1), and then stores it in the first storage area 30 of the non-volatile memory 24. Control writing. As a result, the stored value (number of rewrites Nr1) of the first number storage area 30n is updated from "0" to "6".

このように、記憶制御部28は、第1情報格納領域30vの更新が終了した後に、揮発性メモリ26から読み出した書換回数Nr1をカウント更新し、かつ、第1回数格納領域30nに書き込む記憶制御を行う(ステップS4、S5)。   As described above, the storage control unit 28 performs storage control to count and update the number of rewrites Nr1 read from the volatile memory 26 after the update of the first information storage area 30v is completed, and to write the same to the first count storage area 30n. (Steps S4 and S5).

ステップS6において、記憶制御部28は、第2記憶領域32の書換回数Nr2を不揮発性メモリ24から読み出し、揮発性メモリ26の記憶領域34に書き込むことで、書換回数Nr2を一時的に記憶させる制御を行う。これにより、記憶領域34の格納値(第2書換回数B)が、「NULL」から「5」に更新される。   In step S6, the storage control unit 28 controls the temporary storage of the number of rewrites Nr2 by reading the number of rewrites Nr2 of the second storage area 32 from the non-volatile memory 24 and writing it in the storage area 34 of the volatile memory 26. I do. As a result, the stored value (second rewrite count B) of the storage area 34 is updated from “NULL” to “5”.

ステップS7において、記憶制御部28は、第2記憶領域32(具体的には、第2回数格納領域32n)に格納された書換回数Nr2を、不使用値(0)に更新する制御を行う。ここで、書換回数Nr2の不使用値は、書換回数Nr1の不使用値と同一であってもよいし、異なっていてもよい。   In step S7, the storage control unit 28 performs control to update the number of rewrites Nr2 stored in the second storage area 32 (specifically, the second number storage area 32n) to the nonuse value (0). Here, the non-use value of the number of times of rewriting Nr2 may be the same as or different from the non-use value of the number of times of rewriting Nr1.

このように、記憶制御部28は、第2情報格納領域32vの更新を開始する前に、第2回数格納領域32nから読み出した書換回数Nr2を揮発性メモリ26に書き込み、かつ、書換回数Nr2のカウントに使用しない不使用値を第2回数格納領域32nに書き込む記憶制御を行う(ステップS6、S7)。   As described above, the storage control unit 28 writes the number of rewrites Nr2 read from the second number of storage areas 32n to the volatile memory 26 before starting the update of the second information storage area 32v, and the number of rewrites Nr2 Storage control is performed to write an unused value not used for counting in the second count storage area 32n (steps S6 and S7).

ステップS8において、記憶制御部28は、一時的に記憶された最新車両情報Ivを揮発性メモリ26から読み出し、不揮発性メモリ24の第2記憶領域32に書き込む制御を行う。これにより、第2情報格納領域32vの格納値(車両情報Iv2)が、「5回目の情報」から「6回目の情報」に更新される。   In step S <b> 8, the storage control unit 28 performs control of reading the temporarily stored latest vehicle information Iv from the volatile memory 26 and writing the latest vehicle information Iv in the second storage area 32 of the non-volatile memory 24. Thereby, the stored value (vehicle information Iv2) of the second information storage area 32v is updated from the "fifth information" to the "sixth information".

ステップS9において、記憶制御部28は、一時的に記憶された第2書換回数Bを揮発性メモリ26から読み出し、カウント更新(B←B+1)した後に、不揮発性メモリ24の第2記憶領域32に書き込む制御を行う。これにより、第2回数格納領域32nの格納値(書換回数Nr2)が、「0」から「6」に更新される。   In step S9, the storage control unit 28 reads the temporarily stored second rewrite count B from the volatile memory 26, updates the count (B B B + 1), and then stores it in the second storage area 32 of the non-volatile memory 24. Control writing. Thereby, the stored value (number of rewrites Nr2) of the second number storage area 32n is updated from "0" to "6".

このように、記憶制御部28は、第2情報格納領域32vの更新が終了した後に、揮発性メモリ26から読み出した書換回数Nr2をカウント更新し、かつ、第2回数格納領域32nに書き込む記憶制御を行う(ステップS8、S9)。   As described above, the storage control unit 28 performs storage control to count and update the number of rewrites Nr2 read from the volatile memory 26 after the update of the second information storage area 32v is completed, and to write the same to the second count storage area 32n. (Steps S8 and S9).

ステップS10は、6回目の書き換えが正常に行われた記憶状態に相当する。記憶制御部28の初期化動作により、記憶領域34には「NULL」の値が格納される。ここで、第1記憶領域30の書換回数Nr1(=6)は、第2記憶領域32の書換回数Nr2(=6)に等しい。また、第1記憶領域30の車両情報Iv1は、第2記憶領域32の車両情報Iv2とすべて一致する。   Step S10 corresponds to the storage state in which the sixth rewriting is normally performed. The value “NULL” is stored in the storage area 34 by the initialization operation of the storage control unit 28. Here, the number of times of rewriting Nr1 (= 6) of the first storage area 30 is equal to the number of times of rewriting Nr2 (= 6) of the second storage area 32. Further, all the vehicle information Iv1 of the first storage area 30 matches the vehicle information Iv2 of the second storage area 32.

図3は、各々の区間における記憶制御の特徴を模式的に示す図である。より詳しくは、本図は、状態チェック処理を実行した場合における、処理タイミング毎の記憶制御の挙動(イベント及び結果)を示す。   FIG. 3 is a diagram schematically showing the features of storage control in each section. More specifically, this figure shows the behavior (events and results) of storage control for each processing timing when the state check processing is performed.

ここで、「状態チェック」とは、不揮発性メモリ24の記憶状態に対する確認処理であり、具体的には、書換回数Nr1と、書換回数Nr2とが一致するか否かについて確認することを意味する。また、処理フェーズは、図2に示す10個の区間(第1〜第10区間)により分類される。   Here, the "state check" is a process of confirming the storage state of the non-volatile memory 24, and specifically means to confirm whether the number of rewrites Nr1 and the number of rewrites Nr2 match. . The processing phases are classified into ten sections (first to tenth sections) shown in FIG.

なお、記憶制御部28は、この状態チェック処理を不定期に実行してもよいし、定期的に実行してもよい。不定期の例として、[1]不揮発性メモリ24の読み出し要求時、[2]イグニッションスイッチ20のオン動作の直後、或いは[3]図2に示す一連の動作の終了時点から所定時間が経過したとき、が挙げられる。   The storage control unit 28 may periodically or periodically execute the state check process. As an irregular example, [1] when reading out the nonvolatile memory 24, [2] immediately after the on operation of the ignition switch 20, or [3] a predetermined time has elapsed from the end of the series of operations shown in FIG. When is mentioned.

第1〜第3区間では、書換回数Nr1、Nr2は、互いに等しい(Nr1=Nr2=5)。この場合、記憶制御部28は、車両情報Iv1、Iv2がいずれも最新であると判断し、不揮発性メモリ24に対して特別な処理を行わない。つまり、不揮発性メモリ24は、5回目の車両情報Iv1、Iv2を記憶した状態(データ同期が保たれた状態)を維持する。   In the first to third sections, the number of rewrites Nr1 and Nr2 are equal to one another (Nr1 = Nr2 = 5). In this case, the storage control unit 28 determines that both of the vehicle information Iv1 and Iv2 are latest, and does not perform special processing on the non-volatile memory 24. That is, the non-volatile memory 24 maintains the state (the state where data synchronization is maintained) in which the fifth vehicle information Iv1 and Iv2 are stored.

第4、第5区間では、第1回数格納領域30nに格納された書換回数Nr1が不使用値(つまり、Nr1=0)であって、第2回数格納領域32nに格納された書換回数Nr2が不使用値でない(Nr2=5)。この場合、記憶制御部28は、車両情報Iv2のみが最新であると判断する。   In the fourth and fifth sections, the number of rewrites Nr1 stored in the first number storage area 30n is an unused value (that is, Nr1 = 0), and the number of rewrites Nr2 stored in the second number storage area 32n is It is not an unused value (Nr2 = 5). In this case, the storage control unit 28 determines that only the vehicle information Iv2 is the latest.

つまり、書換回数Nr1が不使用値である一方の記憶領域(第1記憶領域30)が更新中である状態において、他方の記憶領域(第2記憶領域32)から書換回数Nr2及び車両情報Iv2を複製することで直近の記憶状態に戻すことができる。   That is, in a state where one storage area (first storage area 30) whose number of rewrites Nr1 is an unused value is being updated, the number of rewrites Nr2 and vehicle information Iv2 are updated from the other storage area (second storage area 32). It is possible to return to the latest memory state by duplicating.

この場合、記憶制御部28は、[1](Nr1←Nr2)第2回数格納領域32nの書換回数Nr2を複製して第1回数格納領域30nに書き込むと共に、[2](Iv1←Iv2)第2情報格納領域32vの車両情報Iv2を複製して第1情報格納領域30vに書き込む記憶制御を行う。その結果、不揮発性メモリ24は、5回目の車両情報Iv1、Iv2を記憶した状態(つまり、データ同期が保たれた状態)に戻る。   In this case, the storage control unit 28 duplicates the rewrite count Nr2 of the [1] (Nr1 1 Nr2) second count storage area 32n and writes it in the first count storage area 30n, as well as [2] (Iv1 I Iv2) The storage control is performed to copy the vehicle information Iv2 of the 2 information storage area 32v and write it in the first information storage area 30v. As a result, the non-volatile memory 24 returns to the state in which the fifth vehicle information Iv1 and Iv2 are stored (that is, the state in which data synchronization is maintained).

ここで、記憶制御部28は、車両情報Iv2を複製する記憶制御が完了するまでの間、この複製以外での第1記憶領域30及び第2記憶領域32への書き込みを行わない。記憶データの復旧中に複製以外の書き込みを禁止することで、記憶状態に関する異常の発生を防止することができる。   Here, the storage control unit 28 does not write in the first storage area 30 and the second storage area 32 other than this duplication until the storage control for copying the vehicle information Iv2 is completed. By prohibiting writing other than duplication during recovery of stored data, it is possible to prevent occurrence of an abnormality relating to the storage state.

第6、第7区間では、書換回数Nr1(=6)、Nr2(=5)はいずれも不使用値ではなく、かつ、Nr1>Nr2の大小関係を満たしている。この場合、記憶制御部28は、車両情報Iv1のみが最新であると判断する。   In the sixth and seventh sections, the number of rewrites Nr1 (= 6) and Nr2 (= 5) are not unused values, and satisfy the magnitude relationship of Nr1> Nr2. In this case, the storage control unit 28 determines that only the vehicle information Iv1 is the latest.

つまり、書換回数Nr1が大きい一方の記憶領域(第1記憶領域30)が更新後であり、かつ、他方の記憶領域(第2記憶領域32)が更新前である状態において、第1記憶領域30から車両情報Iv1を複製することで最新の記憶状態に移行することができる。   That is, in a state in which one storage area (first storage area 30) having a large number of rewrites Nr1 is updated and the other storage area (second storage area 32) is not updated, the first storage area 30 is It is possible to shift to the latest memory state by duplicating the vehicle information Iv1.

この場合、記憶制御部28は、[1](Nr2←Nr1)第1回数格納領域30nの書換回数Nr1を複製して第2回数格納領域32nに書き込むと共に、[2](Iv2←Iv1)第1情報格納領域30vの車両情報Iv1を複製して第2情報格納領域32vに書き込む記憶制御を行う。なお、書換回数Nr1の複製に代わって、カウント更新した書換回数Nr2を第2回数格納領域32nに書き込んでもよい。   In this case, the storage control unit 28 duplicates the rewrite count Nr1 of the [1] (Nr2 2 Nr1) first count storage area 30n and writes it in the second count storage area 32n, while the [2] (Iv2 I Iv1) first Storage control is performed to copy the vehicle information Iv1 of the first information storage area 30v and write it in the second information storage area 32v. Note that, instead of copying the number of times of rewriting Nr1, the number of times of rewriting Nr2 that has been updated may be written in the second number storing area 32n.

第4、第5区間の場合と同様に、記憶制御部28は、車両情報Iv1を複製する記憶制御が完了するまでの間、この複製以外での第1記憶領域30及び第2記憶領域32への書き込みを行わないようにする。その結果、不揮発性メモリ24は、6回目の車両情報Iv1、Iv2を記憶した状態(つまり、データ同期が保たれた状態)になる。   As in the case of the fourth and fifth sections, the storage control unit 28 sends the first storage area 30 and the second storage area 32 other than this copy until the storage control for copying the vehicle information Iv1 is completed. Do not write As a result, the non-volatile memory 24 is in a state of storing the sixth vehicle information Iv1 and Iv2 (that is, a state in which data synchronization is maintained).

第8、第9区間では、第1回数格納領域30nに格納された書換回数Nr1が不使用値ではなく(Nr1=6)、第2回数格納領域32nに格納された書換回数Nr2が不使用値(つまり、Nr2=0)である。この場合、記憶制御部28は、車両情報Iv1のみが最新であると判断する。   In the eighth and ninth sections, the number of rewrites Nr1 stored in the first count storage area 30n is not the unused value (Nr1 = 6), and the number of rewrites Nr2 stored in the second count storage area 32n is the unused value (That is, Nr2 = 0). In this case, the storage control unit 28 determines that only the vehicle information Iv1 is the latest.

つまり、書換回数Nr2が不使用値である一方の記憶領域(第2記憶領域32)が更新中である状態において、他方の記憶領域(第1記憶領域30)から書換回数Nr1及び車両情報Iv1を複製することで最新の記憶状態に移行することができる。   That is, in a state where one storage area (second storage area 32) in which the number of rewrites Nr2 is an unused value is being updated, the number of rewrites Nr1 and vehicle information Iv1 from the other storage area (first storage area 30) By copying, it is possible to shift to the latest memory state.

この場合、記憶制御部28は、[1](Nr2←Nr1)第1回数格納領域30nの書換回数Nr1を複製して第2回数格納領域32nに書き込むと共に、[2](Iv2←Iv1)第1情報格納領域30vの車両情報Iv1を複製して第2情報格納領域32vに書き込む記憶制御を行う。   In this case, the storage control unit 28 duplicates the rewrite count Nr1 of the [1] (Nr2 2 Nr1) first count storage area 30n and writes it in the second count storage area 32n, while the [2] (Iv2 I Iv1) first Storage control is performed to copy the vehicle information Iv1 of the first information storage area 30v and write it in the second information storage area 32v.

第6、第7区間の場合と同様に、記憶制御部28は、車両情報Iv1を複製する記憶制御が完了するまでの間、この複製以外での第1記憶領域30及び第2記憶領域32への書き込みを行わないようにする。その結果、不揮発性メモリ24は、6回目の車両情報Iv1、Iv2を記憶した状態(つまり、データ同期が保たれた状態)になる。   As in the case of the sixth and seventh sections, the storage control unit 28 sends the first storage area 30 and the second storage area 32 other than this copy until the storage control for copying the vehicle information Iv1 is completed. Do not write As a result, the non-volatile memory 24 is in a state of storing the sixth vehicle information Iv1 and Iv2 (that is, a state in which data synchronization is maintained).

第10区間では、書換回数Nr1、Nr2は、互いに等しい(Nr1=Nr2=6)。この場合、記憶制御部28は、車両情報Iv1、Iv2がいずれも最新であると判断し、不揮発性メモリ24に対して特別な処理を行わない。つまり、不揮発性メモリ24は、6回目の車両情報Iv1、Iv2を記憶した状態(データ同期が保たれた状態)を維持する。   In the tenth section, the number of rewrites Nr1 and Nr2 are equal to one another (Nr1 = Nr2 = 6). In this case, the storage control unit 28 determines that both of the vehicle information Iv1 and Iv2 are latest, and does not perform special processing on the non-volatile memory 24. That is, the non-volatile memory 24 maintains the state in which the sixth vehicle information Iv1 and Iv2 are stored (the state in which data synchronization is maintained).

[エンジンECU12(車両情報記憶装置)による効果]
以上のように、エンジンECU12は、車両に搭載され、かつ、車両の状態を示す車両情報Iv1、Iv2を記憶し、[1]第1記憶領域30及び第2記憶領域32を有する不揮発性メモリ24と、[2]車両情報Iv1、Iv2の書換回数Nr1、Nr2を少なくとも記憶する揮発性メモリ26と、[3]不揮発性メモリ24及び揮発性メモリ26に対する記憶制御を行う記憶制御部28と、を備え、[4]第1記憶領域30は、車両情報Iv1が格納される第1情報格納領域30vと、書換回数Nr1が格納される第1回数格納領域30nと、を含み、[5]第2記憶領域32は、車両情報Iv2が格納される第2情報格納領域32vと、書換回数Nr2が格納される第2回数格納領域32nと、を含む。
[Effect by engine ECU 12 (vehicle information storage device)]
As described above, the engine ECU 12 is mounted on a vehicle and stores vehicle information Iv1 and Iv2 indicating the state of the vehicle, and [1] a non-volatile memory 24 having a first storage area 30 and a second storage area 32. And [2] volatile memory 26 which stores at least the number of times of rewriting Nr1 and Nr2 of vehicle information Iv1 and Iv2, and [3] storage control unit 28 which performs storage control for nonvolatile memory 24 and volatile memory 26. The first storage area 30 includes a first information storage area 30v for storing vehicle information Iv1 and a first number storage area 30n for storing the number of times of rewriting Nr1. Storage area 32 includes a second information storage area 32v in which vehicle information Iv2 is stored, and a second count storage area 32n in which the number of times of rewrite Nr2 is stored.

そして、[6]記憶制御部28は、第1情報格納領域30vの更新を開始する前に、(6a)第1回数格納領域30nから読み出した書換回数Nr1を揮発性メモリ26に書き込み、(6b)書換回数Nr1のカウントに使用しない不使用値(=0)を第1回数格納領域30nに書き込む。[7]記憶制御部28は、第1情報格納領域30vの更新が終了した後に、(7a)揮発性メモリ26から読み出した書換回数Nr1をカウント更新し、(7b)第1回数格納領域30nに書き込む記憶制御を行う。   [6] Then, the storage control unit 28 writes the number of rewrites Nr1 read from the first number storage area 30n to the volatile memory 26 (6a) before starting the update of the first information storage area 30v (6b) ) Write an unused value (= 0) not used for counting the number of rewrites Nr1 in the first number storage area 30n. [7] The storage control unit 28 counts and updates the number of rewrites Nr1 read from the volatile memory 26 after the update of the first information storage area 30v is completed, and (7b) the first number storage area 30n. Perform storage control to write.

そして、[8]記憶制御部28は、第2情報格納領域32vの更新を開始する前に、(8a)第2回数格納領域32nから読み出した書換回数Nr2を揮発性メモリ26に書き込み、(8b)書換回数Nr2のカウントに使用しない不使用値(=0)を第2回数格納領域32nに書き込む。[9]記憶制御部28は、第2情報格納領域32vの更新が終了した後に、(9a)揮発性メモリ26から読み出した書換回数Nr2をカウント更新し、(9b)第2回数格納領域32nに書き込む記憶制御を行う。   [8] The storage control unit 28 writes the number Nr2 of rewrites read from the second number storage area 32n to the volatile memory 26 (8a) before starting updating the second information storage area 32v (8b) 2.) Write an unused value (= 0) not used for counting the number of rewrites Nr2 in the second number storage area 32n. [9] The storage control unit 28 counts and updates the number of rewrites Nr2 read from the volatile memory 26 after the update of the second information storage area 32v is completed, and (9b) the second number storage area 32n. Perform storage control to write.

このように構成することで、例えば、電力の瞬断によって揮発性メモリ26に一時的に記憶された情報が消失した場合であっても、現在格納されている2つの書換回数Nr1、Nr2の数値関係(単独値又は相対値)に基づいて第1記憶領域30及び第2記憶領域32の更新状況を判別可能となり、その後に必要な対処を施すことで記憶データを適切に復旧することができる。これにより、不揮発性メモリ24の使用容量を減らしつつ、記憶データの信頼性を確保することができる。   By configuring in this way, for example, even when the information temporarily stored in the volatile memory 26 is lost due to a momentary power loss, the numerical values of the two rewrite times Nr1 and Nr2 currently stored. The update status of the first storage area 30 and the second storage area 32 can be determined based on the relationship (single value or relative value), and the storage data can be properly recovered by performing the necessary measures thereafter. Thereby, the reliability of stored data can be ensured while reducing the used capacity of the non-volatile memory 24.

また、車両のイグニッションスイッチ20のオフ動作に応じて、電力の供給が停止されるエンジンECU12に適用することがより好ましい。エンジン16を切った後のセルフシャットダウン機能を備えていない車両では、揮発性メモリ26のデータバックアップを取得できないので特に効果的である。   Further, it is more preferable to apply to the engine ECU 12 in which the supply of power is stopped in response to the off operation of the ignition switch 20 of the vehicle. A vehicle that does not have a self-shutdown function after the engine 16 is turned off is particularly effective because data backup of the volatile memory 26 can not be obtained.

[補足]
なお、この発明は、上述した実施形態に限定されるものではなく、この発明の主旨を逸脱しない範囲で自由に変更できることは勿論である。或いは、技術的に矛盾が生じない範囲で各々の構成を任意に組み合わせてもよい。
[Supplement]
In addition, this invention is not limited to embodiment mentioned above, Of course, it can change freely in the range which does not deviate from the main point of this invention. Or you may combine each structure arbitrarily in the range which a technical contradiction does not arise.

例えば、この実施形態では、第1記憶領域30→第2記憶領域32の更新順に従って更新を行っているが、逆の更新順(つまり、第2記憶領域32→第1記憶領域30)であってもよい。また、データ同期が保たれるのであれば、更新順は固定されていなくてもよい。   For example, in this embodiment, the update is performed according to the update order of the first storage area 30 → the second storage area 32, but in the reverse update order (that is, the second storage area 32 → the first storage area 30) May be Also, the update order may not be fixed as long as data synchronization is maintained.

また、この実施形態では、第1回数格納領域30nには1個の書換回数Nr1が格納されているが、同一の値を2個以上格納可能な領域を設け、いわゆるデータの多重化を図ってもよい。具体的には、すべての値が一致する場合に正常値として判定したり、多数決により格納値を決定したりすることで、データ同期処理の信頼性がさらに向上する。また、第2回数格納領域32n(書換回数Nr2)に関しても同様である。   Moreover, in this embodiment, although the number of times of rewriting Nr1 is stored in the first number of times storage area 30n, an area capable of storing two or more identical values is provided to achieve so-called data multiplexing. It is also good. Specifically, the reliability of the data synchronization process is further improved by determining as a normal value when all the values match or by determining the stored value by majority. The same applies to the second number storage area 32n (number of rewrites Nr2).

10…車両故障診断システム 12…エンジンECU(車両情報記憶装置)
14…センサ群 16…エンジン
18…電源 20…イグニッションスイッチ
22…演算処理装置 24…不揮発性メモリ
26…揮発性メモリ 28…記憶制御部
30…第1記憶領域 30n…第1回数格納領域
30v…第1情報格納領域 32…第2記憶領域
32n…第2回数格納領域 32v…第2情報格納領域
34…記憶領域 Iv1、Iv2…車両情報
Nr1、Nr2…書換回数
10: Vehicle failure diagnosis system 12: Engine ECU (vehicle information storage device)
14 sensor group 16 engine 18 power supply 20 ignition switch 22 arithmetic processing unit 24 non-volatile memory 26 volatile memory 28 storage control unit 30 first storage area 30 n first number storage area 30 v first 1 information storage area 32: second storage area 32n: second number storage area 32v: second information storage area 34: storage area Iv1, Iv2: vehicle information Nr1, Nr2: number of times of rewriting

Claims (5)

車両に搭載され、かつ、前記車両の状態を示す車両情報を記憶する車両情報記憶装置であって、
第1記憶領域及び第2記憶領域を有する不揮発性メモリと、
前記車両情報の書換回数を少なくとも記憶する揮発性メモリと、
前記不揮発性メモリ及び前記揮発性メモリに対する記憶制御を行う記憶制御部と、
を備え、
前記第1記憶領域は、前記車両情報が格納される第1情報格納領域と、前記書換回数が格納される第1回数格納領域と、を含み、
前記第2記憶領域は、前記車両情報が格納される第2情報格納領域と、前記書換回数が格納される第2回数格納領域と、を含み、
前記記憶制御部は、
前記第1情報格納領域の更新を開始する前に、前記第1回数格納領域から読み出した前記書換回数を前記揮発性メモリに書き込み、かつ、前記書換回数のカウントに使用しない不使用値を前記第1回数格納領域に書き込み、
前記第1情報格納領域の更新が終了した後に、前記揮発性メモリから読み出した前記書換回数をカウント更新し、かつ、前記第1回数格納領域に書き込む記憶制御を行い、
前記第2情報格納領域の更新を開始する前に、前記第2回数格納領域から読み出した前記書換回数を前記揮発性メモリに書き込み、かつ、前記書換回数のカウントに使用しない不使用値を前記第2回数格納領域に書き込み、
前記第2情報格納領域の更新が終了した後に、前記揮発性メモリから読み出した前記書換回数をカウント更新し、かつ、前記第2回数格納領域に書き込む記憶制御を行う
ことを特徴とする車両情報記憶装置。
A vehicle information storage device mounted on a vehicle and storing vehicle information indicating a state of the vehicle,
A non-volatile memory having a first storage area and a second storage area;
A volatile memory that stores at least the number of times of rewriting of the vehicle information;
A storage control unit that performs storage control on the nonvolatile memory and the volatile memory;
Equipped with
The first storage area includes a first information storage area in which the vehicle information is stored, and a first number storage area in which the number of rewrites is stored.
The second storage area includes a second information storage area in which the vehicle information is stored, and a second number storage area in which the number of rewrites is stored.
The storage control unit
Before starting the update of the first information storage area, the number of rewrites read from the first number storage area is written to the volatile memory, and an unused value not used for counting the number of rewrites is selected. Write to storage area one time,
After the update of the first information storage area is completed, the number of rewrites read out from the volatile memory is counted and updated, and storage control to write in the first number storage area is performed.
Before starting the update of the second information storage area, the number of rewrites read from the second number storage area is written to the volatile memory, and an unused value not used for counting the number of rewrites is selected. Write to storage area 2 times,
After updating of the second information storage area is completed, the number of rewrites read from the volatile memory is counted and updated, and storage control to write in the second number storage area is performed. apparatus.
請求項1に記載の車両情報記憶装置において、
前記記憶制御部は、
前記第1回数格納領域に格納された前記書換回数が前記不使用値であって、かつ、前記第2回数格納領域に格納された前記書換回数が前記不使用値でない場合、
前記第2回数格納領域の前記書換回数を複製して前記第1回数格納領域に書き込むと共に、前記第2情報格納領域の前記車両情報を複製して前記第1情報格納領域に書き込む記憶制御を行い、
前記第1回数格納領域に格納された前記書換回数が前記不使用値でなく、かつ、前記第2回数格納領域に格納された前記書換回数が前記不使用値である場合、
前記第1回数格納領域の前記書換回数を複製して前記第2回数格納領域に書き込むと共に、前記第1情報格納領域の前記車両情報を複製して前記第2情報格納領域に書き込む記憶制御を行う
ことを特徴とする車両情報記憶装置。
In the vehicle information storage device according to claim 1,
The storage control unit
When the number of rewrites stored in the first number storage area is the non-use value, and the number of rewrites stored in the second number storage area is not the non-use value
Storage control is performed to copy the number of rewrites in the second number storage area and write it in the first number storage area, and copy the vehicle information in the second information storage area and write it in the first information storage area ,
When the number of rewrites stored in the first number storage area is not the nonuse value, and the number of rewrites stored in the second number storage area is the nonuse value
The duplication control of the first number storage area is copied and written in the second number storage area, and the vehicle information of the first information storage area is copied and written in the second information storage area. Vehicle information storage device characterized in that.
請求項1に記載の車両情報記憶装置において、
前記記憶制御部は、
前記第1回数格納領域に格納された前記書換回数が、前記第2回数格納領域に格納された前記書換回数よりも大きい場合、前記第1情報格納領域の前記車両情報を複製し、前記第2情報格納領域に書き込む記憶制御を行い、
前記第1回数格納領域に格納された前記書換回数が、前記第2回数格納領域に格納された前記書換回数よりも小さい場合、前記第2情報格納領域の前記車両情報を複製し、前記第1情報格納領域に書き込む記憶制御を行う
ことを特徴とする車両情報記憶装置。
In the vehicle information storage device according to claim 1,
The storage control unit
When the number of rewrites stored in the first number storage area is larger than the number of rewrites stored in the second number storage area, the vehicle information in the first information storage area is copied, and the second number is stored. Perform storage control to write to the information storage area,
When the number of rewrites stored in the first number storage area is smaller than the number of rewrites stored in the second number storage area, the vehicle information in the second information storage area is copied, and the first number is stored. A vehicle information storage device characterized by performing storage control to write in an information storage area.
請求項2又は3に記載の車両情報記憶装置において、
前記記憶制御部は、前記車両情報を複製する記憶制御が完了するまでの間、前記複製以外での前記第1記憶領域及び前記第2記憶領域への書き込みを行わないことを特徴とする車両情報記憶装置。
In the vehicle information storage device according to claim 2 or 3,
The storage control unit does not write to the first storage area and the second storage area other than the copy until the storage control for copying the vehicle information is completed. Storage device.
請求項1〜4のいずれか1項に記載の車両情報記憶装置において、
前記車両のイグニッションスイッチのオフ動作に応じて電力の供給が停止されることを特徴とする車両情報記憶装置。
In the vehicle information storage device according to any one of claims 1 to 4,
A vehicle information storage device characterized in that the supply of electric power is stopped in response to the turning-off operation of an ignition switch of the vehicle.
JP2017165456A 2017-08-30 2017-08-30 Vehicle information storage device Active JP6975581B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017165456A JP6975581B2 (en) 2017-08-30 2017-08-30 Vehicle information storage device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017165456A JP6975581B2 (en) 2017-08-30 2017-08-30 Vehicle information storage device

Publications (2)

Publication Number Publication Date
JP2019045951A true JP2019045951A (en) 2019-03-22
JP6975581B2 JP6975581B2 (en) 2021-12-01

Family

ID=65814318

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017165456A Active JP6975581B2 (en) 2017-08-30 2017-08-30 Vehicle information storage device

Country Status (1)

Country Link
JP (1) JP6975581B2 (en)

Also Published As

Publication number Publication date
JP6975581B2 (en) 2021-12-01

Similar Documents

Publication Publication Date Title
JP4803168B2 (en) Vehicle information storage device
JP3726663B2 (en) Electronic control device control data storage device
JP4345860B2 (en) Vehicle memory management device
JP4636118B2 (en) Electronic device and program
JP2009120054A (en) Vehicular memory management device
JP2020027634A5 (en)
JP2012137803A (en) Vehicle data storage device, controller and vehicle data record system
JP6975581B2 (en) Vehicle information storage device
JP6956566B2 (en) Vehicle information storage device
US11314634B2 (en) Electronic control unit and data protection method therefor
JP2009116521A (en) Data rewriting method for memory
JP6663371B2 (en) Electronic control unit
JP7029366B2 (en) Electronic control device for automobiles
JP2004151944A (en) Method for writing data in non-volatile storage device, its program and device, and onboard electronic controller
JP2006293650A (en) Backup device for vehicle information
JP3644058B2 (en) Electronic control device for vehicle engine and data rewrite control device for EEPROM
JP6159668B2 (en) Vehicle control device
JP4479775B2 (en) Vehicle control apparatus and program
JP6381490B2 (en) In-vehicle electronic control unit
JP7007223B2 (en) Control device and abnormality detection method
JP2006291829A (en) Vehicle state determination device
JP3551855B2 (en) Vehicle control device
JP2002334023A (en) Electronic controller
JP3444295B2 (en) Electronic control unit for vehicle engine
JP5643708B2 (en) Electronic control unit

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200702

A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20210226

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20210408

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210614

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210706

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210902

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: 20211102

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20211108

R150 Certificate of patent or registration of utility model

Ref document number: 6975581

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150