JP2023158751A - Firmware update method and firmware update system - Google Patents

Firmware update method and firmware update system Download PDF

Info

Publication number
JP2023158751A
JP2023158751A JP2022068716A JP2022068716A JP2023158751A JP 2023158751 A JP2023158751 A JP 2023158751A JP 2022068716 A JP2022068716 A JP 2022068716A JP 2022068716 A JP2022068716 A JP 2022068716A JP 2023158751 A JP2023158751 A JP 2023158751A
Authority
JP
Japan
Prior art keywords
firmware
update
writing
program
crc value
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.)
Pending
Application number
JP2022068716A
Other languages
Japanese (ja)
Inventor
祥惠 田中
Sachie Tanaka
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2022068716A priority Critical patent/JP2023158751A/en
Publication of JP2023158751A publication Critical patent/JP2023158751A/en
Pending legal-status Critical Current

Links

Abstract

To provide a firmware update method and a firmware update system which can reduce the firmware update time.SOLUTION: Before updating firmware, a module for update is divided into a plurality of programs after conversion to binary data and CRC values corresponding to the respective programs are calculated by a FW writing device 1. An FW update object device 2 returns CRC values of individual areas which are stored in a memory for FW 212 at a current time, in response to a write instruction from the FW writing device 1 to the FW update object device 2, and the FW writing device 1 compares these CRC values with the preliminarily calculated CRC values to specify program areas to be updated in the memory for FW 212, and the FW update object device 2 writes the program for update into the memory for FW 212 only with respect to the specified program areas.SELECTED DRAWING: Figure 1

Description

本願は、ファームウェアアップデート方法、およびファームウェアアップデートシステムに関するものである。 The present application relates to a firmware update method and a firmware update system.

従来のプラント監視制御システムにおいて、プロセス入出力装置に組み込まれたファームウェアをアップデートする際には、更新対象となるプロセス入出力装置に対して1つの書き込みモジュールを準備し、全プログラム領域の全てに渡って書き換えを行っている。 In conventional plant monitoring and control systems, when updating the firmware built into a process input/output device, one writing module is prepared for the process input/output device to be updated, and it is written across all program areas. is being rewritten.

すなわち、まず、専用の書き込みツールにファームウェアをダウンロードし、これをバイナリデータに変換した後に更新対象となるプロセス入出力装置に対して書き込み指示を行い、ファームウェアの書き換えを実行する(例えば、下記の特許文献1参照)。 That is, first, the firmware is downloaded to a dedicated writing tool, and after converting this into binary data, a writing instruction is given to the process input/output device to be updated, and the firmware is rewritten (for example, the following patent (See Reference 1).

特開2012-216010号公報Japanese Patent Application Publication No. 2012-216010

従来のファームウェアアップデート方法は、専用の書き込みツールからの書き込み指示を受信した更新対象となるプロセス入出力装置は、ブートプログラムを起動させて、一度FW用メモリ内の全プログラムの記憶領域を全消去した後、更新するファームウェアをプログラム領域に新たに書き込むようにしている。このため、書き込みに時間がかかり、ファームウェアの更新を効率良く行えないという課題がある。 In the conventional firmware update method, the process input/output device to be updated receives a write instruction from a dedicated writing tool, starts the boot program, and once erases all program storage areas in the FW memory. After that, the firmware to be updated is newly written to the program area. Therefore, there is a problem that writing takes time and firmware cannot be updated efficiently.

本願は、上記のような課題を解決するための技術を開示するものであり、ファームウェアの書き換えに要する時間を大幅に短縮できるようにしたファームウェアアップデート方法、およびファームウェアアップデートシステムを提供することを目的とする。 This application discloses a technology to solve the above-mentioned problems, and aims to provide a firmware update method and firmware update system that can significantly reduce the time required to rewrite firmware. do.

本願に開示されるファームウェアアップデート方法は、更新用のファームウェアを書き込むためのFW書込装置から、前記ファームウェアの更新対象となるFW更新対象装置に対して前記ファームウェアを書き込む場合に、前記ファームウェアの更新に先立ち、前記FW書込装置で前記ファームウェアをバイナリデータに変換した後に複数のプログラムに分割して各プログラムに対応するCRC値を個別に算出しておき、前記FW書込装置による前記FW更新対象装置に対する書き込み指示に応じて、前記FW更新対象装置は、このFW更新対象装置が備えるFW用メモリに現時点で格納されている各領域のCRC値を返答し、前記FW書込装置がこのCRC値と予め算出したCRC値とを比較することで前記FW用メモリにおける更新すべきプログラムの記憶領域を特定し、その特定したプログラムの記憶領域に関してのみ前記FW更新対象装置が更新用のプログラムを前記FW用メモリに書き込む。 The firmware update method disclosed in the present application is provided for updating the firmware when writing the firmware from a FW writing device for writing update firmware to a FW update target device to which the firmware is updated. First, the firmware is converted into binary data by the FW writing device, and then divided into a plurality of programs, and a CRC value corresponding to each program is calculated individually, and the FW writing device converts the firmware into binary data. In response to the write instruction, the FW update target device replies with the CRC value of each area currently stored in the FW memory provided in the FW update target device, and the FW writing device writes this CRC value and By comparing the CRC value with a pre-calculated CRC value, the storage area of the program to be updated in the FW memory is specified, and the FW update target device updates the update program only with respect to the specified storage area of the program. write to memory.

また、本願に開示されるファームウェアアップデートシステムは、更新用のファームウェアを書き込むためのFW書込装置と、前記ファームウェアの更新対象となるFW更新対象装置とからなり、
前記FW書込装置は、前記ファームウェアを記憶するとともに、前記ファームウェアを前記FW更新対象装置に書き込むFW書込ツールを搭載しており、
前記FW書込ツールは、前記FW更新対象装置に対して前記ファームウェアを書き込む場合に、前記ファームウェアをバイナリデータに変換した後に複数のプログラムに分割し、各々の前記プログラムに対してそれぞれCRC値を個別に算出するとともに、この算出されたCRC値と前記FW更新対象装置から返答される現時点のCRC値とを比較し、両CRC値が不一致の場合にのみ、その不一致のCRC値を有するプログラムを前記FW更新対象装置に送信するものであり、
前記FW更新対象装置は、前記ファームウェアを構成する各プログラムならびに各プログラムに個別に対応して設定されたCRC値を記憶するFW用メモリと、前記FW書込装置から送信される更新用のプログラムを算出されたCRC値と共に前記FW用メモリに書き込むFW書込処理部とを有し、
前記FW書込処理部は、前記FW書込装置の前記FW書込ツールによる前記ファームウェアの書き込み指示に応答して、前記FW用メモリに記憶されている現時点のCRC値を読み出して前記FW書込ツールに送信するとともに、前記FW書込ツールにより送信されてくるCRC値を有するプログラムを前記FW用メモリのCRC値が不一致となった領域に書き込むものである。
Further, the firmware update system disclosed in the present application includes an FW writing device for writing firmware for update, and a FW update target device to which the firmware is updated,
The FW writing device stores the firmware and is equipped with a FW writing tool that writes the firmware to the FW update target device,
When writing the firmware to the FW update target device, the FW writing tool converts the firmware into binary data, divides it into a plurality of programs, and individually assigns a CRC value to each of the programs. At the same time, this calculated CRC value is compared with the current CRC value returned from the FW update target device, and only when the two CRC values do not match, the program having the mismatched CRC value is It is sent to the device subject to FW update,
The FW update target device has an FW memory that stores each program constituting the firmware and a CRC value set individually corresponding to each program, and an update program sent from the FW writing device. an FW write processing unit that writes the calculated CRC value to the FW memory,
The FW write processing unit reads the current CRC value stored in the FW memory and writes the FW in response to an instruction to write the firmware by the FW write tool of the FW write device. A program having a CRC value sent to the tool and also sent by the FW writing tool is written into the area of the FW memory where the CRC value does not match.

本願に開示されるファームウェアアップデート方法、およびファームウェアアップデートシステムによれば、ファームウェアをアップデートする際に、プログラムを書き込むために要する更新時間を大幅に短縮することができる。 According to the firmware update method and firmware update system disclosed in the present application, it is possible to significantly reduce the update time required to write a program when updating firmware.

この実施の形態1によるファームウェアアップデートシステムの概略構成を示すブロック図である。1 is a block diagram showing a schematic configuration of a firmware update system according to the first embodiment; FIG. この実施の形態1によるファームウェアアップデート方法の処理の概要、特にFW書込装置の側の処理内容を示すフロー図である。FIG. 2 is a flowchart showing an overview of the processing of the firmware update method according to the first embodiment, particularly the processing content on the FW writing device side. この実施の形態1によるファームウェアアップデート方法の処理の概要、特にFW更新対象装置の側の処理内容を示すフロー図である。FIG. 2 is a flow diagram showing an overview of the processing of the firmware update method according to the first embodiment, particularly the processing content on the side of the FW update target device. 図2で示したステップS1における処理の詳細を示すフロー図である。FIG. 3 is a flow diagram showing details of processing in step S1 shown in FIG. 2. FIG. 図2で示したステップS3における処理の詳細を示すフロー図である。FIG. 3 is a flow diagram showing details of processing in step S3 shown in FIG. 2. FIG. 図3で示したステップS9~S12における処理の詳細を示すフロー図である。4 is a flow diagram showing details of the processing in steps S9 to S12 shown in FIG. 3. FIG.

実施の形態1.
図1は、この実施の形態1によるファームウェアアップデートシステムの概略構成を示すブロック図である。なお、本願において「ファームウェア」を「FW」と略している場合がある。
Embodiment 1.
FIG. 1 is a block diagram showing a schematic configuration of a firmware update system according to the first embodiment. Note that in this application, "firmware" may be abbreviated as "FW".

この実施の形態1によるファームウェアアップデートシステムは、更新用のファームウェアを書き込むFW書込装置1と、このファームウェアの更新対象となるFW更新対象装置2とで構成される。 The firmware update system according to the first embodiment includes an FW writing device 1 that writes firmware for updating, and a FW update target device 2 that is the target of updating the firmware.

ここに、具体例として、ファームウェアアップデートシステムをプラント監視制御システムに適用した場合、上記のFW更新対象装置2は、各種のプラント検出器で検出されたプラント機器の状態に応じてプラント機器に対して制御信号を発信してプロセス制御を行うプロセス制御装置がこれに該当する。しかし、本願は、このようなプロセス制御装置に限定されるものではない。 Here, as a specific example, when the firmware update system is applied to a plant monitoring and control system, the above-mentioned FW update target device 2 updates the plant equipment according to the status of the plant equipment detected by various plant detectors. This corresponds to a process control device that performs process control by transmitting control signals. However, the present application is not limited to such process control devices.

FW書込装置1は、更新用のファームウェア112を記憶するとともに、このファームウェア112の特定の領域のプログラムをFW更新対象装置2に書き込むためのFW書込ツール11を搭載している。そして、このFW書込ツール11には、更新するファームウェア112をFW更新対象装置2に書き込むための準備を行うFW書込準備処理部111が設けられている。 The FW writing device 1 stores update firmware 112 and is equipped with an FW writing tool 11 for writing a program in a specific area of the firmware 112 to the FW update target device 2. The FW writing tool 11 is provided with an FW writing preparation processing unit 111 that prepares for writing the firmware 112 to be updated into the FW update target device 2.

一方、FW更新対象装置2は、ファームウェアを構成する各プログラムならびに各プログラムの記憶領域ごとに対応して設定されたCRC値を記憶するFW用メモリ(例えば、フラッシュメモリ)212と、前記FW書込装置1から送信される更新用のプログラムを前記FW用メモリ212に書き込むためのFW書込処理部211とを有する。また、FW更新対象装置2には、ファームウェアの誤更新を防ぐために、手動でファームウェアの更新起動を許可するためのスイッチ22が設けられている。 On the other hand, the FW update target device 2 includes an FW memory (for example, a flash memory) 212 that stores each program constituting the firmware and a CRC value set corresponding to each storage area of each program, and It has an FW write processing unit 211 for writing an update program transmitted from the device 1 into the FW memory 212. Further, the FW update target device 2 is provided with a switch 22 for manually permitting firmware update activation in order to prevent erroneous firmware updates.

なお、上記のFW書込装置1におけるFW書込準備処理部111、およびFW更新対象装置2におけるFW書込処理部211の構成、ならびにその処理動作については、後述のフロー図により一層明確にされる。 The configurations and processing operations of the FW write preparation processing unit 111 in the FW writing device 1 and the FW write processing unit 211 in the FW update target device 2 described above will be further clarified in the flowchart described below. Ru.

この実施の形態1におけるファームウェアアップデートシステムによるファームウェア更新の概要は、図1に示すように、FW書込装置1に搭載されているFW書込ツール11が備えるFW書込準備処理部111により、予めファイル等に記憶されている更新用ファームウェア112を読み出す一方、ファームウェア112の更新対象となるFW更新対象装置2と通信してファームウェア112の書き込み指示を出す。 The outline of the firmware update by the firmware update system in the first embodiment is as shown in FIG. 1, as shown in FIG. While reading the update firmware 112 stored in a file or the like, it communicates with the FW update target device 2 to which the firmware 112 is to be updated and issues a write instruction for the firmware 112.

FW書込装置1から書き込み指示を受信したFW更新対象装置2は、内部に搭載しているブートプログラム21を起動させ、FW書込処理部211において、FW書込装置1から送信されてくるファームウェア112の内の特定のプログラムを、FW用メモリ212内の特定の領域に記憶されている既存のプログラムと書き換える。 The FW update target device 2 that has received the write instruction from the FW writing device 1 starts the internally installed boot program 21, and the FW writing processing unit 211 updates the firmware sent from the FW writing device 1. 112 is rewritten with an existing program stored in a specific area within the FW memory 212.

図2はファームウェアアップデート方法の処理の概要、特にFW書込装置1における処理内容を示すフロー図である。また、図3はファームウェアアップデート方法の処理の概要、特にFW更新対象装置2における処理内容を示すフロー図である。なお、以下のフロー図において、符合Sは各処理ステップを意味する。 FIG. 2 is a flowchart showing an overview of the processing of the firmware update method, particularly the processing content in the FW writing device 1. Further, FIG. 3 is a flowchart showing an overview of the processing of the firmware update method, particularly the processing content in the FW update target device 2. Note that in the flowcharts below, the symbol S means each processing step.

FW書込装置1のFW書込ツール11でファームウェアの書き込みを開始すると、FW書込準備処理部111は、更新用のファームウェア112をダウンロードし、バイナリ変換(BIN化)を行う。 When the FW writing tool 11 of the FW writing device 1 starts writing firmware, the FW writing preparation processing unit 111 downloads the update firmware 112 and performs binary conversion (BIN conversion).

次に、FW書込準備処理部111は、バイナリ変換された更新用のファームウェア112を構成するプログラムを複数の領域に分割し、分割した各領域のプログラム、ならびに全領域のプログラムに対してCRC(Cyclic Redundancy Check)演算を行い、CRC値を付加する(ステップS1)。 Next, the FW write preparation processing unit 111 divides the program constituting the binary-converted update firmware 112 into a plurality of areas, and performs a CRC ( Cyclic Redundancy Check) calculation is performed and a CRC value is added (step S1).

これにより、分割された各プログラム113、これに対応するCRC値114、およびデータ構造を特定する情報としての固定ベクタ115が準備されることになる。こうして、準備が完了したなら、FW書込準備処理部111は、FW更新対象装置2に対してファームウェアの更新指示を送信する(ステップS2)。 As a result, each divided program 113, a corresponding CRC value 114, and a fixed vector 115 as information specifying the data structure are prepared. When the preparation is completed in this way, the FW write preparation processing unit 111 transmits a firmware update instruction to the FW update target device 2 (step S2).

FW更新対象装置2は、書き込み指示の誤受信を防ぐために、スイッチ22が操作された場合に、ブートプログラム21を起動する。そして、ブートプログラム21が起動された状態で、FW書込ツール11からの更新指示を受信した場合(ステップS7)、FW書込処理部211は、FW更新対象装置2内のFW用メモリ212に記憶されている各プログラムの記憶領域ごとに対応して設定された現時点のCRC値を読み出し、これをFW書込装置1のFW書込ツール11に送信する(ステップS8)。 The FW update target device 2 starts the boot program 21 when the switch 22 is operated in order to prevent erroneous reception of a write instruction. When the boot program 21 is activated and receives an update instruction from the FW writing tool 11 (step S7), the FW writing processing unit 211 writes the FW to the FW memory 212 in the FW update target device 2. The current CRC value set corresponding to each storage area of each stored program is read and sent to the FW writing tool 11 of the FW writing device 1 (step S8).

FW更新対象装置2からのCRC値を受信したFW書込ツール11は、FW書込準備処理部111において、受信した現時点のCRC値とFW書込ツール11側で演算して得られたCRC値とを比較する。このとき、CRC値が一致しない場合、その領域のプログラムは更新対象となるものであるから、現時点のCRC値が一致しないプログラム領域を特定し、FW更新対象装置2に対する更新すべきプログラム領域を決定する(ステップS3)。 The FW writing tool 11 that has received the CRC value from the FW update target device 2 uses the FW writing preparation processing unit 111 to calculate the CRC value obtained by calculating the received current CRC value and the FW writing tool 11 side. Compare with. At this time, if the CRC values do not match, the program in that area is to be updated, so identify the program area where the current CRC value does not match, and determine the program area to be updated for the FW update target device 2. (Step S3).

そして、更新するプログラム113、FW書込装置1で算出されたCRC値114、および固定ベクタ115をFW更新対象装置2へ送信する(ステップS4)。この時のCRC値は、更新対象となるプログラム領域に対応した算出後のCRC値、および全プログラム領域に対するCRC値である。 Then, the program 113 to be updated, the CRC value 114 calculated by the FW writing device 1, and the fixed vector 115 are transmitted to the FW update target device 2 (step S4). The CRC value at this time is the calculated CRC value corresponding to the program area to be updated, and the CRC value for all program areas.

FW更新対象装置2は、FW書込ツール11から送信された更新対象のプログラム213、CRC値214、および固定ベクタ215の各データを受信し(ステップS9)、FW用メモリ212内の該当する領域211にこれらのデータを格納する更新処理を行う(ステップS10)。 The FW update target device 2 receives each data of the update target program 213, CRC value 214, and fixed vector 215 transmitted from the FW writing tool 11 (step S9), and stores the corresponding area in the FW memory 212. Update processing is performed to store these data in 211 (step S10).

FW用メモリ212内の各領域へデータを格納して更新処理が完了すると、ブートプログラム21内で全領域のプログラムのCRC値の演算を行い、受信した全領域のプログラムに対するCRC値213と比較し、健全性の確認を行う(ステップS11)。この健全性の確認により、CRC値が一致した場合には、更新完了通知をFW書込ツール11に送信し(ステップS12)、FW書込準備処理部111において完了表示がされた時点で、ファームウェアの書き込み終了となる(ステップS5)。 When data is stored in each area in the FW memory 212 and the update process is completed, the boot program 21 calculates the CRC value of the program in all areas and compares it with the CRC value 213 for the received program in all areas. , the soundness is confirmed (step S11). As a result of this health check, if the CRC values match, an update completion notification is sent to the FW writing tool 11 (step S12), and when the FW writing preparation processing unit 111 indicates completion, the firmware Writing ends (step S5).

次に、ファームウェアの更新処理の詳細について更に図4~図6を参照して説明する。
図4は、図2で示したステップS1、(すなわち、バイナリ変換されたファームウェア112を複数のプログラムの領域に分割し、分割した各プログラム領域、および全領域に対してCRC演算を行い、CRC値を付加するステップS1)における処理の詳細を示すフロー図である。
Next, details of the firmware update process will be further explained with reference to FIGS. 4 to 6.
FIG. 4 shows step S1 shown in FIG. FIG. 3 is a flow diagram showing details of the process in step S1) for adding a .

まず、入力情報チェックとして、更新用のファームウェア112のファイル拡張子をチェックし(ステップS20)、適切でなければ入力情報異常として異常終了する(ステップS21)。 First, as an input information check, the file extension of the update firmware 112 is checked (step S20), and if the file extension is not appropriate, the input information is considered abnormal and the process ends abnormally (step S21).

ステップS20で適切であれば、更新用のファームウェア112を16byteずつ読み込み、フォーマットチェック、およびデータサイズチェックを行う(ステップS22)。チェック異常となれば、入力ファイル異常として異常終了する(ステップS23)。
一方、チェックが正常となれば、バイナリ変換(BIN化)し、各々の領域サイズごとにバイナリ変換したファイルを複数の領域に分割し、分割した各領域のファイルについてCRC演算を行う。そして、バイナリ変換後の領域サイズごとに分割されたプログラム、これに対応するCRC値、および固定ベクタからなるデータを各領域に分けて蓄積する(ステップS24)。
If it is found appropriate in step S20, the update firmware 112 is read 16 bytes at a time, and a format check and a data size check are performed (step S22). If the check is found to be abnormal, it is assumed that the input file is abnormal and the process ends abnormally (step S23).
On the other hand, if the check is normal, binary conversion (BIN conversion) is performed, the binary converted file is divided into a plurality of areas for each area size, and a CRC calculation is performed on the file of each divided area. Then, data consisting of programs divided by area size after binary conversion, corresponding CRC values, and fixed vectors are stored in each area (step S24).

このステップS24の処理を全てのプログラム領域に渡って繰り返し、各データの作成が完了したなら、全プログラム領域に対するCRC値の算出を行い(ステップS25)、入力ファイルの準備完了となる(ステップS26)。 The process of step S24 is repeated over all program areas, and when the creation of each data is completed, the CRC value for all program areas is calculated (step S25), and the input file preparation is completed (step S26). .

図5は、図2で示したステップS3、(すなわち、FW更新対象装置2から受信した現時点のCRC値とFW書込ツール11の側で演算して得られたCRC値とを比較し、両CRC値が一致しないプログラム領域を特定し、FW更新対象装置2に対する更新すべきプログラム領域を決定するステップS3)における処理の詳細を示すフロー図である。 FIG. 5 shows step S3 shown in FIG. FIG. 7 is a flow diagram showing details of the process in step S3) of identifying a program area whose CRC values do not match and determining a program area to be updated for the FW update target device 2. FIG.

CRC値を比較する際には、まず、FW更新対象装置2のFW用メモリ212に格納されている現時点のCRC値を取得し(ステップS30)、分割された領域ごとにCRC値を比較する(ステップS31)。CRC値が不一致の場合は、ファームウェアに含まれる更新すべきプログラムであるから、ダウンロード用の図示しないバッファに格納する(ステップS32)。CRC値が一致する場合には、更新すべきプログラムではないのでステップS31に戻り、次の分割された領域についてCRC値を比較する。 When comparing CRC values, first, the current CRC value stored in the FW memory 212 of the FW update target device 2 is obtained (step S30), and the CRC values are compared for each divided area ( Step S31). If the CRC values do not match, the program is included in firmware and should be updated, so it is stored in a buffer (not shown) for download (step S32). If the CRC values match, the program does not need to be updated, so the process returns to step S31 and the CRC values of the next divided area are compared.

全てのプログラム領域について上記処理が完了すると、完了フラグを立てて(ステップS33)、本処理を終了する。なお、この完了フラグをもってFW更新対象装置2へのファームウェアの送信処理(ステップS4)を開始する。 When the above processing is completed for all program areas, a completion flag is set (step S33), and this processing is ended. Note that with this completion flag, the firmware transmission process to the FW update target device 2 (step S4) is started.

図6は、図3で示したステップS9~ステップS12、すなわち、FW更新対象装置2におけるファームウェア更新手順の処理における詳細を示すフロー図である。 FIG. 6 is a flowchart showing details of steps S9 to S12 shown in FIG. 3, that is, the firmware update procedure in the FW update target device 2.

FW書込ツール11から書き込みデータ(すなわち、更新するプログラム213、FW書込装置1で算出されたCRC値214、および固定ベクタ215)を受信すると、受信した書き込みデータのチェックを行う(ステップS40)。正常にチェックが完了すると、書き込みデータに付与されている開始アドレスに基づいてFW用メモリ212の特定のデータ領域にプログラム213、CRC値214、および固定ベクタ215の各データを書き込む(ステップS41)。 When the write data (that is, the program to be updated 213, the CRC value 214 calculated by the FW write device 1, and the fixed vector 215) is received from the FW writing tool 11, the received write data is checked (step S40). . When the check is completed normally, each data of the program 213, CRC value 214, and fixed vector 215 is written to a specific data area of the FW memory 212 based on the start address given to the write data (step S41).

データの書き込みが正常に完了すると、全体のCRCチェックのために、CRC値を計算し、送信されてきた全プログラム領域のCRC値と比較して健全性のチェックを行う(ステップS42)。これらの処理が完了すると、FW書込装置1に対して完了通知を送信する(ステップS43)。 When data writing is completed normally, a CRC value is calculated for the overall CRC check, and the soundness is checked by comparing it with the CRC values of all the transmitted program areas (step S42). When these processes are completed, a completion notification is sent to the FW writing device 1 (step S43).

なお、各処理ステップS40、S41、S42においていずれも異常となった場合には、異常終了する(ステップS44)。特に、ステップS41でFW用メモリ212へのデータの書き込みが異常となった場合には、ファームウェア更新前の状態に戻しておく(ステップS45)。これにより、ファームウェア更新前の健全性が確保される。 Note that if any abnormality occurs in each processing step S40, S41, and S42, the process ends abnormally (step S44). In particular, if writing of data to the FW memory 212 becomes abnormal in step S41, the state is returned to the state before the firmware update (step S45). This ensures the soundness before firmware update.

以上のように、この実施の形態1では、従来のようにFW更新対象装置2のFW用メモリ212内の全プログラム領域を全消去し、その後に更新するファームウェアをプログラム領域に書き込むのではなくて、FW書込装置1によるFW更新対象装置2に対する書き込み指示に応じて、FW更新対象装置2は、現時点でFW用メモリ212に格納されている各領域のCRC値を返答し、このCRC値とFW書込装置1で算出したCRC値とを比較することで更新すべきプログラム領域を特定し、その特定したプログラム領域に関してのみ更新用のプログラムを書き込むので、従来に比べて、ファームウェアをアップデートする際に要する更新時間を大幅に短縮することができる。 As described above, in the first embodiment, instead of completely erasing the entire program area in the FW memory 212 of the FW update target device 2 and then writing the firmware to be updated into the program area, as in the conventional case. In response to the write instruction from the FW writing device 1 to the FW update target device 2, the FW update target device 2 responds with the CRC value of each area currently stored in the FW memory 212, and uses this CRC value and The program area to be updated is identified by comparing the CRC value calculated by the FW writing device 1, and the update program is written only for the identified program area, making it easier to update the firmware than in the past. The update time required can be significantly reduced.

なお、本願は、例示的な実施の形態が記載されているが、実施の形態に記載された様々な特徴、態様、および機能は特定の実施の形態の適用に限られるものではなく、単独で、または様々な組み合わせで実施の形態に適用可能である。 Note that although exemplary embodiments are described in this application, various features, aspects, and functions described in the embodiments are not limited to application of a particular embodiment, and may be used independently. , or can be applied to the embodiments in various combinations.

したがって、例示されていない無数の変形例が、本願に開示される技術の範囲内において想定される。例えば、少なくとも一つの構成要素を変形する場合、追加する場合、または省略する場合が含まれものとする。 Therefore, countless variations not illustrated are envisioned within the scope of the technology disclosed herein. For example, at least one component may be modified, added, or omitted.

1 FW書込装置、11 FW書込ツール、111 FW書込準備処理部、
112 更新用のファームウェア、2 FW更新対象装置、22 スイッチ、
211 FW書込処理部、212 FW用メモリ。
1 FW writing device, 11 FW writing tool, 111 FW writing preparation processing unit,
112 Firmware for update, 2 FW update target device, 22 Switch,
211 FW write processing unit, 212 FW memory.

Claims (3)

更新用のファームウェアを書き込むためのFW書込装置から、前記ファームウェアの更新対象となるFW更新対象装置に対して前記ファームウェアを書き込む場合に、前記ファームウェアの更新に先立ち、前記FW書込装置で前記ファームウェアをバイナリデータに変換した後に複数のプログラムに分割して各プログラムに対応するCRC値を個別に算出しておき、前記FW書込装置による前記FW更新対象装置に対する書き込み指示に応じて、前記FW更新対象装置は、このFW更新対象装置が備えるFW用メモリに現時点で格納されている各領域のCRC値を返答し、前記FW書込装置がこのCRC値と予め算出したCRC値とを比較することで前記FW用メモリにおける更新すべきプログラムの記憶領域を特定し、その特定したプログラムの記憶領域に関してのみ前記FW更新対象装置が更新用のプログラムを前記FW用メモリに書き込む、ファームウェアアップデート方法。 When writing the firmware from a FW writing device for writing update firmware to a FW update target device to which the firmware is to be updated, the FW writing device writes the firmware prior to updating the firmware. is converted into binary data, divided into a plurality of programs, a CRC value corresponding to each program is calculated individually, and the FW is updated in accordance with a write instruction to the FW update target device by the FW writing device. The target device replies with the CRC value of each area currently stored in the FW memory of this FW update target device, and the FW writing device compares this CRC value with a CRC value calculated in advance. A firmware update method in which a storage area of a program to be updated in the FW memory is specified, and the FW update target device writes an update program into the FW memory only for the specified storage area of the program. 更新用のファームウェアを書き込むためのFW書込装置と、前記ファームウェアの更新対象となるFW更新対象装置とを備え、
前記FW書込装置は、前記ファームウェアを記憶するとともに、前記ファームウェアを前記FW更新対象装置に書き込むFW書込ツールを搭載しており、
前記FW書込ツールは、前記FW更新対象装置に対して前記ファームウェアを書き込む場合に、前記ファームウェアをバイナリデータに変換した後に複数のプログラムに分割し、各々の前記プログラムに対してそれぞれCRC値を個別に算出するとともに、この算出されたCRC値と前記FW更新対象装置から返答される現時点のCRC値とを比較し、両CRC値が不一致の場合にのみ、その不一致のCRC値を有するプログラムを前記FW更新対象装置に送信するものであり、
前記FW更新対象装置は、前記ファームウェアを構成する各プログラムならびに各プログラムに個別に対応して設定されたCRC値を記憶するFW用メモリと、前記FW書込装置から送信される更新用のプログラムを算出されたCRC値と共に前記FW用メモリに書き込むFW書込処理部とを有し、
前記FW書込処理部は、前記FW書込装置の前記FW書込ツールによる前記ファームウェアの書き込み指示に応答して、前記FW用メモリに記憶されている現時点のCRC値を読み出して前記FW書込ツールに送信するとともに、前記FW書込ツールにより送信されてくるCRC値を有するプログラムを前記FW用メモリのCRC値が不一致となった領域に書き込むものである、ファームウェアアップデートシステム。
comprising an FW writing device for writing firmware for update, and a FW update target device to which the firmware is updated,
The FW writing device stores the firmware and is equipped with a FW writing tool that writes the firmware to the FW update target device,
When writing the firmware to the FW update target device, the FW writing tool converts the firmware into binary data, divides it into a plurality of programs, and individually assigns a CRC value to each of the programs. At the same time, this calculated CRC value is compared with the current CRC value returned from the FW update target device, and only when the two CRC values do not match, the program having the mismatched CRC value is It is sent to the device subject to FW update,
The FW update target device has an FW memory that stores each program constituting the firmware and a CRC value set individually corresponding to each program, and an update program sent from the FW writing device. an FW write processing unit that writes the calculated CRC value to the FW memory,
The FW write processing unit reads the current CRC value stored in the FW memory and writes the FW in response to an instruction to write the firmware by the FW write tool of the FW write device. A firmware update system that writes a program having a CRC value transmitted to a tool and also transmitted by the FW writing tool to an area of the FW memory where the CRC value does not match.
前記FW更新対象装置は、前記ファームウェアの更新起動用のスイッチを備え、前記スイッチが操作された場合にのみ前記ファームウェアを前記FW用メモリに書き込むためのブートプログラムを起動することにより、前記ファームウェアの誤更新を防ぐものである、請求項2に記載のファームウェアアップデートシステム。 The FW update target device includes a switch for starting the firmware update, and starts a boot program for writing the firmware into the FW memory only when the switch is operated, thereby preventing errors in the firmware. The firmware update system according to claim 2, wherein the firmware update system prevents updates.
JP2022068716A 2022-04-19 2022-04-19 Firmware update method and firmware update system Pending JP2023158751A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2022068716A JP2023158751A (en) 2022-04-19 2022-04-19 Firmware update method and firmware update system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2022068716A JP2023158751A (en) 2022-04-19 2022-04-19 Firmware update method and firmware update system

Publications (1)

Publication Number Publication Date
JP2023158751A true JP2023158751A (en) 2023-10-31

Family

ID=88513842

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2022068716A Pending JP2023158751A (en) 2022-04-19 2022-04-19 Firmware update method and firmware update system

Country Status (1)

Country Link
JP (1) JP2023158751A (en)

Similar Documents

Publication Publication Date Title
CN107239411B (en) Memory management method and system for vehicle-mounted controller
US20010020263A1 (en) Information processing apparatus and method
US8036786B2 (en) On-vehicle control apparatus
JP2023158751A (en) Firmware update method and firmware update system
CN113220319A (en) Data updating method and device and vehicle
JP6447469B2 (en) Rewriting system
CN111506449B (en) Air conditioner parameter storage method and device and storage medium
JP4417994B2 (en) Material data recording apparatus and material data recording method
EP4130985A1 (en) Communication device and information processing method
JP4950214B2 (en) Method for detecting a power outage in a data storage device and method for restoring a data storage device
JP4127307B2 (en) Data storage device, data processing system, data processing method, and data processing device
JP4851525B2 (en) Data processing system and driving method thereof
JP4867557B2 (en) Programmable controller
US10720222B2 (en) Solid state storage device using state prediction method
JP2019160080A (en) Controller and abnormality detection method
JP2004126658A (en) Processor system
JP3514173B2 (en) Control device
KR20030011553A (en) Electronic apparatus and correction method
CN114115755B (en) Method and device for data writing and storage medium
CN117289974A (en) FPGA programming file trusted update loading system and method for DCS controller
US7089447B2 (en) Apparatus and method for compression based error correction procedure in a data processing system
JP2006276981A (en) Transmitter, its program, and recording medium
JPH0816488A (en) Electronic disk device
CN115993978A (en) Firmware upgrading method and device
US20220129198A1 (en) Data updates for controllers