JP2012008677A - Automatic discrimination device and automatic discrimination method for version upgrade file using ftp - Google Patents

Automatic discrimination device and automatic discrimination method for version upgrade file using ftp Download PDF

Info

Publication number
JP2012008677A
JP2012008677A JP2010142367A JP2010142367A JP2012008677A JP 2012008677 A JP2012008677 A JP 2012008677A JP 2010142367 A JP2010142367 A JP 2010142367A JP 2010142367 A JP2010142367 A JP 2010142367A JP 2012008677 A JP2012008677 A JP 2012008677A
Authority
JP
Japan
Prior art keywords
file
upgrade
version
stored
ftp
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
JP2010142367A
Other languages
Japanese (ja)
Inventor
Shinji Tabuchi
慎司 田渕
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.)
Hioki EE Corp
Original Assignee
Hioki EE 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 Hioki EE Corp filed Critical Hioki EE Corp
Priority to JP2010142367A priority Critical patent/JP2012008677A/en
Publication of JP2012008677A publication Critical patent/JP2012008677A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)
  • Stored Programmes (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide an automatic discrimination device for a file storing a version upgrade program for rewriting a control program of a storage unit of a controller.SOLUTION: An automatic discrimination device 10 for a file that rewrites a control program of a storage unit 14 of a controller from an old version to a new version includes a CPU 12 that rewrites the control program from an old version to a new version on the basis of a version upgrade program in a file with a predetermined extension transferred via FTP from a data transmission device 24 inserted into a LAN input port 22 of the automatic discrimination device. The CPU 12 includes: recognition means 30 for recognizing the file transferred from the data transmission device 24 on the basis of the extension; and apparatus ID discrimination means 32 for reading the file recognized by the recognition means 30 from the beginning, and then, when an apparatus ID in the file matches an apparatus ID in the storage unit 14, starting reading the rest of the file.

Description

本発明は、制御対象の機器を制御する制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに適式に書き換えるバージョンアッププログラムが格納されたバージョンアップ用ファイルを自動判別するFTPを用いたバージョンアップ用ファイルの自動判別装置及び自動判別方法に関するものである。   The present invention provides an FTP that automatically discriminates a version-up file in which a version-up program for properly rewriting a control program stored in a storage unit of a control device that controls a device to be controlled from an old version to a new version is stored. The present invention relates to an automatic discrimination apparatus and automatic discrimination method for used version upgrade files.

測定装置や工作機器等の機器には、機器が実行する種々の動作等を制御する制御装置が設けられている。この制御装置では、その記憶部に記憶された制御プログラムに基づいて、CPU(Central Processing Unit)等のデータ処理ユニットから機器の各部に信号を発信している。かかる制御プログラムの不具合の解消や機器の能力向上等のため、制御プログラムを旧バージョンから新バージョンに書き換えるバージョンアップがなされている。かかるバージョンアップを、例えば下記特許文献1に記載されているように、バージョンアッププログラムを記憶するパーソナルコンピュータ(PC)等のデータ送信装置(以下、単にデータ送信装置と称することがある)を用いて実施する場合がある。この場合には、図4に示す様に、所定のコマンドをデータ送信装置と機器との間で送受信してからバージョンアップが実行される。   Devices such as measuring devices and machine tools are provided with a control device that controls various operations performed by the devices. In this control device, a signal is transmitted from a data processing unit such as a CPU (Central Processing Unit) to each unit of the device based on a control program stored in the storage unit. In order to solve such a problem of the control program and improve the capability of the device, the control program is upgraded from an old version to a new version. For example, as described in Patent Document 1 below, this version upgrade is performed using a data transmission apparatus (hereinafter, simply referred to as a data transmission apparatus) such as a personal computer (PC) that stores the version upgrade program. May be implemented. In this case, as shown in FIG. 4, the upgrade is executed after a predetermined command is transmitted / received between the data transmitting apparatus and the device.

図4に示す様に、所定のコマンドをデータ送信装置と機器との間で送受信してからバージョンアップを実行する際には、先ず、バージョンアッププログラムを記憶するデータ送信装置と機器とをLANケーブルで接続した後、データ送信装置が保有するバージョンアップ用のアプリケーションソフトを立ち上げ、データ送信装置から機器にバージョンアップ用コマンドを送信する。かかるバージョンアップ用コマンドを受信した機器では、バージョンアップしてもよい状態にあるとき、データ送信装置にバージョンアップOKの返答コマンドを送信する。この返答コマンドを受信したデータ送信装置では、機器にバージョンアッププログラムを送信する。バージョンアッププログラムを受信した機器では、バージョンアッププログラムに基づいて、制御装置の記憶部を構成する揮発メモリとしてのRAM(Random Access Memory)に読み込んだ後、制御装置の記憶装置の記憶部を構成する書き換え可能な不揮発メモリとしてのフラッシュROM(Read Only Memory)に記憶されている旧バージョンの制御用プログラムを消去し、RAMに記憶されている新バージョンの制御用プログラムを書き込む。   As shown in FIG. 4, when the upgrade is performed after a predetermined command is transmitted / received between the data transmission device and the device, first, the data transmission device and the device storing the upgrade program are connected to the LAN cable. After the connection, the application software for upgrading owned by the data transmission device is started, and the upgrade command is transmitted from the data transmission device to the device. When the device that has received such a version upgrade command is in a state where the version upgrade is possible, the device transmits a version upgrade OK response command to the data transmission apparatus. The data transmitting apparatus that has received this reply command transmits the upgrade program to the device. In the device that has received the upgrade program, the storage unit of the storage device of the control device is configured after reading into a RAM (Random Access Memory) as a volatile memory that constitutes the storage unit of the control device based on the upgrade program An old version control program stored in a flash ROM (Read Only Memory) as a rewritable nonvolatile memory is erased, and a new version control program stored in the RAM is written.

特開2002−186066号公報JP 2002-186066 A

前述した図4に示すバージョンアップの方法によれば、所定機器のバージョンアッププログラムをインターネット等を介して取得したパーソナルコンピュータ(PC)等のデータ送信装置から機器に直接送信できる。このため、機器のバージョンアップを、データ送信装置が保有するバージョンアッププログラムをUSB(Universal Serial Bus)やCD(Compact Disc)等の外部記録媒体に一旦転送することなく実行できる。しかし、図4に示すバージョンアップの方法では、データ送信装置側にバージョンアップのコマンドを使ったプログラムの組み込みと、バージョンアップ用のアプリケーションソフトとを必要として煩雑である。また、データ送信装置に記憶されているバージョンアッププログラムが、別の機器に用いられるバージョンアッププログラムである場合には、そのバージョンアップは実行できない。例え、バージョンアップが実行できたとしても、バージョンアップされた機器は誤作動したり、或いは作動しなくなるおそれもある。   According to the version upgrade method shown in FIG. 4 described above, a version upgrade program for a predetermined device can be directly transmitted to the device from a data transmission device such as a personal computer (PC) acquired via the Internet or the like. Therefore, the upgrade of the device can be executed without once transferring the upgrade program held by the data transmission apparatus to an external recording medium such as a USB (Universal Serial Bus) or a CD (Compact Disc). However, the upgrade method shown in FIG. 4 is complicated because it requires installation of a program using an upgrade command on the data transmitting apparatus side and application software for upgrading. Further, when the upgrade program stored in the data transmission device is an upgrade program used for another device, the upgrade cannot be executed. Even if the version upgrade can be executed, the upgraded device may malfunction or stop operating.

本発明は前記の課題を解決するためになされたものであって、制御対象の機器を制御する制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに適式に書き換えるバージョンアッププログラムを記憶しているデータ送信装置から機器の制御部に、所定のコマンドを用いることなく送信でき、且つそのバージョンアッププログラムが適式なものであることを自動判別できるバージョンアップ用ファイルの自動判別装置及び自動判別方法を提供することを目的とする。   The present invention has been made to solve the above-described problem, and is an upgrade program for properly rewriting a control program stored in a storage unit of a control device that controls a device to be controlled from an old version to a new version Can be transmitted without using a predetermined command from the data transmission device storing the information to the control unit of the device, and the automatic determination device for the upgrade file can automatically determine that the upgrade program is appropriate And it aims at providing the automatic discrimination method.

前記の目的を達成するためになされた、特許請求の範囲の請求項1に記載されたFTPを用いたバージョンアップ用ファイルの自動判別装置は、制御対象の機器を制御する制御装置に設けられ、前記制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに適式に書き換えるバージョンアッププログラムが格納されたバージョンアップ用ファイルを自動判別する判別装置であって、前記判別装置には、前記機器を特定する識別子である機器ID及び前記旧バージョンの制御プログラムが記憶された前記記憶部と、前記機器ID及び前記バージョンアッププログラムが格納されているバージョンアップ用ファイルであることを、前記ファイルを読み込むことなく認識できるように認識記号が付与されたバージョンアップ用ファイルをファイル転送用プロトコル(FTP)でデータ送信するデータ送信装置がLANケーブルを介して接続されるLAN入力ポートと、前記LAN入力ポートに接続された前記データ送信装置からファイル転送用プロトコル(FTP)でバージョンアップ用ファイルを取得したとき、前記ファイルに格納されているバージョンアッププログラムに基づき、前記制御プログラムを旧バージョンから新バージョンに書き換える書換処理を実行するデータ処理ユニットとを備え、前記データ処理ユニットには、前記データ送信装置からファイル転送用プロトコル(FTP)で転送されたファイルが、前記バージョンアップ用ファイルであることを前記認識記号に基いて認識する認識手段と、前記認識手段で認識されたバージョンアップ用ファイルを先頭から順次読み込み、前記ファイルに格納された機器IDと前記記憶部に記憶された機器IDとが一致したとき、前記データ処理ユニットでの前記書換処理が可能となるように、前記バージョンアップ用ファイルの残部の読み込みを開始する機器ID判別手段とを具備することを特徴とする。   An automatic determination device for an upgrade file using FTP according to claim 1, which has been made to achieve the above object, is provided in a control device that controls a device to be controlled, A discriminating device for automatically discriminating an upgrade file in which an upgrade program for properly rewriting the control program stored in the storage unit of the control device from an old version to a new version is stored, The storage unit storing the device ID, which is an identifier for identifying the device, and the control program of the previous version; and the upgrade file storing the device ID and the upgrade program. Version with a recognition symbol so that it can be recognized without reading A LAN input port to which a data transmission device that transmits data by a file transfer protocol (FTP) is connected via a LAN cable, and a file transfer protocol (FTP) from the data transmission device connected to the LAN input port A data processing unit that executes a rewriting process for rewriting the control program from an old version to a new version based on a version upgrade program stored in the file when the version upgrade file is obtained The recognizing unit recognizes that the file transferred from the data transmission device by the file transfer protocol (FTP) is the version-up file based on the recognition symbol, and the recognizing unit recognizes the file. Upgrade version The version is updated so that the data processing unit can perform the rewriting process when the device ID stored in the file and the device ID stored in the storage unit match. And a device ID discriminating means for starting reading of the remainder of the file.

請求項2に記載されたFTPを用いたバージョンアップ用ファイルの自動判別装置は、請求項1に記載されているものであって、前記バージョンアップ用ファイルには、前記バージョンアップ用ファイルであることを示す認識記号としての拡張子が付されていることを特徴とする。   An automatic discrimination device for an upgrade file using FTP described in claim 2 is the one described in claim 1, wherein the upgrade file is the upgrade file. It is characterized in that an extension as a recognition symbol indicating is attached.

請求項3に記載されたFTPを用いたバージョンアップ用ファイルの自動判別装置は、請求項1に記載されているものであって、前記機器IDが、前記制御プログラム内に格納されていることを特徴とする。   An automatic determination device for an upgrade file using FTP described in claim 3 is the one described in claim 1, wherein the device ID is stored in the control program. Features.

請求項4に記載されたFTPを用いたバージョンアップ用ファイルの自動判別装置は、請求項3に記載されているものであって、前記機器IDが、前記制御プログラムの先頭近傍に格納されていることを特徴とする。   The automatic identification device for version upgrade files using FTP described in claim 4 is the one described in claim 3, wherein the device ID is stored near the top of the control program. It is characterized by that.

請求項5に記載されたFTPを用いたバージョンアップ用ファイルの自動判別方法は、制御対象の機器を制御する制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに書き換えるバージョンアッププログラムが格納されたバージョンアップ用ファイルをデータ送信するデータ装置を用いて、前記制御プログラムのバージョンアップを実行する際に、前記データ装置として、前記機器を特定する識別子である機器ID及び前記バージョンアッププログラムが格納されたバージョンアップ用ファイルであることを、前記ファイルを読み込むことなく認識できる認識記号が付されたバージョンアップ用ファイルをファイル転送用プロトコル(FTP)でデータ送信するデータ装置を用い、前記データ装置をLANケーブルで前記制御装置のLAN入力ポートに接続し、前記データ装置からファイル転送用プロトコル(FTP)で転送されたファイルが、前記バージョンアップ用ファイルであることを前記認識記号に基いて認識した後、前記バージョンアップ用ファイルの先頭から順次読み込み、前記ファイルに格納された機器IDと前記記憶部に予め記憶された機器IDとが一致したとき、前記バージョンアッププログラムに基づいて、前記制御装置のデータ処理ユニットによって前記制御プログラムを旧バージョンから新バージョンに書き換える書換処理を可能とすべく、前記バージョンアップ用ファイルの残部の読み込みを開始することを特徴とする。   An automatic determination method of an upgrade file using FTP according to claim 5 is an upgrade program for rewriting a control program stored in a storage unit of a control device that controls a device to be controlled from an old version to a new version. When performing a version upgrade of the control program using a data device that transmits a version upgrade file in which data is stored, a device ID that is an identifier for identifying the device as the data device and the version upgrade program Using a data device that transmits a version upgrade file with a recognition symbol that can be recognized without reading the file by using a file transfer protocol (FTP). LAN cable for device After connecting to the LAN input port of the control device and recognizing that the file transferred from the data device by the file transfer protocol (FTP) is the upgrade file based on the recognition symbol, A data processing unit of the control device is read based on the upgrade program when the device ID stored in the file and the device ID stored in advance in the storage unit coincide with each other when sequentially reading from the top of the file for upgrade In order to enable rewriting processing for rewriting the control program from the old version to the new version, reading of the remainder of the upgrade file is started.

請求項6に記載されたFTPを用いたバージョンアップ用ファイルの自動判別方法は、請求項5に記載されたものであって、前記バージョンアップ用ファイルには、前記バージョンアップ用ファイルであることを示す認識記号としての拡張子を付していることを特徴とする。   The automatic determination method of the upgrade file using FTP described in claim 6 is described in claim 5, wherein the upgrade file is the upgrade file. An extension as a recognition symbol to be shown is added.

請求項7に記載されたFTPを用いたバージョンアップ用ファイルの自動判別方法は、請求項5に記載されたものであって、前記機器IDを、前記制御プログラム内に格納していることを特徴とする。   An automatic determination method for an upgrade file using FTP according to claim 7 is the method according to claim 5, wherein the device ID is stored in the control program. And

請求項8に記載されたFTPを用いたバージョンアップ用ファイルの自動判別方法は、請求項7に記載されたものであって、前記機器IDを、前記制御プログラムの先頭近傍に格納していることを特徴とする。   The automatic determination method of the file for upgrade using FTP described in claim 8 is the method described in claim 7, wherein the device ID is stored in the vicinity of the head of the control program. It is characterized by.

本発明によれば、データ送信装置に記憶されているバージョンアッププログラムが格納されているバージョンアップ用ファイルを、ファイル転送用プロトコル(FTP)を用いて機器の制御部に転送できる。このため、データ送信装置側のバージョンアップのコマンドを使ったプログラムの組み込みやバージョンアップ用のアプリケーションソフトを不要化でき簡素化できる。   According to the present invention, an upgrade file in which an upgrade program stored in a data transmission device is stored can be transferred to a control unit of a device using a file transfer protocol (FTP). For this reason, it is possible to eliminate and simplify the incorporation of a program using the upgrade command on the data transmission apparatus side and the application software for the upgrade.

また、本発明によれば、データ送信装置に記憶されているファイルが、バージョンアッププログラムが格納されたバージョンアップ用ファイルであることは、その認識記号によってファイルを読み込むことなく簡単に認識できる。しかも、認識されたバージョンアップ用ファイルを、そのファイル内に格納された機器IDの箇所まで読み込み、ファイル内の機器IDと制御装置の記憶部に予め記憶された機器IDとが一致したとき、そのバージョンアップ用ファイルには、適式のバージョンアッププログラムが収容されていることを簡単に判断できる。その結果、適式なバージョンアッププログラムが格納されたバージョンアップ用ファイルを自動判別できる。このため、バージョンアップ用ファイルの残部を引き続いて読み込むことによって、制御装置の制御プログラムに対して適式なバージョンアップを迅速に且つ確実に実行できる。   Further, according to the present invention, it is possible to easily recognize that the file stored in the data transmission device is an upgrade file in which the upgrade program is stored without reading the file by the recognition symbol. In addition, when the recognized version-up file is read up to the location of the device ID stored in the file and the device ID in the file matches the device ID stored in advance in the storage unit of the control device, It can be easily determined that the version upgrade file contains a proper version upgrade program. As a result, it is possible to automatically determine an upgrade file in which a proper upgrade program is stored. For this reason, it is possible to quickly and reliably execute a proper version upgrade for the control program of the control device by continuously reading the remainder of the version upgrade file.

本発明に係るFTPを用いたバージョンアップ用ファイルの自動判別装置の一例を説明するブロック図である。It is a block diagram explaining an example of the automatic discrimination apparatus of the file for a version upgrade using FTP which concerns on this invention. 図1に示すFTPを用いたバージョンアップ用ファイルの自動判別装置の動作を説明するフローチャートである。3 is a flowchart for explaining the operation of the automatic upgrade device for version upgrade files using FTP shown in FIG. 1. 図1に示す記憶部に記憶された制御プログラムの一例を説明する説明図である。It is explanatory drawing explaining an example of the control program memorize | stored in the memory | storage part shown in FIG. 従来のバージョンアップの手順を説明するフローチャートである。It is a flowchart explaining the procedure of the conventional version upgrade.

以下、本発明について図面を用いて詳細に説明するが、本発明の範囲はこれらの図面に限定されるものではない。   Hereinafter, the present invention will be described in detail with reference to the drawings, but the scope of the present invention is not limited to these drawings.

本発明に係るFTPを用いたバージョンアップ用ファイルの自動判別装置の一例を説明するためのブロック図を図1に示す。図1に示すFTPを用いたバージョンアップ用ファイルの自動判別装置10(以下、単に自動判別装置10と称することがある)には、データ処理ユニットとして、CPU(Central Processing Unit)12が設けられている。このCPU12は、記憶部14のフラッシュROM(Read Only Memory:以下、単にROM16と称することがある)とRAM(Random Acces Memory:以下、単にRAM18と称することがある)とバス20を介して接続されている。かかるCPU12は、記憶部14のROM16に記憶されている制御プログラムに基づいて電子制御対象である機器の動作を制御している。また、CPU12には、LAN入力ポート22に接続されるPC等のFTP機能付きデータ送信装置24(以下、単にデータ送信装置24と称することがある)やタッチパネルやキーボード等の操作入力部26から種々のデータが入力される。入力されたデータは、CPU12を介して記憶部14のROM16やRAM18に記憶され、表示部28に表示され、或いは機器の制御に用いられる。かかる記憶部14のROM16に記憶されている制御プログラムには、制御プログラムを読むことなく認識できるように、認識記号としての拡張子である「.VER」が予め付与されている。更に、この制御プログラムの先頭近傍には、この制御プログラムに基づいて制御されている機器を特定する識別子である機器IDが格納されている。更に、制御プログラムには、データ送信装置24とのファイルの送受信に用いるファイル転送用プロトコル(FTP)も収納されている。   FIG. 1 is a block diagram for explaining an example of an automatic file identification device for upgrading using FTP according to the present invention. 1 is provided with a CPU (Central Processing Unit) 12 as a data processing unit. The automatic file identification device 10 for upgrading files using FTP shown in FIG. Yes. The CPU 12 is connected to a flash ROM (Read Only Memory: hereinafter simply referred to as ROM 16) and a RAM (Random Access Memory: hereinafter simply referred to as RAM 18) of the storage unit 14 via a bus 20. ing. The CPU 12 controls the operation of the device to be electronically controlled based on the control program stored in the ROM 16 of the storage unit 14. Further, the CPU 12 has various functions such as a data transmission device 24 with an FTP function such as a PC connected to the LAN input port 22 (hereinafter sometimes simply referred to as the data transmission device 24), and an operation input unit 26 such as a touch panel and a keyboard. Data is input. The input data is stored in the ROM 16 or the RAM 18 of the storage unit 14 via the CPU 12 and displayed on the display unit 28 or used for device control. The control program stored in the ROM 16 of the storage unit 14 is previously given an extension “.VER” as a recognition symbol so that it can be recognized without reading the control program. Further, a device ID, which is an identifier for identifying a device controlled based on this control program, is stored near the top of this control program. Further, the control program also stores a file transfer protocol (FTP) used for transmission / reception of files with the data transmission device 24.

また、データ送信装置24には、拡張子に「.VER」が付与されたバージョンアップ用ファイルが記憶されている。かかるバージョンアップ用ファイルには、新バージョンの制御プログラムが格納されており、その制御プログラムの先頭近傍には、新バージョンの制御プログラムを適用する機器を特定する機器IDが格納されている。更に、新バージョンの制御プログラムにも、ファイル転送用プロトコル(FTP)が収納されている。尚、データ送信装置24には、バージョンアップ用ファイルの他に種々のファイルが収容されていてもよい。   Further, the data transmission device 24 stores an upgrade file with an extension “.VER”. In this version upgrade file, a new version of the control program is stored, and a device ID for identifying a device to which the new version of the control program is applied is stored near the top of the control program. Further, the new version of the control program also contains a file transfer protocol (FTP). The data transmission device 24 may accommodate various files in addition to the upgrade file.

図1に示す自動判別装置10では、図2に示す手順でバージョンアップを実行する。図2では、自動判別装置10を装置10として示した。先ず、データ送信装置24を自動判別装置10のLAN入力ポート22にLANケーブルで接続し、データ送信装置24と自動判別装置10とをFTP接続する(ステップS10、ステップS12)。次いで、データ送信装置24の画面等の表示部(図示せず)に表示されたファイルのうちから自動判別装置10に送信するファイルを指定し、指定したファイルをデータ送信装置24から自動判別装置10にFTPを用いて転送を開始する(ステップS14)。この様に、ファイルの転送が開始されると、CPU12では、認識手段30(図1)を起動する。この認識手段30では、転送されたファイルの拡張子を調査する(ステップS16)。かかる拡張子の調査において、転送されたファイルの拡張子がROM16に記憶されている拡張子と不一致の場合には、当該ファイルはバージョンアップ用ファイルではなく別目的で用いるファイルであると判断し、当該ファイルの全体を読み込みRAM18に記憶させてバージョンアップを実行せず終了する(ステップS30)。   In the automatic discrimination device 10 shown in FIG. 1, the version upgrade is executed according to the procedure shown in FIG. In FIG. 2, the automatic discrimination device 10 is shown as the device 10. First, the data transmission device 24 is connected to the LAN input port 22 of the automatic determination device 10 with a LAN cable, and the data transmission device 24 and the automatic determination device 10 are FTP-connected (steps S10 and S12). Next, a file to be transmitted to the automatic determination device 10 is specified from among files displayed on a display unit (not shown) such as a screen of the data transmission device 24, and the specified file is transmitted from the data transmission device 24 to the automatic determination device 10 The transfer is started using FTP (step S14). In this way, when the file transfer is started, the CPU 12 activates the recognition means 30 (FIG. 1). This recognition means 30 checks the extension of the transferred file (step S16). When the extension of the transferred file does not match the extension stored in the ROM 16 in the investigation of the extension, it is determined that the file is not a version upgrade file but a file used for another purpose. The entire file is read and stored in the RAM 18, and the process is terminated without executing version upgrade (step S30).

一方、ステップS16において、データ送信装置24から転送されたファイルの拡張子が、ROM16に記憶されている拡張子と同一の拡張子「.VER」であるとき、CPU12では、そのファイルがバージョンアップ用ファイルであると判断して、機器ID判別手段32(図1)を起動する。機器ID判別手段32では、拡張子「.VER」が付与されているバージョンアップ用ファイルに格納されている新バージョンの制御プログラムを先頭から機器IDが格納されている箇所までRAM18に順次読み込む(ステップS18)。この際に、機器IDは、制御プログラムを先頭近傍に格納されているため、その読み込みは極めて短時間である。読み込んだ機器IDとROM16の制御プログラム内の機器IDとが一致したとき、機器ID判別手段32では、一部読み込んだ新バージョンの制御プログラムは、ROM16の制御プログラムを適式にバージョンアップするものであると判断し(ステップS20)、バージョンアップを開始する(ステップS22)。かかるバージョンアップでは、新バージョンの制御プログラムの残部をRAM18に読み込む(ステップS26)。次いで、CPU12は、ROM16に記憶されていた旧バージョンの制御プログラムを消去し、新バージョンの制御プログラムをRAM18からROM16に書き込んで、バージョンアップを終了する(ステップS28)。   On the other hand, when the extension of the file transferred from the data transmission device 24 is the same extension “.VER” as the extension stored in the ROM 16 in step S16, the CPU 12 determines that the file is for version upgrade. If it is determined that the file is a file, the device ID discrimination means 32 (FIG. 1) is activated. The device ID discriminating means 32 sequentially reads the new version of the control program stored in the upgrade file with the extension “.VER” from the head to the location where the device ID is stored in the RAM 18 (step S18). At this time, since the device ID is stored in the vicinity of the head of the control program, the reading is extremely short. When the read device ID matches the device ID in the control program of the ROM 16, the device ID discriminating means 32 upgrades the control program of the ROM 16 in a proper manner. Judgment is made (step S20), and version upgrade is started (step S22). In such version upgrade, the remaining part of the control program of the new version is read into the RAM 18 (step S26). Next, the CPU 12 erases the old version of the control program stored in the ROM 16, writes the new version of the control program from the RAM 18 to the ROM 16, and finishes the version upgrade (step S28).

ここで、ステップS20において、拡張子に「.VER」が付与されているバージョンアップ用ファイルに格納されている機器IDとROM16の制御プログラム内の機器IDとが不一致の場合には、当該バージョンアップ用ファイルに格納されている制御プログラムは別機器用のものであると判断し、転送された当該ファイルを削除し(ステップS32)、その旨を表示部28に表示(ステップS34)してバージョンアップを終了する。   If the device ID stored in the upgrade file with the extension “.VER” does not match the device ID in the control program in the ROM 16 in step S20, the version upgrade is performed. The control program stored in the file for use is determined to be for another device, the transferred file is deleted (step S32), and a message to that effect is displayed on the display unit 28 (step S34). Exit.

この様に、図1及び図2に示す自動判別装置10及び自動判別方法では、データ送信装置24に取得されているファイルを、FTPを用いて自動判別装置10に転送できる。このため、データ送信装置24側のバージョンアップのコマンドを使ったプログラムの組み込みやバージョンアップ用のアプリケーションソフトを不要化でき簡素化できる。また、データ送信装置24から転送されたファイルについての拡張子を調査し、バージョンアップ用ファイルであるか否かの判断をしている。このため、ユーザがバージョンアップ用ファイルの名称等を知らなくてもバージョンアップができる。更に、ファイルを読み込んで、バージョンアッププログラムが存在するか否かを判断する場合に比較しても、迅速にバージョンアップ用ファイルであるか否かの判断ができる。しかも、バージョンアップ用ファイルであると判断した場合でも、その新バージョンの制御プログラム内の機器IDと記憶部14に記憶されている機器IDとが一致したときに旧バージョンから新バージョンに書き換える。このため、新バージョンの制御プログラムが、旧バージョンの制御プログラムに対応するものであることを確実に確認できる。   As described above, in the automatic determination device 10 and the automatic determination method shown in FIGS. 1 and 2, the file acquired in the data transmission device 24 can be transferred to the automatic determination device 10 using FTP. For this reason, the incorporation of a program using the upgrade command on the data transmission device 24 side and the application software for upgrading can be eliminated and simplified. Further, the extension of the file transferred from the data transmission device 24 is checked to determine whether it is a version upgrade file. Therefore, the version can be upgraded without the user knowing the name or the like of the version upgrade file. Furthermore, even if the file is read and it is determined whether or not an upgrade program exists, it can be quickly determined whether or not the file is an upgrade file. In addition, even when it is determined that the file is an upgrade file, the old version is rewritten to the new version when the device ID in the control program of the new version matches the device ID stored in the storage unit 14. For this reason, it can be confirmed reliably that the control program of the new version corresponds to the control program of the old version.

ところで、ROM16の制御プログラムが、図3に示す様に、複数の制御プログラムに分割されていた場合、その一部の制御プログラム、例えば図3に示す第1制御プログラムのみをバージョンアップしたい場合にも、図1及び図2に示す自動判別装置10及び自動判別方法を適用できる。また、分割されている複数の制御プログラム、例えば図3に示す第1制御プログラム〜第3制御プログラムを同時にバージョンアップしたい場合にも、図1及び図2に示す自動判別装置10及び自動判別方法を適用できる。   By the way, when the control program of the ROM 16 is divided into a plurality of control programs as shown in FIG. 3, it is also possible to upgrade only a part of the control programs, for example, the first control program shown in FIG. The automatic discrimination device 10 and the automatic discrimination method shown in FIGS. 1 and 2 can be applied. Also, when it is desired to simultaneously upgrade a plurality of divided control programs, for example, the first to third control programs shown in FIG. 3, the automatic discrimination device 10 and the automatic discrimination method shown in FIGS. Applicable.

これまで説明してきた図1及び図2に示す自動判別装置10及び自動判別方法では、ROM16に予め記憶されている旧バージョンの制御プログラム内の機器IDと、データ送信装置24から読み込んだ新バージョンの制御プログラム内の機器IDとが一致するか否かを機器ID判別手段32がステップS20で比較する場合について説明したが、ROM16に制御プログラムとは別個に機器IDを予め記憶させておき、この別個に記憶された機器IDと、新バージョンの制御プログラム内の機器IDとが一致するか否かを機器ID判別手段32がステップS20で判別し、一致したときにステップS22以下を実行するようにしてもよい。この様に、ROM16に制御プログラムとは別個に機器IDが予め記憶されている場合、バージョンアップ用ファイルの構造を、機器IDを含まない制御プログラム部分と、機器IDを含む先頭データ部分とを結合したファイル構造にして、ステップS20で、ROM16に予め記憶された機器IDと、バージョンアップ用ファイルの先頭データ部分の機器IDとが一致したときに、ステップS26でバージョンアップ用ファイルの制御用プログラム部分だけを読み込んで、その制御用プログラム部分だけをステップS28でROM16に書き込んでもよい。この場合、CPU12は、制御プログラムを読み込むことなく機器IDをチェックすることが可能である。更に、バージョンアップする制御プログラムにFTPが収納されている例について示したが、FTPを制御プログラムに収納せずに、ROM16に制御プログラムとは別個にFTPを予め記憶させておき、この別個に記憶させたFTPにより、制御用プログラムをバージョンアップしてもよい。   In the automatic determination device 10 and the automatic determination method shown in FIGS. 1 and 2 described so far, the device ID in the old version control program stored in advance in the ROM 16 and the new version read from the data transmission device 24 are stored. Although the case where the device ID determination unit 32 compares the device ID in the control program with each other in step S20 has been described, the device ID is stored in advance in the ROM 16 separately from the control program. In step S20, the device ID determination unit 32 determines whether or not the device ID stored in the device ID matches the device ID in the new version of the control program. Also good. In this way, when the device ID is stored in advance in the ROM 16 separately from the control program, the structure of the upgrade file is combined with the control program portion not including the device ID and the head data portion including the device ID. When the device ID stored in advance in the ROM 16 matches the device ID of the head data portion of the upgrade file in step S20, the control program portion of the upgrade file in step S26. Only the control program portion may be written in the ROM 16 in step S28. In this case, the CPU 12 can check the device ID without reading the control program. Furthermore, although an example is shown in which FTP is stored in the control program to be upgraded, FTP is not stored in the control program, but is stored in advance in the ROM 16 separately from the control program. The control program may be upgraded by using the FTP that has been set.

また、図1及び図2に示す自動判別装置10及び自動判別方法では、ステップ20において、拡張子に「.VER」が付与されているバージョンアップ用ファイルに格納されている機器IDとROM16の制御プログラム内の機器IDとが不一致の場合には、転送された当該ファイルを削除していたが、当該ファイルをRAM18に読み込んでからバージョンアップを終了してもよい。更に、ROM16やRAM18をハードディスクドライブに換えてもよい。尚、図1及び図2に示す自動判別装置10及び自動判別方法は、電力測定器の制御装置に好適に適用できる。   Further, in the automatic discrimination device 10 and the automatic discrimination method shown in FIGS. 1 and 2, in step 20, the device ID stored in the upgrade file having the extension “.VER” and the control of the ROM 16 are controlled. If the device ID in the program does not match, the transferred file has been deleted. However, the upgrade may be terminated after the file is read into the RAM 18. Further, the ROM 16 and RAM 18 may be replaced with a hard disk drive. Note that the automatic discrimination device 10 and the automatic discrimination method shown in FIGS. 1 and 2 can be suitably applied to a control device for a power meter.

本発明に係るバージョンアップ用ファイルの自動判別装置及び自動判別方法は、測定装置や工作機器等の機器を制御する制御プログラムのバージョンアップに好適に適用できる。   The automatic file identification apparatus and automatic classification method according to the present invention can be preferably applied to version upgrade of a control program for controlling devices such as a measuring device and a machine tool.

10は自動判別装置、12はCPU、14は記憶部、16はフラッシュROM、18はRAM、20はバス、22はLAN入力ポート、24はデータ送信装置、26は操作入力部、28は表示部、30は認識手段、32は機器ID判別手段、S10〜S34はフローチャートにおけるステップである。   10 is an automatic discrimination device, 12 is a CPU, 14 is a storage unit, 16 is a flash ROM, 18 is a RAM, 20 is a bus, 22 is a LAN input port, 24 is a data transmission device, 26 is an operation input unit, and 28 is a display unit , 30 are recognition means, 32 is a device ID determination means, and S10 to S34 are steps in the flowchart.

Claims (8)

制御対象の機器を制御する制御装置に設けられ、前記制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに適式に書き換えるバージョンアッププログラムが格納されたバージョンアップ用ファイルを自動判別する判別装置であって、
前記判別装置には、前記機器を特定する識別子である機器ID及び前記旧バージョンの制御プログラムが記憶された前記記憶部と、
前記機器ID及び前記バージョンアッププログラムが格納されているバージョンアップ用ファイルであることを、前記ファイルを読み込むことなく認識できるように認識記号が付与されたバージョンアップ用ファイルをファイル転送用プロトコル(FTP)でデータ送信するデータ送信装置がLANケーブルを介して接続されるLAN入力ポートと、
前記LAN入力ポートに接続された前記データ送信装置からファイル転送用プロトコル(FTP)でバージョンアップ用ファイルを取得したとき、前記ファイルに格納されているバージョンアッププログラムに基づき、前記制御プログラムを旧バージョンから新バージョンに書き換える書換処理を実行するデータ処理ユニットとを備え、
前記データ処理ユニットには、前記データ送信装置からファイル転送用プロトコル(FTP)で転送されたファイルが、前記バージョンアップ用ファイルであることを前記認識記号に基いて認識する認識手段と、
前記認識手段で認識されたバージョンアップ用ファイルを先頭から順次読み込み、前記ファイルに格納された機器IDと前記記憶部に記憶された機器IDとが一致したとき、前記データ処理ユニットでの前記書換処理が可能となるように、前記バージョンアップ用ファイルの残部の読み込みを開始する機器ID判別手段とを具備することを特徴とするFTPを用いたバージョンアップ用ファイルの自動判別装置。
Provided in a control device that controls the device to be controlled, and automatically discriminates an upgrade file that stores an upgrade program that properly rewrites the control program stored in the storage unit of the control device from the old version to the new version. A discrimination device for
In the determination device, the storage unit in which the device ID which is an identifier for specifying the device and the control program of the old version are stored,
A file transfer protocol (FTP) is provided with an upgrade file to which a recognition symbol is added so that the device ID and the upgrade program in which the device upgrade program is stored can be recognized without reading the file. A LAN input port to which a data transmission device for data transmission is connected via a LAN cable;
When an upgrade file is acquired from the data transmission device connected to the LAN input port by a file transfer protocol (FTP), the control program is updated from the previous version based on the upgrade program stored in the file. With a data processing unit that executes rewrite processing to rewrite to a new version,
Recognizing means for recognizing that the file transferred from the data transmitting apparatus by the file transfer protocol (FTP) is the version-up file based on the recognition symbol in the data processing unit;
The upgrade file recognized by the recognition unit is sequentially read from the top, and when the device ID stored in the file matches the device ID stored in the storage unit, the rewrite processing in the data processing unit An apparatus for automatically discriminating an upgrade file using FTP, comprising: an apparatus ID discriminating unit that starts reading the remaining part of the upgrade file.
前記バージョンアップ用ファイルには、前記バージョンアップ用ファイルであることを示す認識記号としての拡張子が付されていることを特徴とする請求項1に記載のFTPを用いたバージョンアップ用ファイルの自動判別装置。   The automatic upgrade of an upgrade file using FTP according to claim 1, wherein the upgrade file has an extension as a recognition symbol indicating that it is the upgrade file. Discriminator. 前記機器IDが、前記制御プログラム内に格納されていることを特徴とする請求項1に記載のFTPを用いたバージョンアップ用ファイルの自動判別装置。   The apparatus for automatically identifying a version upgrade file using FTP according to claim 1, wherein the device ID is stored in the control program. 前記機器IDが、前記制御プログラムの先頭近傍に格納されていることを特徴とする請求項3に記載のFTPを用いたバージョンアップ用ファイルの自動判別装置。   4. The apparatus for automatically discriminating an upgrade file using FTP according to claim 3, wherein the device ID is stored in the vicinity of the head of the control program. 制御対象の機器を制御する制御装置の記憶部に記憶された制御プログラムを旧バージョンから新バージョンに書き換えるバージョンアッププログラムが格納されたバージョンアップ用ファイルをデータ送信するデータ装置を用いて、前記制御プログラムのバージョンアップを実行する際に、
前記データ装置として、前記機器を特定する識別子である機器ID及び前記バージョンアッププログラムが格納されたバージョンアップ用ファイルであることを、前記ファイルを読み込むことなく認識できる認識記号が付されたバージョンアップ用ファイルをファイル転送用プロトコル(FTP)でデータ送信するデータ装置を用い、
前記データ装置をLANケーブルで前記制御装置のLAN入力ポートに接続し、前記データ装置からファイル転送用プロトコル(FTP)で転送されたファイルが、前記バージョンアップ用ファイルであることを前記認識記号に基いて認識した後、
前記バージョンアップ用ファイルの先頭から順次読み込み、前記ファイルに格納された機器IDと前記記憶部に予め記憶された機器IDとが一致したとき、前記バージョンアッププログラムに基づいて、前記制御装置のデータ処理ユニットによって前記制御プログラムを旧バージョンから新バージョンに書き換える書換処理を可能とすべく、前記バージョンアップ用ファイルの残部の読み込みを開始することを特徴とするFTPを用いたバージョンアップ用ファイルの自動判別方法。
The control program using a data device that transmits a version upgrade file that stores a version upgrade program that rewrites a control program stored in a storage unit of a control device that controls a device to be controlled from an old version to a new version. When performing version upgrade of
As the data device, for the upgrade, to which a device ID that is an identifier for identifying the device and a version upgrade file in which the version upgrade program is stored can be recognized without reading the file Using a data device that sends data using file transfer protocol (FTP),
The data device is connected to the LAN input port of the control device by a LAN cable, and the file transferred from the data device by the file transfer protocol (FTP) is the version upgrade file based on the recognition symbol. After recognizing
When the device ID sequentially read from the head of the upgrade file matches the device ID stored in the file and the device ID stored in advance in the storage unit, data processing of the control device is performed based on the upgrade program A method of automatically discriminating an upgrade file using FTP, characterized in that reading of the remainder of the upgrade file is started so as to enable rewriting processing for rewriting the control program from an old version to a new version by a unit. .
前記バージョンアップ用ファイルには、前記バージョンアップ用ファイルであることを示す認識記号としての拡張子を付していることを特徴とする請求項5に記載のFTPを用いたバージョンアップ用ファイルの自動判別方法。   6. The automatic upgrade of an upgrade file using FTP according to claim 5, wherein the upgrade file has an extension as a recognition symbol indicating that it is the upgrade file. How to determine. 前記機器IDを、前記制御プログラム内に格納していることを特徴とする請求項5に記載のFTPを用いたバージョンアップ用ファイルの自動判別方法。   6. The method for automatically discriminating a version upgrade file using FTP according to claim 5, wherein the device ID is stored in the control program. 前記機器IDを、前記制御プログラムの先頭近傍に格納していることを特徴とする請求項7に記載のFTPを用いたバージョンアップ用ファイルの自動判別方法。
8. The method for automatically discriminating an upgrade file using FTP according to claim 7, wherein the device ID is stored near the head of the control program.
JP2010142367A 2010-06-23 2010-06-23 Automatic discrimination device and automatic discrimination method for version upgrade file using ftp Pending JP2012008677A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010142367A JP2012008677A (en) 2010-06-23 2010-06-23 Automatic discrimination device and automatic discrimination method for version upgrade file using ftp

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010142367A JP2012008677A (en) 2010-06-23 2010-06-23 Automatic discrimination device and automatic discrimination method for version upgrade file using ftp

Publications (1)

Publication Number Publication Date
JP2012008677A true JP2012008677A (en) 2012-01-12

Family

ID=45539171

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010142367A Pending JP2012008677A (en) 2010-06-23 2010-06-23 Automatic discrimination device and automatic discrimination method for version upgrade file using ftp

Country Status (1)

Country Link
JP (1) JP2012008677A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017005959A (en) * 2015-06-16 2017-01-05 株式会社東芝 Digital protection controller

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000112723A (en) * 1998-09-30 2000-04-21 Toshiba Corp Video reproducing device and program updating method to apply to the reproducing device
JP2001216167A (en) * 2000-02-04 2001-08-10 Minolta Co Ltd System consisting of main body and peripheral device
JP2003051796A (en) * 2001-08-07 2003-02-21 J-Phone West Co Ltd Downloading system
JP2004274964A (en) * 2003-03-12 2004-09-30 Tm T & D Kk Control device
JP2005157577A (en) * 2003-11-21 2005-06-16 Victor Co Of Japan Ltd Program update method
JP2007047993A (en) * 2005-08-09 2007-02-22 Rohm Co Ltd Control circuit, electronic equipment using it and update method for firmware
JP2007280415A (en) * 2007-06-04 2007-10-25 Hitachi Electronics Service Co Ltd Management device, version management system and program version management method
JP2009123134A (en) * 2007-11-19 2009-06-04 Mimaki Engineering Co Ltd Usb host device and method for manufacturing usb host device

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000112723A (en) * 1998-09-30 2000-04-21 Toshiba Corp Video reproducing device and program updating method to apply to the reproducing device
JP2001216167A (en) * 2000-02-04 2001-08-10 Minolta Co Ltd System consisting of main body and peripheral device
JP2003051796A (en) * 2001-08-07 2003-02-21 J-Phone West Co Ltd Downloading system
JP2004274964A (en) * 2003-03-12 2004-09-30 Tm T & D Kk Control device
JP2005157577A (en) * 2003-11-21 2005-06-16 Victor Co Of Japan Ltd Program update method
JP2007047993A (en) * 2005-08-09 2007-02-22 Rohm Co Ltd Control circuit, electronic equipment using it and update method for firmware
JP2007280415A (en) * 2007-06-04 2007-10-25 Hitachi Electronics Service Co Ltd Management device, version management system and program version management method
JP2009123134A (en) * 2007-11-19 2009-06-04 Mimaki Engineering Co Ltd Usb host device and method for manufacturing usb host device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017005959A (en) * 2015-06-16 2017-01-05 株式会社東芝 Digital protection controller

Similar Documents

Publication Publication Date Title
TW200414045A (en) Firmware updating method and related apparatus for checking content of replacing firmware before firmware updating
JP4955099B2 (en) Optical disk drive device
WO2020062887A1 (en) Firmware upgrading method and system based on flash micro-controller, and flash micro-controller
US20170140497A1 (en) Display operation system
US9361138B2 (en) Peripheral device, method of controlling peripheral device, firmware download system and program
US20100030922A1 (en) Computer peripheral device implemented as optic storage device or/and removable disk by software emulation and implementing method thereof
EP1647885A2 (en) Rewriting a non-volatile memory
CN109614118B (en) SPI Flash firmware burning method and device
JP2009543251A (en) Portable device with user interface
JP2012008677A (en) Automatic discrimination device and automatic discrimination method for version upgrade file using ftp
JP5707061B2 (en) Automatic discrimination device and automatic discrimination method for version upgrade file
CN113434467B (en) Network file transmission method, device and computer readable storage medium
US8156257B2 (en) Removeable medium, formatting device, formatting system, formatting method, and formatting program
TWI614684B (en) Field firmware upgrading method and computer-readable medium
EP2730993B1 (en) Reset method and network device
JP2007207089A (en) External storage device controller and program
US20050210233A1 (en) System and method for updating a basic Input/Output system program
KR100713971B1 (en) Method for discriminating firmware download in optical disc device
JP6385264B2 (en) Information processing apparatus, memory control method for information processing apparatus, and program
US20080091399A1 (en) Driverless signal generating apparatus and control method thereof
JP2005010912A (en) Program and computer
JP2011145810A (en) Method for rewriting program data and equipment control system
JP2005092392A (en) Recovery method for personal computer and usb descriptor rewrite program
US7600067B2 (en) Methods for identifying bridge devices and systems thereof
CN115129379A (en) Hardware initialization method and device, electronic equipment and computer readable storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20130606

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20140225

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20140226

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140418

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20141118