JP2006133889A - Method for updating program, program and device - Google Patents

Method for updating program, program and device Download PDF

Info

Publication number
JP2006133889A
JP2006133889A JP2004319596A JP2004319596A JP2006133889A JP 2006133889 A JP2006133889 A JP 2006133889A JP 2004319596 A JP2004319596 A JP 2004319596A JP 2004319596 A JP2004319596 A JP 2004319596A JP 2006133889 A JP2006133889 A JP 2006133889A
Authority
JP
Japan
Prior art keywords
difference data
memory
program
operation mode
data
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
JP2004319596A
Other languages
Japanese (ja)
Inventor
Nobuhiko Funato
信彦 舟渡
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.)
Sharp Corp
Original Assignee
Sharp 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 Sharp Corp filed Critical Sharp Corp
Priority to JP2004319596A priority Critical patent/JP2006133889A/en
Publication of JP2006133889A publication Critical patent/JP2006133889A/en
Pending legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide a method for updating a program incorporated in a terminal, whose memory capacity is limited and on which an MMU-adaptable OS is mounted, by using difference data received by a communication means, and to provide the program, device and terminal therefor. <P>SOLUTION: The difference data for updating the program are received and stored in a memory in a first operation mode where memory protection by an MMU is operated, and the operation mode is switched to a second operation mode where memory protection by the MMU is not operated, and the stored difference data are acquired so that the program can be updated by using the difference data. When the received difference data are stored in the memory, the conversion of a logical address and a physical address space is operated by the MMP, and the information on address conversion for the storage region of the difference data isheld, thereby accessing the difference data in the second operation mode. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、通信手段によって受信した差分データを用いて端末装置に内蔵されるプログラムの更新を行うための方法、プログラムおよび端末装置に関し、特に、メモリ容量に制限があり、MMU対応のOSを搭載した携帯型の端末装置においてプログラムの更新を行うための方法、プログラムおよび端末装置に関するものである。   The present invention relates to a method, a program, and a terminal device for updating a program built in a terminal device using difference data received by a communication means, and particularly has a limited memory capacity and is equipped with an MMU-compatible OS. The present invention relates to a method, a program, and a terminal device for updating a program in a portable terminal device.

携帯電話機や携帯情報端末(PDA等)などの通信手段を備えた携帯型の端末装置に内蔵されるソフトウェアは大規模化しており、プログラムの改良や不具合対応のために、製品出荷後も端末外部からアップデート用データを供給して、これらのプログラムの更新を行うことがある。   The software built in portable terminal devices equipped with communication means such as mobile phones and personal digital assistants (PDAs, etc.) has become large-scale, and even after product shipment, the outside of the terminal has been expanded in order to improve programs and deal with problems. These programs may be updated by supplying update data.

従来、このようなデータの供給は、サポートを行う店舗などにおいて、有線通信経由で行われてきたが、近年では、重大な不具合の解消を急いだり、更新作業のサポートコストを低減したりするために、無線通信経由でデータの供給が行なわれている。このようにデータを無線通信で供給する場合、無線リンクの帯域が小さいことと、携帯型の端末装置ではパーソナルコンピュータなどの汎用のコンピュータに比べてメモリ容量が小さいことから、供給するデータのサイズをできるだけ小さくすることが要求される。   Conventionally, such data has been supplied via wired communication at stores that provide support, but in recent years in order to expedite the resolution of serious problems and to reduce support costs for renewal work. In addition, data is supplied via wireless communication. When data is supplied by wireless communication in this way, the size of the data to be supplied is reduced because the bandwidth of the wireless link is small and the portable terminal device has a smaller memory capacity than a general-purpose computer such as a personal computer. It is required to be as small as possible.

特許文献1には、供給データのサイズを小さくするために、データの送信側において、端末装置内のプログラムの更新前のバージョンと更新後のバージョンを比較して得られる差分を抽出して、その差分データのみを端末装置に伝送し、端末装置では、装置内にあるデータ(更新対象となるプログラム)と受信した差分データとから更新後データを復元し、この更新後データにより更新対象となるプログラムの格納領域を書き換えることによりプログラムを更新する方法が開示されている。   In Patent Document 1, in order to reduce the size of the supply data, on the data transmission side, a difference obtained by comparing the version before update and the version after update of the program in the terminal device is extracted. Only the difference data is transmitted to the terminal device, and the terminal device restores the updated data from the data in the device (program to be updated) and the received difference data, and the program to be updated by this updated data A method of updating a program by rewriting the storage area is disclosed.

しかしながら、携帯型の端末装置では、差分データから書換えに用いる更新後のデータ、すなわち更新対象となるプログラムを全て復元するだけの作業領域を確保できないほどメモリ容量が小さいことがある。   However, in a portable terminal device, the memory capacity may be so small that it is not possible to secure a work area sufficient to restore all the data to be updated, that is, the updated data used for rewriting from the difference data.

この問題に対処する方法として、特許文献2には、対象プログラムを複数の領域に区分しておき、データの送信側ではそれらの領域ごとに差分データを抽出し、全ての差分データをまとめたものを伝送する差分データとし、端末装置では、更新後データの復元を個々の領域に対する差分データごとに行い、全ての領域の更新後データが復元されるのを待つことなく、個々の領域の更新後データを更新対象プログラムの格納領域に書き込むことにより、全ての領域の更新後データを同時に保持することを必要とせずプログラム更新を行う方法が開示されている。また、特許文献3には、特許文献2に開示された方法において、個々の領域ごとに抽出される差分データを小さくする方法が開示されている。   As a method for coping with this problem, Patent Document 2 discloses that the target program is divided into a plurality of areas, and on the data transmission side, difference data is extracted for each area, and all the difference data is collected. The terminal device performs the restoration of the updated data for each differential data for each area, and after updating each area without waiting for the restored data for all areas to be restored. There has been disclosed a method for updating a program by writing data in the storage area of the update target program without having to simultaneously hold updated data in all areas. Patent Document 3 discloses a method of reducing the difference data extracted for each region in the method disclosed in Patent Document 2.

非特許文献1には、特許文献1、特許文献2および特許文献3における構成要素となる2つのプログラムの対応する領域間の差分データ抽出処理の基礎的アルゴリズムである「Block-Moveアルゴリズム」が開示されている。   Non-Patent Document 1 discloses “Block-Move Algorithm”, which is a basic algorithm for extracting difference data between corresponding regions of two programs as constituent elements in Patent Document 1, Patent Document 2, and Patent Document 3. Has been.

一方で、大規模化している携帯端末のソフトウェアの不具合による影響を抑えるための別の方法として、端末装置で動作するOS(オペレーティングシステム)にMMU(メモリ管理ユニット)を利用してメモリ保護を行う方法が知られている(以下、このようなOSをMMU対応のOSと呼ぶ)。MMU非対応のOSでは、特定のアプリケーションの不具合が他のアプリケーションやシステム全体に影響を及ぼすのに対して、MMU対応のOSでは、このような影響を局所化し低減できるという利点がある。このため、携帯電話機のOSは、μITRONなどのMMU非対応のOSから、LinuxやSymbianのようなMMU対応のOSに移行しつつある。   On the other hand, as another method for suppressing the influence caused by the malfunction of the software of the mobile terminal which is becoming large-scale, the memory protection is performed by using the MMU (memory management unit) for the OS (operating system) operating on the terminal device. A method is known (hereinafter, such an OS is referred to as an MMU-compatible OS). In an OS that does not support MMU, a failure of a specific application affects other applications or the entire system, whereas an OS that supports MMU has an advantage that such an effect can be localized and reduced. For this reason, the OS of mobile phones is shifting from an OS that does not support MMU, such as μITRON, to an OS that supports MMU, such as Linux and Symbian.

特開平8−255104号公報。JP-A-8-255104. 特開2004−234503号公報。Japanese Patent Application Laid-Open No. 2004-234503. 特開2004−227520号公報。JP 2004-227520 A. Walter F. Tichy, The String-to-String Correction Problem with Block Moves, ACM Transaction on Computing Systems, Nov.1984 (Vol.2, No.4), pp.309-321Walter F. Tichy, The String-to-String Correction Problem with Block Moves, ACM Transaction on Computing Systems, Nov.1984 (Vol.2, No.4), pp.309-321

一般に、上記のような携帯型の端末装置のメモリは、RAMなどの書換え可能な揮発性メモリと、フラッシュROMなどの書換え可能な不揮発性メモリとから構成されており、前者は作業領域および/または一時データの格納領域として用いられ、後者は命令コードや命令コードが用いる初期化データなどから構成されるプログラムおよび/または永続的なデータの格納領域として用いられる。携帯電話などにおいては、生産コストを低減するために可能な範囲でメモリ容量を小さくしようとするので、命令コードや定数データの領域は、RAMにコピーされることなく、フラッシュROMなどの書換え可能不揮発性メモリから直接読み出されることが多い。   In general, the memory of the portable terminal device as described above is composed of a rewritable volatile memory such as a RAM and a rewritable nonvolatile memory such as a flash ROM. The former is a work area and / or The latter is used as a temporary data storage area, and the latter is used as a storage area for programs and / or permanent data composed of instruction codes and initialization data used by the instruction codes. In mobile phones, etc., we try to reduce the memory capacity as much as possible in order to reduce production costs, so the area for instruction codes and constant data is not copied to RAM, but is rewritable and non-volatile such as flash ROM. Often read directly from the memory.

一方、MMU対応のOSでは、通常、プログラムや定数データの領域はMMUによって保護されているので、MMUよるメモリ管理が行われている最中に当該メモリ上にあるプログラムの書換えを行うことは不可能である。特許文献1〜3および非特許文献1には、このようなMMU対応のOSを搭載した端末装置においてプログラムの更新を行う方法は具体的に言及されていない。   On the other hand, in an MMU-compatible OS, since the program and constant data areas are usually protected by the MMU, it is not possible to rewrite the program in the memory while the memory management by the MMU is being performed. Is possible. Patent Documents 1 to 3 and Non-Patent Document 1 do not specifically mention a method for updating a program in such a terminal device equipped with an MMU-compatible OS.

本発明は、このような実情に鑑みてなされたものであり、メモリ容量に制限があり、MMU対応のOSを搭載した端末装置に内蔵されているプログラムを、通信手段によって受信した差分データを用いて更新するための方法、プログラムおよび端末装置を提供しようとするものである。   The present invention has been made in view of such circumstances, has a limited memory capacity, and uses differential data received by communication means for a program built in a terminal device equipped with an MMU-compatible OS. It is an object of the present invention to provide a method, a program, and a terminal device for updating the program.

上記解決課題に鑑みて鋭意研究の結果、本発明者は、MMUによるメモリ保護が行われる第1の動作モードにおいてプログラム更新用の差分データを受信してメモリに格納した後に、動作モードを、MMUによるメモリ保護が行われない第2の動作モードに切り替えて、格納しておいた差分データを取得し、これを用いてプログラムの更新を行うことに想到した。ここで、受信した差分データをメモリに格納する際には、MMUによる論理アドレスと物理アドレス空間との変換が行われているが、差分データの格納領域についてのアドレス変換に関する情報を保持しておくことにより、後の第2の動作モードにおいて差分データへのアクセスを可能とすることができる。   As a result of diligent research in view of the above problem, the present inventor, after receiving the differential data for program update in the first operation mode in which memory protection is performed by the MMU and storing it in the memory, changes the operation mode to the MMU. It was conceived to switch to the second operation mode in which the memory protection is not performed, to acquire the stored difference data, and to update the program using this. Here, when the received difference data is stored in the memory, the logical address and the physical address space are converted by the MMU, but information regarding the address conversion for the storage area of the difference data is held. This makes it possible to access the difference data in the second operation mode later.

すなわち、本発明は、プログラム更新用の差分データを用いて端末装置のプログラムを更新する方法であって、前記差分データを取得する差分データ取得ステップと、OSによるメモリ管理が行われる第1の動作モードにおいて、前記差分データをメモリに格納する差分データ格納ステップと、前記差分データのメモリにおける配置に関する情報を取得し、メモリに格納する差分データ配置情報格納ステップと、前記メモリに格納された内容を保持したまま、前記第1の動作モードから、OSによるメモリ管理が行われない第2の動作モードに切り替えを行う切り換えを行う動作モード切り換えステップと、前記第2の動作モードにおいて、前記メモリに格納された差分データ配置情報に基づいて、前記差分データをメモリから取得する差分データ復元ステップと、前記差分データを用いて、前記プログラムの更新を行うプログラム更新ステップと、を含む方法を提供するものである。   That is, the present invention is a method for updating a program of a terminal device using difference data for program update, and includes a difference data acquisition step for acquiring the difference data and a first operation in which memory management is performed by the OS. In the mode, a difference data storage step for storing the difference data in a memory, information on an arrangement of the difference data in the memory, a difference data arrangement information storage step for storing in the memory, and contents stored in the memory An operation mode switching step for switching from the first operation mode to a second operation mode in which memory management by the OS is not performed is held and stored in the memory in the second operation mode. Difference for acquiring the difference data from the memory based on the difference data arrangement information And over data restoration step, using the difference data, a program updating step of updating of the program, there is provided a method comprising.

本発明のプログラム更新方法では、前記メモリは、前記第1の動作モード及び前記第2の動作モードにおいて利用可能なファイルシステムとして構成されており、前記差分データ格納ステップにおいて、前記ファイルシステム上のファイルに差分データを格納し、前記差分データ配置情報格納ステップにおいて、前記差分データの配置情報として、前記差分データを格納したファイルを特定する情報を取得及びし格納し、前記差分データ復元ステップにおいて、前記差分データ配置情報に基づき、前記差分データを格納したファイルを読み出すことにより前記差分データを取得することを特徴とする。   In the program update method of the present invention, the memory is configured as a file system that can be used in the first operation mode and the second operation mode, and in the differential data storage step, a file on the file system is configured. In the difference data arrangement information storage step, information specifying the file storing the difference data is acquired and stored as the difference data arrangement information, and in the difference data restoration step, The difference data is acquired by reading a file storing the difference data based on the difference data arrangement information.

本発明のプログラム更新方法では、前記メモリは、前記差分データがとり得る最大のサイズ以上のサイズのダミーファイルを格納しており、前記差分データ取得ステップにおいて、取得した差分データを前記ダミーファイルに上書きする処理を行うことを特徴とする。   In the program update method of the present invention, the memory stores a dummy file having a size equal to or larger than a maximum size that can be taken by the difference data. In the difference data acquisition step, the acquired difference data is overwritten on the dummy file. It is characterized in that the processing is performed.

本発明のプログラム更新方法では、前記差分データ格納ステップにおいて、前記差分データを前記メモリにおける1つ以上の物理アドレス空間上の領域に格納し、前記差分データ配置情報格納ステップにおいて、前記領域の物理アドレス空間上の位置及びサイズと、前記差分データの格納順序に関する情報とを取得及び格納することを特徴とする。   In the program update method of the present invention, in the differential data storage step, the differential data is stored in an area on one or more physical address spaces in the memory, and in the differential data arrangement information storage step, the physical address of the area is stored. It acquires and stores the position and size in space and information related to the storage order of the difference data.

本発明のプログラム更新方法は、前記差分データ格納ステップを実行する前に、前記メモリにおいて前記差分データを格納するのに必要となる物理アドレス空間上の領域の数を削減するステップをさらに含んでいることを特徴とする。具体的には、前記差分データ格納ステップを実行する前に、プログラム更新処理に不要な作業を中止し、それに利用されていたメモリ領域を解放するステップ、あるいは、OSの再起動を行うステップとすることができる。   The program update method of the present invention further includes a step of reducing the number of areas on the physical address space required for storing the differential data in the memory before executing the differential data storage step. It is characterized by that. Specifically, before executing the difference data storing step, a step unnecessary for the program update process is stopped and a memory area used for the step is released, or a step of restarting the OS is performed. be able to.

本発明のプログラム更新方法では、前記差分データ取得ステップにおいて、通信手段によりプログラム更新用の差分データを前記端末装置外部から取得することを特徴とする。   In the program update method of the present invention, in the differential data acquisition step, differential data for program update is acquired from the outside of the terminal device by communication means.

本発明のプログラム更新方法において、前記OSによるメモリ管理は、MMUによる論理アドレス及び物理アドレス間のアドレス変換により実現されることを特徴とする。   In the program update method of the present invention, the memory management by the OS is realized by address conversion between a logical address and a physical address by the MMU.

本発明は、また、上記したいずれかのプログラム更新方法を用いて、端末装置のプログラム更新処理を実行するプログラムを提供するものである。さらには、そのようなプログラムを記録した記録媒体が提供される。   The present invention also provides a program for executing a program update process of a terminal device using any one of the program update methods described above. Furthermore, a recording medium recording such a program is provided.

本発明は、また、プログラムを含んだ端末装置であって、プログラム及び当該プログラムの更新用データを記憶するメモリと、OSにより前記メモリを管理するメモリ管理手段と、プログラム更新用の差分データを取得する差分データ取得手段と、前記差分データを用いて前記プログラムの更新を行うプログラム更新手段と、前記メモリに格納された内容を保持したまま、OSによるメモリ管理が行われる第1の動作モードと、OSによるメモリ管理が行われない第2の動作モードとの間で動作モードを切り替える動作モード切り換え手段とを備え、前記差分データ取得手段により取得した差分データを、前記第1の動作モードにおいて、前記メモリに格納するとともに、前記差分データのメモリにおける配置に関する情報を取得してメモリに格納した後、前記第2の動作モードにおいて、前記メモリに格納された差分データの配置に関する情報に基づいて、前記差分データをメモリから取得し、その差分データを用いて前記プログラムの更新を行う端末装置を提供するものである。   The present invention is also a terminal device including a program, a memory that stores the program and update data for the program, a memory management unit that manages the memory by the OS, and obtains differential data for program update Differential data acquisition means, program update means for updating the program using the difference data, a first operation mode in which memory management is performed by the OS while retaining the contents stored in the memory, An operation mode switching unit that switches an operation mode between a second operation mode in which memory management by the OS is not performed, and the difference data acquired by the difference data acquisition unit in the first operation mode Storing in the memory and acquiring information about the arrangement of the difference data in the memory After the storage, in the second operation mode, the terminal acquires the difference data from the memory based on the information on the arrangement of the difference data stored in the memory, and updates the program using the difference data A device is provided.

本発明の端末装置において、前記メモリは、前記第1の動作モード及び前記第2の動作モードにおいて利用可能なファイルシステムとして構成されており、前記差分データは前記ファイルシステム上のファイルに格納され、前記差分データの配置情報は、前記差分データを格納したファイルを特定する情報であり、前記差分データ配置情報に基づき、前記差分データを格納したファイルを読み出すことにより前記差分データが取得されることを特徴とする。   In the terminal device of the present invention, the memory is configured as a file system that can be used in the first operation mode and the second operation mode, and the difference data is stored in a file on the file system, The arrangement information of the difference data is information for identifying a file storing the difference data. Based on the difference data arrangement information, the difference data is acquired by reading the file storing the difference data. Features.

本発明の端末装置において、前記メモリは、前記差分データがとり得る最大のサイズ以上のサイズのダミーファイルを格納しており、前記差分データ取得手段は、取得した差分データを前記ダミーファイルに上書きする処理を行うことを特徴とする。   In the terminal device according to the present invention, the memory stores a dummy file having a size equal to or larger than a maximum size that the difference data can take, and the difference data acquisition unit overwrites the acquired difference data on the dummy file. It is characterized by performing processing.

本発明の端末装置において、前記差分データは、前記メモリにおける1つ以上の物理アドレス空間上の領域に格納され、前記差分データ配置情報をメモリに格納する際に、前記領域の物理アドレス空間上の位置及びサイズと、前記差分データの格納順序に関する情報とを取得及び格納することを特徴とする。   In the terminal device of the present invention, the difference data is stored in one or more areas on the physical address space in the memory, and when the difference data arrangement information is stored in the memory, the difference data on the physical address space of the area is stored. The position and size, and information regarding the storage order of the difference data are acquired and stored.

本発明の端末装置は、前記差分データ格納する前に、前記メモリにおいて前記差分データを格納するのに必要となる物理アドレス空間上の領域の数を削減する領域削減手段をさらに含んでいることを特徴とする。   The terminal device of the present invention further includes area reduction means for reducing the number of areas in the physical address space necessary for storing the difference data in the memory before storing the difference data. Features.

本発明の端末装置において、前記領域削減手段は、プログラム更新処理に不要な作業を中止し、それに利用されていたメモリ領域を解放することを特徴とする。あるいは、OSの再起動を行うことを特徴とする。   In the terminal device according to the present invention, the area reduction means stops the work unnecessary for the program update process and releases the memory area used for it. Alternatively, the OS is restarted.

本発明の端末装置において、前記差分データ取得手段は、通信手段によりプログラム更新用の差分データを前記端末装置外部から取得することを特徴とする。   In the terminal device according to the present invention, the difference data acquisition unit acquires the difference data for program update from the outside of the terminal device by a communication unit.

本発明の端末装置において、前記メモリ管理手段は、MMUによる論理アドレス及び物理アドレス間のアドレス変換によりメモリ管理を実現することを特徴とする。   In the terminal device according to the present invention, the memory management means realizes memory management by address conversion between a logical address and a physical address by the MMU.

本発明は、また、上記したいずれかの端末装置を含んでいることを特徴とする携帯端末を提供するものである。   The present invention also provides a portable terminal including any one of the terminal devices described above.

以上、説明したように、本発明のプログラムを更新するための方法、プログラムおよび装置によれば、メモリ容量に制限があり、MMU対応のOSを搭載した端末装置に内蔵されているプログラムを、通信手段によって受信した差分データを用いて更新することが可能となる。   As described above, according to the method, program, and apparatus for updating the program of the present invention, the memory capacity is limited, and the program built in the terminal device equipped with the MMU-compatible OS is communicated. It becomes possible to update using the difference data received by the means.

以下、添付図面を参照しながら、本発明のプログラムを更新するための方法、プログラムおよび装置を実施するための最良の形態を詳細に説明する。図1〜図7は、本発明の実施の形態を例示する図であり、これらの図において、同一の符号を付した部分は同一物を表わし、基本的な構成および動作は同様であるものとする。   The best mode for carrying out a method, a program, and an apparatus for updating a program according to the present invention will be described below in detail with reference to the accompanying drawings. 1 to 7 are diagrams illustrating embodiments of the present invention. In these drawings, the same reference numerals denote the same components, and the basic configuration and operation are the same. To do.

端末装置のハードウェア構成
図1は、本実施形態において更新対象であるプログラムを含んだ端末装置のハードウェア構成を概略的に示すブロック図である。図1において、端末装置は、プログラム実行処理部11と、記憶部12と、無線通信部13と、アンテナ14とを有している。記憶部12は、RAM121と、プログラム用フラッシュROM122と、データ用フラッシュROM123とを含んでいる。プログラム実行処理部11は、プログラム用フラッシュROM122に内蔵されたプログラムを実行するCPUコア111と、実行されるプログラムに含まれる論理アドレスを記憶部12内のメモリの物理アドレスに変換する処理を行うMMU(メモリ管理ユニット)112とを含んでいる。
Hardware Configuration of Terminal Device FIG. 1 is a block diagram schematically showing a hardware configuration of a terminal device including a program to be updated in this embodiment. In FIG. 1, the terminal device includes a program execution processing unit 11, a storage unit 12, a wireless communication unit 13, and an antenna 14. The storage unit 12 includes a RAM 121, a program flash ROM 122, and a data flash ROM 123. The program execution processing unit 11 includes a CPU core 111 that executes a program built in the program flash ROM 122, and an MMU that performs processing for converting a logical address included in the program to be executed into a physical address of a memory in the storage unit 12. (Memory management unit) 112.

図1に示す端末装置は携帯型であり、生産コストの低減および消費電力の節減のために、メモリ容量は可能な限り小さく抑えられており、ハードディスクのような比較的電力消費の大きい大容量の2次記憶装置は搭載していないものとする。上述のフラッシュROMならば、書き換え可能な不揮発性メモリであって、ハードディスクよりも消費電力が小さい。また、本実施形態では、更新対象であるプログラムは、プログラム用フラッシュROM122に格納されており、このプログラムは、メモリの使用効率を高めるために、実行時にRAM121にコピーされることなく、CPUコア111によりプログラム用フラッシュROM122から直接読み出されて実行されるものとする。NOR型のフラッシュメモリは、アドレスを指定して直接読み出しアクセスできるから、このような利用形態が可能である。ただし、このことは本発明の本質とは関係がなく、本発明自体はNAND型のプログラム用フラッシュROM(実行するプログラムをいったんRAMにコピーする必要がある)にも適用できる。   The terminal device shown in FIG. 1 is portable, and the memory capacity is kept as small as possible in order to reduce production costs and power consumption. It is assumed that no secondary storage device is installed. The above-mentioned flash ROM is a rewritable nonvolatile memory and consumes less power than a hard disk. In the present embodiment, the program to be updated is stored in the program flash ROM 122, and this program is not copied to the RAM 121 at the time of execution in order to increase the memory usage efficiency. Thus, the program is read directly from the program flash ROM 122 and executed. Since the NOR type flash memory can be directly read and accessed by designating an address, such a utilization form is possible. However, this is not related to the essence of the present invention, and the present invention itself can be applied to a NAND-type program flash ROM (the program to be executed needs to be copied to the RAM once).

また、図1に示す端末装置は、RAM121の記憶内容を保持したままCPUコア111をリセットすることができるように構成されている。例えば、RAMがSRAMである場合には、特別な構成を必要とせずCPUコアのリセット後もRAMの記憶内容は保持されるし、RAMがDRAMである場合には、一旦SelfRefreshモード(近年のDRAMの多くはこのモードを備えている)に移行してからリセットすれば、RAMの記憶内容は保持される。また、フラッシュROMに対する指令に読み取りと書き込みの両方が混在していると、読み出しのみを行うときに比べて読み出し速度が落ちることが通常であるため、本実施形態の端末装置では、プログラム実行時の速度が落ちないように、プログラム用とデータ用のフラッシュROMをそれぞれ設けている。   Further, the terminal device shown in FIG. 1 is configured to be able to reset the CPU core 111 while retaining the stored contents of the RAM 121. For example, if the RAM is an SRAM, no special configuration is required, and the stored contents of the RAM are retained even after the CPU core is reset. If the RAM is a DRAM, the Self Refresh mode (in recent DRAMs) Many of them are equipped with this mode), and if reset is performed, the stored contents of the RAM are retained. In addition, when both reading and writing are mixed in the command to the flash ROM, the reading speed is usually lower than when only reading is performed. Program and data flash ROMs are provided to prevent the speed from dropping.

なお、図1に示す端末装置において、無線通信部13及びアンテナ14に替えて、ネットワークインタフェースカード等の有線の通信手段を備えていてもよい。   1 may be provided with wired communication means such as a network interface card in place of the wireless communication unit 13 and the antenna 14.

端末装置の機能的構成
図2は、図1に示す端末装置の処理内容にもとづいた機能的構成を示す機能ブロック図である。図2において、端末装置は、プログラム実行手段21と、記憶手段22と、差分データ受信手段23とを有している。プログラム実行手段21は、第1の動作モード(以下、「動作モード1」という)によるプログラム実行手段211と、第2の動作モード(以下、「動作モード2」という)によるプログラム実行手段212と、動作モード切り換え/再起動実行手段213と、アドレス変換手段214とを含んでいる。記憶手段22は、動作モード1によるプログラム実行手段211が実行する第1のプログラム221と、動作モード2によるプログラム実行手段212が実行する第2のプログラム222と、差分データ受信手段により受信した差分データ223と、動作モード1によるプログラム実行手段が生成する差分データ配置情報224とを格納している。
Functional Configuration of Terminal Device FIG. 2 is a functional block diagram showing a functional configuration based on the processing contents of the terminal device shown in FIG. In FIG. 2, the terminal device includes a program execution unit 21, a storage unit 22, and a difference data reception unit 23. The program execution means 21 includes a program execution means 211 in a first operation mode (hereinafter referred to as “operation mode 1”), a program execution means 212 in a second operation mode (hereinafter referred to as “operation mode 2”), An operation mode switching / restarting execution unit 213 and an address conversion unit 214 are included. The storage unit 22 includes a first program 221 executed by the program execution unit 211 according to the operation mode 1, a second program 222 executed by the program execution unit 212 according to the operation mode 2, and the difference data received by the difference data reception unit. 223 and difference data arrangement information 224 generated by the program execution means in the operation mode 1 are stored.

ここで、プログラム実行手段21は、プログラム実行処理部11に対応する機能であり、記憶手段22は記憶部12に対応する機能であり、差分データ受信手段は無線通信部13に対応する機能である。すなわち、記憶手段22に含まれている第1のプログラム221および第2のプログラム222は、記憶部12のプログラム用フラッシュROM122に格納されており、差分データ223および差分データ配置情報224は、RAM121またはデータ用フラッシュROM123に格納されている。   Here, the program execution unit 21 is a function corresponding to the program execution processing unit 11, the storage unit 22 is a function corresponding to the storage unit 12, and the difference data receiving unit is a function corresponding to the wireless communication unit 13. . That is, the first program 221 and the second program 222 included in the storage unit 22 are stored in the program flash ROM 122 of the storage unit 12, and the difference data 223 and the difference data arrangement information 224 are stored in the RAM 121 or It is stored in the data flash ROM 123.

なお、データ用フラッシュROM123に対するデータの読み書きは、通常、ファイルシステムを介して読み書きするものであるが、特定の目的ごとに使用する領域(予約領域)を決めて、ファイルシステムを介さずに読み書きを行うことも可能である。そこで本実施形態の端末装置では、データ用フラッシュROMの大部分はファイルシステム(以下、「フラッシュファイルシステム」という)を通じて読み書きを行い、少数の特定のデータについては予約領域に読み書きを行うものとする。   Data read / write from / to the data flash ROM 123 is normally performed via a file system. However, an area (reserved area) to be used for a specific purpose is determined and read / write is not performed via the file system. It is also possible to do this. Therefore, in the terminal device of this embodiment, most of the data flash ROM is read and written through a file system (hereinafter referred to as “flash file system”), and a small number of specific data is read and written in a reserved area. .

第1のプログラム221は、更新処理の対象となるプログラムであって、動作モード1によるプログラム実行手段211によって実行されるものである。第2のプログラム222は、第1のプログラム221を更新する処理を行うプログラムであって、動作モード2によるプログラム実行手段212によって実行されるものである。第2のプログラム222は更新することができないから、不具合が生ずる可能性を低くするために、更新処理に関する機能のみを有する簡易な構成としておくのが好ましい。このため、端末装置に内蔵されるプログラムコードの大部分は、第1のプログラム221に含むように構成している。後述するように、差分データ受信手段を用いた差分データの受信処理も第1のプログラムにより行う。   The first program 221 is a program to be updated, and is executed by the program execution unit 211 in the operation mode 1. The second program 222 is a program that performs processing for updating the first program 221 and is executed by the program execution means 212 in the operation mode 2. Since the second program 222 cannot be updated, it is preferable that the second program 222 has a simple configuration having only a function related to the update process in order to reduce the possibility of malfunction. For this reason, most of the program codes incorporated in the terminal device are configured to be included in the first program 221. As will be described later, differential data reception processing using differential data reception means is also performed by the first program.

また、第1のプログラム221は、MMU112を用いたメモリ保護を行うOS(オペレーティングシステム)のプログラムコードを含んでおり、動作モード1によるプログラム実行手段211は、アドレス変換手段214を用いたアドレス変換およびメモリ保護を行う。一方、第2のプログラム222は、このようなプログラムコードを含んでおらず、動作モード2によるプログラム実行手段212は、アドレス変換手段214の機能を用いることはない。   The first program 221 includes an OS (operating system) program code that performs memory protection using the MMU 112, and the program execution means 211 in the operation mode 1 performs address conversion using the address conversion means 214 and Perform memory protection. On the other hand, the second program 222 does not include such a program code, and the program execution unit 212 in the operation mode 2 does not use the function of the address conversion unit 214.

動作モード切替え/再起動実行手段213は、プログラムを実行する主体を、動作モード1によるプログラム実行手段と動作モード2によるプログラム実行手段との間で切替えるものである。本実施形態の端末装置では、次の動作モードを指定して切替えを行うと、指定された動作モードで動作するプログラムを始めから実行するようになっている。このため、次の動作モードとして現在と同じ動作モードを指定すれば、プログラムを再起動することになるので、動作モード切替え/再起動実行手段213によって、動作モード切替え機能とプログラム再起動機能とが提供されることになる。   The operation mode switching / restarting execution means 213 switches the subject executing the program between the program execution means according to the operation mode 1 and the program execution means according to the operation mode 2. In the terminal device according to the present embodiment, when switching is performed by designating the next operation mode, a program that operates in the designated operation mode is executed from the beginning. Therefore, if the same operation mode as the current operation mode is designated as the next operation mode, the program is restarted. Therefore, the operation mode switching function and the program restart function are performed by the operation mode switching / restart execution means 213. Will be provided.

アドレス変換手段214は、MMU112を用いて論理アドレスから物理アドレスへの変換を行うことにより、メモリ保護を行う。アドレス変換はページ単位で行われる。例えば、アドレスを32ビット、ページサイズを4Kとし、論理アドレスの上位20ビットが論理ページ番号を表し、物理アドレスの上位20ビットが物理ページ番号を表すとすると、アドレス変換手段は、ページテーブル(論理ページ番号と物理ページ番号の対応表であり、通常はRAMに保持されている)を用いて、論理アドレスの論理ページ番号を物理ページ番号に置換することで、論理アドレスを記憶部12における物理アドレスに変換することができる。   The address conversion unit 214 performs memory protection by performing conversion from a logical address to a physical address using the MMU 112. Address conversion is performed in units of pages. For example, assuming that the address is 32 bits, the page size is 4K, the upper 20 bits of the logical address represent the logical page number, and the upper 20 bits of the physical address represent the physical page number, the address conversion means performs the page table (logical Is a correspondence table of page numbers and physical page numbers, and is normally held in the RAM), by replacing the logical page number of the logical address with the physical page number, the logical address in the storage unit 12 Can be converted to

図3は、アドレス変換手段214によりアドレス変換を行う際の論理アドレス空間と物理アドレス空間との対応関係を例示する模式図である。アドレス変換手段214は、このようなアドレス変換を行う過程で、特定のページへのアクセス権限を禁止したり、読み出し専用にしたりすることで、メモリ保護を実現できる。例えば、プログラムが格納される論理アドレス空間上の領域を読み出し専用(書き込み禁止)に設定したり、第1のプログラムの一部であるアプリケーション1のプログラムから、同じく第1のプログラムの一部であるアプリケーション2のデータに対するアクセスは禁止されるように設定したりすることができる。なお、MMUにはこのようなメモリ保護機能のみを有するものもあるが、一般的にはアドレス変換機能と併用されることが多い。   FIG. 3 is a schematic diagram illustrating the correspondence between the logical address space and the physical address space when the address conversion unit 214 performs address conversion. The address conversion means 214 can realize memory protection by prohibiting the authority to access a specific page or making it read-only in the process of performing such address conversion. For example, an area on the logical address space in which the program is stored is set to read-only (write-inhibited), or from the application 1 program that is a part of the first program, it is also a part of the first program. Access to the data of the application 2 can be set to be prohibited. Some MMUs have only such a memory protection function, but generally they are often used together with an address translation function.

本実施形態の端末装置において、第1のプログラム221の実行を開始すると、初期段階のOS起動処理によりMMUによるアドレス変換が有効な状態となり、第1のプログラム221は論理アドレスを用いることになる。一方、第2のプログラム222は、アドレス変換手段によるアドレス変換機能を使わないので、第2のプログラム222が用いるアドレスは記憶部12における物理アドレスを用いることになる。   In the terminal device of this embodiment, when the execution of the first program 221 is started, the address translation by the MMU is enabled by the OS startup process in the initial stage, and the first program 221 uses a logical address. On the other hand, since the second program 222 does not use the address conversion function by the address conversion means, the physical address in the storage unit 12 is used as the address used by the second program 222.

端末装置によるプログラム更新処理
次に、図4〜図7のフローチャートを参照しながら、上記した本実施形態の端末装置においてプログラム更新処理を行う手順について説明する。以下では説明を具体的にするために、図1に示す端末装置のハードウェア構成において、RAM121のサイズを16Mバイト、プログラム用フラッシュROM122のサイズを32Mバイト、データ用フラッシュROM123のサイズを32Mバイトとしている。また、差分データのサイズの最大値を4Mバイトとしている。
Program Update Processing by Terminal Device Next, a procedure for performing the program update processing in the terminal device of the present embodiment described above will be described with reference to the flowcharts of FIGS. In the following, for the sake of specific explanation, in the hardware configuration of the terminal device shown in FIG. 1, the size of the RAM 121 is 16 Mbytes, the size of the program flash ROM 122 is 32 Mbytes, and the size of the data flash ROM 123 is 32 Mbytes. Yes. In addition, the maximum size of the difference data is 4 Mbytes.

図4は、動作モード1によるプログラム実行手段211が実行するプログラム更新処理の前半部分の流れを示すフローチャートである。動作モード1は端末装置が通常に動作している状態であって、アドレス変換手段によりMMU112を用いたアドレス変換/メモリ保護を行う機能が働いている。この状態で、プログラム更新処理が開始されると、図4のフローチャートの処理が開始される。   FIG. 4 is a flowchart showing the flow of the first half of the program update process executed by the program execution unit 211 in the operation mode 1. The operation mode 1 is a state in which the terminal device is operating normally, and the function of performing address translation / memory protection using the MMU 112 by the address translation means is working. When the program update process is started in this state, the process of the flowchart of FIG. 4 is started.

まず、差分データ受信ステップ(S41)が実行される。このステップでは、差分データ受信手段23が無線通信部13を用いて差分データを受信し、記憶手段22に格納する。ここでの格納先は、データ用フラッシュROM123のファイルシステム(フラッシュファイルシステム)上のファイルまたは予約領域とする(あるいはRAMの作業領域とすることも可能である)。次いで、差分データ配置情報取得ステップ(S42)が実行され、ステップS41で格納した差分データから差分データ配置情報が取得される。ここで、ステップS41において差分データをフラッシュファイルシステム上のファイルに格納した場合には、差分データ配置情報として、差分データが格納されたファイル名が取得されることになる。一方、ステップS41において差分データをフラッシュROMの予約領域(あるいはRAMの作業領域)に格納した場合には、差分データ配置情報として、当該予約領域の論理アドレスとその物理ページの並びに関する情報とが取得されることになる。この差分データ配置情報の内容については、後に詳しく説明する(※1)。   First, a difference data receiving step (S41) is executed. In this step, the difference data receiving unit 23 receives the difference data using the wireless communication unit 13 and stores it in the storage unit 22. The storage destination here is a file on the file system (flash file system) of the data flash ROM 123 or a reserved area (or can be a working area of the RAM). Next, a difference data arrangement information acquisition step (S42) is executed, and difference data arrangement information is acquired from the difference data stored in step S41. Here, when the difference data is stored in the file on the flash file system in step S41, the file name in which the difference data is stored is acquired as the difference data arrangement information. On the other hand, when the difference data is stored in the reserved area of the flash ROM (or the work area of the RAM) in step S41, the logical address of the reserved area and information related to the arrangement of the physical pages are acquired as the difference data arrangement information. Will be. The contents of the difference data arrangement information will be described in detail later (* 1).

取得された差分データ配置情報は、データ用フラッシュROM123の予約領域に格納する。次いで、動作モード切替えステップを行う(S43)。このステップでは、動作モード切り換え/再起動実行手段213により、動作モード1から動作モード2への切り換えを行う。実際の切り替え処理は、次の動作モードをデータ用フラッシュROM123の予約領域に格納してから、CPUコア111にリセットをかけることにより行う。このリセットは、ステップS41で格納した差分データと、S42で格納した差分データ配置情報を保持したままで行われる。この後、リセット処理ルーチンが、予約領域にある次の動作モードを読み出して、指定された動作モードで起動処理を行う。ここでは、ステップS43で次の動作モードとして指定した動作モード2が起動されるので、動作モード1から動作モード2への切り替えが起こることになる。以上で、動作モード1によるプログラム実行手段211が実行するプログラム更新処理の前半部分は終了する。   The acquired difference data arrangement information is stored in the reserved area of the data flash ROM 123. Next, an operation mode switching step is performed (S43). In this step, the operation mode switching / restart execution means 213 switches from the operation mode 1 to the operation mode 2. The actual switching process is performed by storing the next operation mode in the reserved area of the data flash ROM 123 and then resetting the CPU core 111. This reset is performed while holding the difference data stored in step S41 and the difference data arrangement information stored in S42. Thereafter, the reset processing routine reads the next operation mode in the reserved area and performs the start-up processing in the designated operation mode. Here, since operation mode 2 designated as the next operation mode in step S43 is activated, switching from operation mode 1 to operation mode 2 occurs. Thus, the first half of the program update process executed by the program execution unit 211 in the operation mode 1 is completed.

図5は、動作モード2によるプログラム実行手段212が実行するプログラム更新処理の後半部分の流れを示すフローチャートである。まず、差分データ復元ステップ(S51)が実行される。このステップでは、ステップS42で取得した差分データ配置情報を用いて、ステップS41で受信した差分データを復元する。続いて、復元された差分データと、第1のプログラムの所定部分である更新前データとから、その所定部分に対する更新後のデータを生成する更新後データ生成ステップ(S52)が実行される。さらに、当該更新後データを用いて第1のプログラムの該当部分を書き換える書換えステップ(S53)が実行される。その後、ステップS51において復元した差分データが残っているかどうかを判定し(S54)、残っている場合にはその残りの差分データについてステップS52からの処理を繰り返し、残っていない場合には動作モード2によるプログラム実行手段212が実行するプログラム更新処理の後半部分は終了する。   FIG. 5 is a flowchart showing the flow of the latter half of the program update process executed by the program execution means 212 in the operation mode 2. First, a differential data restoration step (S51) is executed. In this step, the difference data received in step S41 is restored using the difference data arrangement information acquired in step S42. Subsequently, an updated data generation step (S52) for generating updated data for the predetermined part from the restored difference data and the pre-update data which is the predetermined part of the first program is executed. Further, a rewriting step (S53) is executed in which the corresponding part of the first program is rewritten using the updated data. Thereafter, it is determined whether or not the differential data restored in step S51 remains (S54). If the differential data remains, the processing from step S52 is repeated for the remaining differential data. The second half of the program update process executed by the program execution means 212 is completed.

ステップS54において、復元した差分データが残っている場合とは、プログラム更新用差分データの送信側において、更新前と更新後の第1のプログラムを複数の分割された領域ごとに比較し、更新されている領域のみの差分データを抽出して端末装置に送信しているため、端末装置において複数の領域に対する差分データが取得されている場合である。このような場合には、それら全ての差分データが使われるまで、各領域について更新後データ生成ステップ(S52)および書換えステップ(S53)が繰り返し実行されるようになっている。   In step S54, when the restored differential data remains, on the transmission side of the program update differential data, the updated first program is compared and updated for each of the plurality of divided areas. This is a case where the difference data for a plurality of areas is acquired in the terminal device because the difference data of only the area is extracted and transmitted to the terminal device. In such a case, the updated data generation step (S52) and the rewrite step (S53) are repeatedly executed for each area until all the difference data is used.

以上にてプログラム更新処理は全て終了する。ところで図4において、差分データ受信ステップを、動作モード1で実行する第1のプログラムに含めているのは、動作モード2で実行する第2のプログラムの機能を小さい範囲に留めるためであるほか、第1のプログラムに含めることによって、OSがサポートするHTTPやHTTPS(SSL)などの高度かつ広く行き渡った通信機能を使えるという利点も考慮したためである。実際、これらの高度な通信機能を第2のプログラムの小さいプログラム容量の中で表現することは困難である。   The program update process is all completed. By the way, in FIG. 4, the difference data receiving step is included in the first program executed in the operation mode 1 in order to keep the function of the second program executed in the operation mode 2 within a small range. This is because by including it in the first program, the advantage that advanced and widely used communication functions such as HTTP and HTTPS (SSL) supported by the OS can be used. In fact, it is difficult to express these advanced communication functions in the small program capacity of the second program.

図6は、図5の差分データ復元ステップ(S51)における処理の詳細を示すフローチャートである。上記したように、差分データ配置情報はその格納先によって内容が異なっているので、差分データを復元する際には、まず、差分データ配置情報がファイル名であるかどうかを判定する(S61)。差分データ配置情報がファイル名である場合には、フラッシュROMのファイルシステム(フラッシュファイルシステム)上の当該ファイルを読み出して差分データを得ることができる(S62)。差分データ配置情報がファイル名ではなく、フラッシュROMの予約領域の論理アドレスとその物理ページの並びである場合には、その並びに従って当該物理ページから差分データを読み出すことで、元の差分データを復元することができる(S63)。   FIG. 6 is a flowchart showing details of the processing in the differential data restoration step (S51) of FIG. As described above, since the contents of the difference data arrangement information differ depending on the storage destination, when restoring the difference data, it is first determined whether or not the difference data arrangement information is a file name (S61). If the difference data arrangement information is a file name, the file on the flash ROM file system (flash file system) can be read to obtain difference data (S62). If the difference data placement information is not the file name but the logical address of the reserved area in the flash ROM and the physical page sequence, the original differential data is restored by reading the differential data from the physical page according to the sequence. (S63).

なお、ステップS63において、フラッシュROMの予約領域から差分データを読み出すと、差分データと同じサイズの追加の作業領域が必要となってしまう。これを避けるために、フラッシュROMの予約領域において、差分データ配置情報に従って差分データ情報をページ単位で並べ替える処理を行うことにより、元の差分データを復元してもよい。例えば、差分データ配置情報をメモリ上に読み出して(4Kバイト)、それをキーとしてページをソートすると、必要となる追加の作業領域を減少させることができる。   In step S63, when the difference data is read from the reserved area of the flash ROM, an additional work area having the same size as the difference data is required. In order to avoid this, the original difference data may be restored by performing a process of rearranging the difference data information in units of pages in the reserved area of the flash ROM according to the difference data arrangement information. For example, if the difference data arrangement information is read out to the memory (4 Kbytes) and the pages are sorted using it as a key, the required additional work area can be reduced.

以上、図4〜図6を用いて、本実施形態の端末装置におけるプログラム更新処理の基本的な手順を示したが、メモリ容量に制限がある端末装置では、図4のステップS41において差分データを受信した際に、そのデータを一時的に格納するための領域をRAM上あるいはフラッシュファイルシステム上に確保できない可能性がある。上記した本実施形態のプログラム更新処理では、端末装置は全ての差分データを受信して記憶手段に格納した後に、動作モード1から動作モード2に切り換えることとしているので、少なくとも差分データの最大サイズ(上記では4Mバイト)に相当する領域をRAM上あるいはフラッシュファイルシステム上に確保する必要がある。   As described above, the basic procedure of the program update process in the terminal device according to the present embodiment has been described with reference to FIGS. 4 to 6. In the terminal device having a limited memory capacity, the difference data is stored in step S41 in FIG. When received, there is a possibility that an area for temporarily storing the data cannot be secured on the RAM or the flash file system. In the program update process of the present embodiment described above, since the terminal device receives all the difference data and stores it in the storage means and then switches from the operation mode 1 to the operation mode 2, at least the maximum size of the difference data ( In the above, it is necessary to secure an area corresponding to 4 Mbytes) on the RAM or the flash file system.

この対応策として、差分データを全てフラッシュファイルシステムのファイルに格納する場合には、例えば、事前に4Mバイトのダミーファイルをフラッシュファイルシステムに作成しておき、受信した差分データをそのファイルに上書きすればよい。あるいは、ダミーファイルを作成せずとも、プログラム更新処理を行う前に、消去しても差し支えがないファイルを消去して空き領域を作るようにしてもよい。後者の方法は、そのようなファイル(重要度の低いファイルや、後でバックアップから復旧できるファイルなど)が所定サイズ以上存在することが事前に分かっている場合に有効である。事前に分かっていない場合には、ユーザーインタフェースを通じてユーザに不要なファイルを消去するよう促して、必要な空き領域を作るようにしてもよい。   As a countermeasure, when all the difference data is stored in a file of the flash file system, for example, a dummy file of 4 Mbytes is created in the flash file system in advance, and the received difference data is overwritten on the file. That's fine. Alternatively, even if a dummy file is not created, a file that can be erased may be erased to create a free area before the program update process is performed. The latter method is effective when it is known in advance that such a file (such as a low-importance file or a file that can be recovered from backup later) has a predetermined size or more. If it is not known in advance, the user may be prompted to delete unnecessary files through the user interface to create a necessary free area.

あるいは、差分データを格納するための作業領域をRAM上に確保するために、他の用途で用いられている作業領域を解放させて、差分データの格納に転用することもできる。このような解放処理を行うために、プログラム更新処理以外のプロセスを個別に停止させ、それらが使用していた作業領域を解放させてもよい。また、動作モード1が動作しているOSを一旦再起動した後に、プログラム更新処理を継続するようにしてもよい。例えば、ステップS43と同様の処理を、次の動作モードを動作モード1に設定して行うようにすればよい。   Alternatively, in order to secure a work area for storing difference data on the RAM, a work area used for other purposes can be released and used for storing difference data. In order to perform such release processing, processes other than the program update processing may be individually stopped, and the work areas used by them may be released. Alternatively, the program update process may be continued after the OS operating in the operation mode 1 is once restarted. For example, the same processing as step S43 may be performed by setting the next operation mode to operation mode 1.

図7は、差分データを格納するための作業領域をRAM上に確保できない場合に、差分データ受信ステップ(図4のS41)により行われる作業領域のための処理の流れを示すフローチャートである。まず、動作モード1で動作する第1のプログラムは、受信した差分データをフラッシュファイルシステム上のファイルに格納する(S71)。上述したように、あらかじめフラッシュファイルシステム上に差分データの最大サイズと同じサイズのダミーファイルを作成しておけば、この処理を確実に実行することができる。なお、MMU対応OSの起動処理では、通常、RAMの初期化を行うので、S71ではRAM上に差分データを格納することはできない。続いて、RAM上の作業領域を確保するために、第1のプログラムが動作しているOSを再起動する(S72)。OS再起動後、受信した差分データを格納するための作業領域をRAM上に確保し(S73)、その作業領域に、フラッシュファイルシステム上のファイルに格納してある差分データを読み出す(S74)。以上の処理により、差分データ受信ステップ(図4のS41)が正常に実行されたことになる。   FIG. 7 is a flowchart showing a flow of processing for the work area performed in the difference data receiving step (S41 in FIG. 4) when the work area for storing the difference data cannot be secured on the RAM. First, the first program operating in the operation mode 1 stores the received difference data in a file on the flash file system (S71). As described above, if a dummy file having the same size as the maximum size of the difference data is created in advance on the flash file system, this process can be executed reliably. Note that in the MMU-compatible OS startup process, the RAM is usually initialized, so that the difference data cannot be stored on the RAM in S71. Subsequently, in order to secure a work area on the RAM, the OS on which the first program is running is restarted (S72). After the OS is restarted, a work area for storing the received difference data is secured on the RAM (S73), and the difference data stored in the file on the flash file system is read into the work area (S74). With the above processing, the difference data receiving step (S41 in FIG. 4) is normally executed.

図7に示す処理では、ステップS73においてRAM上に必要な作業領域が確保できなければ、プログラム更新処理は実行できないことになる。しかしながら、実際には再起動直後に確保可能な作業領域は、プログラムのバージョンに応じて再現性があるから、差分データの最大サイズが確保できるかどうかを事前の調査によって知ることが可能である。また、ステップS72で再起動した後に動作するOSは、ステップS71の実行時のものと同じOSでよいが、再起動後にOS上で動作させるプログラムは、ステップS71の実行時とは違って、ステップS73以降の処理に必要な最小限度のものにとどめることができる。具体的には、ステップS73以降においてもファイル読み出し機能は必要であるが、ステップS71で用いた差分データの受信機能は必要ではない。このように、OS再起動後のステップS73では、ステップS71の実行時よりも大きな作業領域を確保できるものと期待することができる。   In the process shown in FIG. 7, the program update process cannot be executed unless a necessary work area can be secured on the RAM in step S73. However, since the work area that can be secured immediately after the restart has reproducibility according to the version of the program, it is possible to know whether or not the maximum size of the difference data can be secured by a preliminary investigation. Further, the OS that operates after restarting in step S72 may be the same OS as that at the time of execution of step S71. However, the program that runs on the OS after the restart is different from that at the time of execution of step S71. It can be kept to the minimum necessary for the processing after S73. Specifically, the file reading function is necessary even after step S73, but the difference data receiving function used in step S71 is not necessary. Thus, in step S73 after the OS is restarted, it can be expected that a larger work area can be ensured than in the execution of step S71.

また、OSの再起動直後は、上記のとおりRAMの初期化が行われてから間もないため、RAM上の作業領域を確保する直前までに、RAM上に初期化以来一度も使われていない物理ページが残っているときは、作業領域の中には連続した物理ページが多く含まれることが期待できる。一般的に、物理ページが連続していると、実効的な差分データ配置情報のサイズを小さくすることが可能である。これは、連続している領域の数が少ないほど、差分データ配置情報のサイズは小さくなり、作業領域全体が連続する物理ページで構成される1つの領域だけで構成されるとき、差分データ配置情報のサイズは最小となるためである。実際の差分データ配置情報のサイズは、プログラムのバージョンに応じて再現性があるから、差分データ配置情報のサイズは事前の調査によって知ることが可能であり、予約領域のサイズを小さくすることができる。   In addition, immediately after the OS is restarted, it is shortly after the initialization of the RAM as described above, so it has not been used on the RAM since the initialization until immediately before the work area on the RAM is secured. When physical pages remain, it can be expected that many continuous physical pages are included in the work area. Generally, when physical pages are continuous, the size of effective differential data arrangement information can be reduced. This is because the smaller the number of continuous areas, the smaller the size of the difference data arrangement information. When the entire work area is composed of only one area composed of continuous physical pages, the difference data arrangement information This is because the size of is minimized. Since the actual size of the difference data arrangement information is reproducible according to the version of the program, the size of the difference data arrangement information can be known by prior investigation, and the size of the reserved area can be reduced. .

起動直後でなければ、OSによって物理ページの割当と解放が繰り返されているから、作業領域の中に連続した物理ページが多く割り当てられるかどうかは、空きページの管理アルゴリズムに依存するが、一般に多く割り当てられることは期待できない。OSによっては、DMA処理用のバッファを確保するために、物理ページが連続した作業領域を確保するAPIを提供することもあり、OSを改変してそのようなAPIを作成してもよい。ただし、再起動した場合の差分データ配置情報のサイズを事前に知ることができるから、同様の効果が期待できるのであれば、再起動の方が簡便である。   If it is not immediately after startup, physical page allocation and release are repeated by the OS, so whether or not a large number of continuous physical pages are allocated in the work area depends on the management algorithm of free pages, but in general there are many You cannot expect to be assigned. Depending on the OS, an API for securing a work area in which physical pages are continuous may be provided to secure a buffer for DMA processing, and such an API may be created by modifying the OS. However, since the size of the difference data arrangement information when restarting can be known in advance, restarting is easier if the same effect can be expected.

なお、ステップS71〜S74の処理では、差分データの受信後に再起動を行っているが、差分データの受信前に再起動を行って、データの受信前にRAM上に作業領域を確保してから、差分データの受信と格納を行ってもよい。作業領域を確保した状態で差分データ受信処理を行ってもRAMの空き容量が不足しないと判定できる場合には、この処理手順によれば受信したデータを一旦ファイルに格納する必要がなくなる。   In the processing of steps S71 to S74, the restart is performed after the difference data is received. However, after the restart is performed before the difference data is received and the work area is secured on the RAM before the data is received. The difference data may be received and stored. If it can be determined that there is no shortage of RAM even if differential data reception processing is performed with a work area secured, this processing procedure eliminates the need to temporarily store the received data in a file.

※1
本実施形態の端末装置では、上記したように動作モード2の機能を簡易な構成としているため、フラッシュファイルシステムが使用できないこともある。この場合、図4のステップS41では差分データをフラッシュROMの予約領域(あるいはRAM上の作業領域)に格納することになる。動作モード1では、MMUを用いたアドレス変換/メモリ保護を行うOSが動作しているから、ステップS41で差分データを格納した予約領域は論理アドレスで指示されている。ところが、動作モード2では、アドレスは物理アドレスで指定しなければならない。このため、図5のステップS51において差分データを復元できるように、ステップS41において差分データが格納された予約領域の論理アドレスとともにその物理ページの並びに関する情報を差分データ配置情報として記録しておくことが必要となる。
* 1
In the terminal device of the present embodiment, the function of the operation mode 2 has a simple configuration as described above, and thus the flash file system may not be used. In this case, in step S41 of FIG. 4, the difference data is stored in the reserved area of the flash ROM (or the work area on the RAM). In operation mode 1, since the OS that performs address conversion / memory protection using the MMU is operating, the reserved area in which the difference data is stored in step S41 is designated by a logical address. However, in the operation mode 2, the address must be specified by a physical address. Therefore, in order to be able to restore the difference data in step S51 of FIG. 5, information regarding the physical page arrangement is recorded as difference data arrangement information together with the logical address of the reserved area in which the difference data is stored in step S41. Is required.

例えばこのような情報は、最大で4Mバイト/4Kバイト=1024個の物理ページ番号を、差分データの格納順にデータ用フラッシュ上の予約領域に格納することで表現できる。物理ページ番号を、各ページの先頭番地の物理アドレス(32ビット)で表現すると、4Kバイトのサイズの予約領域がデータ用フラッシュ上に必要となるが、格納されている物理ページが連続している箇所がある場合は、ランレングス法にもとづく適当な符号化を施すことで、実効的な差分データ配置情報のサイズを小さくすることが可能である。具体的には、連続する物理ページで構成される領域を、「(連続する物理ページのうちの)先頭ページの先頭番地の物理アドレス」と「連続する個数」という2つの値の組で表す。さらに、前者を20ビット、後者を12ビットとして、32ビット長に符号化すれば、差分データ配置情報の格納に必要な予約領域のサイズは、符号化を施す前のサイズを超えることはない。   For example, such information can be expressed by storing a maximum of 4 Mbytes / 4 Kbytes = 1024 physical page numbers in the reserved area on the data flash in the order of storing the difference data. If the physical page number is expressed by the physical address (32 bits) at the top address of each page, a reserved area of 4 Kbytes is required on the data flash, but the stored physical pages are continuous. If there are places, it is possible to reduce the size of the effective differential data arrangement information by performing appropriate encoding based on the run length method. Specifically, an area composed of continuous physical pages is represented by a set of two values: “the physical address of the first address of the first page (of consecutive physical pages)” and “the number of consecutive”. Furthermore, if the former is 20 bits and the latter is 12 bits, and the encoding is performed to a 32-bit length, the size of the reserved area necessary for storing the differential data arrangement information does not exceed the size before encoding.

上記符号化の形式は、物理アドレス空間上の1つ以上の領域に格納された差分データの、各領域の位置(先頭の物理アドレス)と大きさ(連続するページ数)を表したもので、それを順番に格納することで領域の順序を表している。   The encoding format represents the position (starting physical address) and size (number of consecutive pages) of each area of differential data stored in one or more areas on the physical address space. The order of the areas is expressed by storing them in order.

なお、所定の論理ページ番号に対応する物理アドレスを取得するためには、対象となるOS内部の状態にアクセスする必要がある。OSがそのような情報を取得するためのAPIを提供していることもあるし、OSを改変したり、デバイスドライバを作成したりして、ページテーブル経由で取得できることもある。   Note that in order to acquire a physical address corresponding to a predetermined logical page number, it is necessary to access the state inside the target OS. The OS may provide an API for acquiring such information, or may be acquired via a page table by modifying the OS or creating a device driver.

以上、本発明のプログラムを更新するための方法、プログラムおよび装置について、具体的な実施の形態を示して説明したが、本発明はこれらに限定されるものではない。当業者であれば、本発明の要旨を逸脱しない範囲内において、上記各実施形態又は他の実施形態にかかる発明の構成および機能に様々な変更・改良を加えることが可能である。   As mentioned above, although the specific embodiment was shown and demonstrated about the method, program, and apparatus for updating the program of this invention, this invention is not limited to these. A person skilled in the art can make various changes and improvements to the configurations and functions of the invention according to the above-described embodiments or other embodiments without departing from the gist of the present invention.

本発明のプログラムを更新するための方法およびプログラムは、データ受信手段、記憶手段、データ書き換え手段等を備えた携帯型の端末装置などにおいて実現され得るものであり、内蔵プログラムの更新という情報処理が上記のデータ受信手段、記憶手段、データ書き換え手段等を用いて具体的に実現されるものであるから、産業上利用することができる発明である。   The method and program for updating the program of the present invention can be realized in a portable terminal device provided with data receiving means, storage means, data rewriting means, etc. Since it is specifically realized by using the above data receiving means, storage means, data rewriting means, etc., it is an invention that can be utilized industrially.

本発明のプログラムを更新するための方法、プログラムおよび装置において、更新の対象であるプログラムを含んだ端末装置のハードウェア構成を概略的に示すブロック図である。In the method, program, and apparatus for updating the program of this invention, it is a block diagram which shows roughly the hardware constitutions of the terminal device containing the program which is the object of an update. 図1に示す端末装置が行う処理の内容にもとづいた機能的構成を示す機能ブロック図である。It is a functional block diagram which shows the functional structure based on the content of the process which the terminal device shown in FIG. 1 performs. 図1に示す端末装置のアドレス変換手段によりアドレス変換を行う際の論理アドレス空間と物理アドレス空間との対応関係を例示する模式図である。It is a schematic diagram which illustrates the correspondence of the logical address space and physical address space at the time of performing address translation by the address translation means of the terminal device shown in FIG. 動作モード1によるプログラム実行手段が実行するプログラム更新処理の前半部分の流れを示すフローチャートである。It is a flowchart which shows the flow of the first half part of the program update process which the program execution means by the operation mode 1 performs. 動作モード2によるプログラム実行手段が実行するプログラム更新処理の後半部分の流れを示すフローチャートである。It is a flowchart which shows the flow of the second half part of the program update process which the program execution means by the operation mode 2 performs. 図5の差分データ復元ステップ(S51)における処理の詳細を示すフローチャートである。It is a flowchart which shows the detail of the process in the difference data restoration step (S51) of FIG. 差分データを格納するための作業領域をRAM上に確保できない場合に、差分データ受信ステップ(図4のS41)により行われる作業領域のための処理の流れを示すフローチャートである。5 is a flowchart showing a flow of processing for a work area performed in a differential data reception step (S41 in FIG. 4) when a work area for storing difference data cannot be secured on a RAM.

符号の説明Explanation of symbols

11 プログラム実行処理部
111 CPUコア
12 記憶部
121 RAM
122 プログラム用フラッシュROM
123 データ用フラッシュROM
13 無線通信部
14 アンテナ
21 プログラム実行手段
211 第1の動作モードによるプログラム実行手段
212 第2の動作モードによるプログラム実行手段
213 動作モード切り替え/再起動実行手段
214 アドレス変換手段
22 記憶手段
221 第1のプログラム
222 第2のプログラム
223 差分データ
224 差分データ配置情報
23 差分データ受信手段
11 Program execution processing unit 111 CPU core 12 Storage unit 121 RAM
122 Flash ROM for program
123 Flash ROM for data
13 wireless communication unit 14 antenna 21 program execution means 211 program execution means 212 in the first operation mode program execution means 213 in the second operation mode 213 operation mode switching / restart execution means 214 address conversion means 22 storage means 221 first Program 222 Second program 223 Difference data 224 Difference data arrangement information 23 Difference data receiving means

Claims (20)

プログラム更新用の差分データを用いて端末装置のプログラムを更新する方法であって、
前記差分データを取得する差分データ取得ステップと、
OSによるメモリ管理が行われる第1の動作モードにおいて、前記差分データをメモリに格納する差分データ格納ステップと、
前記差分データのメモリにおける配置に関する情報を取得し、メモリに格納する差分データ配置情報格納ステップと、
前記メモリに格納された内容を保持したまま、前記第1の動作モードから、OSによるメモリ管理が行われない第2の動作モードに切り替えを行う切り換えを行う動作モード切り換えステップと、
前記第2の動作モードにおいて、前記メモリに格納された差分データ配置情報に基づいて、前記差分データをメモリから取得する差分データ復元ステップと、
前記差分データを用いて、前記プログラムの更新を行うプログラム更新ステップと、
を含む方法。
A method of updating a program of a terminal device using difference data for program update,
A difference data acquisition step for acquiring the difference data;
In a first operation mode in which memory management is performed by the OS, a difference data storage step for storing the difference data in a memory;
A step of storing difference data arrangement information for acquiring information on arrangement of the difference data in a memory and storing the information in the memory;
An operation mode switching step for performing switching for switching from the first operation mode to the second operation mode in which memory management by the OS is not performed while retaining the contents stored in the memory;
In the second operation mode, based on the difference data arrangement information stored in the memory, the difference data restoring step for acquiring the difference data from the memory;
A program update step for updating the program using the difference data;
Including methods.
前記メモリは、前記第1の動作モード及び前記第2の動作モードにおいて利用可能なファイルシステムとして構成されており、
前記差分データ格納ステップにおいて、前記ファイルシステム上のファイルに差分データを格納し、
前記差分データ配置情報格納ステップにおいて、前記差分データの配置情報として、前記差分データを格納したファイルを特定する情報を取得及び格納し、
前記差分データ復元ステップにおいて、前記差分データ配置情報に基づき、前記差分データを格納したファイルを読み出すことにより前記差分データを取得することを特徴とする請求項1に記載のプログラム更新方法。
The memory is configured as a file system that can be used in the first operation mode and the second operation mode,
In the difference data storage step, the difference data is stored in a file on the file system;
In the difference data arrangement information storage step, as the arrangement information of the difference data, obtain and store information specifying a file storing the difference data;
2. The program update method according to claim 1, wherein, in the differential data restoration step, the differential data is acquired by reading a file storing the differential data based on the differential data arrangement information.
前記メモリは、前記差分データがとり得る最大のサイズ以上のサイズのダミーファイルを格納しており、
前記差分データ取得ステップにおいて、取得した差分データを前記ダミーファイルに上書きする処理を行うことを特徴とする請求項2に記載のプログラム更新方法。
The memory stores a dummy file having a size greater than or equal to the maximum size that the difference data can take,
The program update method according to claim 2, wherein in the difference data acquisition step, a process of overwriting the acquired difference data on the dummy file is performed.
前記差分データ格納ステップにおいて、前記差分データを前記メモリにおける1つ以上の物理アドレス空間上の領域に格納し、
前記差分データ配置情報格納ステップにおいて、前記領域の物理アドレス空間上の位置及びサイズと、前記差分データの格納順序に関する情報とを取得及び格納することを特徴とする請求項1に記載のプログラム更新方法。
In the differential data storage step, the differential data is stored in an area on one or more physical address spaces in the memory;
2. The program update method according to claim 1, wherein, in the difference data arrangement information storage step, the position and size of the area in the physical address space and information regarding the storage order of the difference data are acquired and stored. .
前記差分データ格納ステップを実行する前に、前記メモリにおいて前記差分データを格納するのに必要となる物理アドレス空間上の領域の数を削減するステップをさらに含んでいることを特徴とする請求項4に記載のプログラム更新方法。   5. The method according to claim 4, further comprising the step of reducing the number of areas in the physical address space required for storing the differential data in the memory before executing the differential data storing step. The program update method described in 1. 前記差分データ格納ステップを実行する前に、プログラム更新処理に不要な作業を中止し、それに利用されていたメモリ領域を解放するステップを含んでいることを特徴とする請求項4又は5に記載のプログラム更新方法。   6. The method according to claim 4, further comprising a step of canceling a work unnecessary for the program update process and releasing a memory area used for the work before executing the differential data storage step. Program update method. 前記差分データ格納ステップを実行する前に、OSの再起動を行うステップを含んでいることを特徴とする請求項4又は5に記載のプログラム更新方法。   6. The program update method according to claim 4, further comprising a step of restarting the OS before executing the differential data storage step. 前記差分データ取得ステップにおいて、通信手段によりプログラム更新用の差分データを前記端末装置外部から取得することを特徴とする請求項1から7のいずれか1項に記載のプログラム更新方法。   8. The program update method according to claim 1, wherein, in the differential data acquisition step, differential data for program update is acquired from the outside of the terminal device by communication means. 9. 前記OSによるメモリ管理は、MMUによる論理アドレス及び物理アドレス間のアドレス変換により実現されることを特徴とする請求項1から8のいずれか1項に記載のプログラム更新方法。   9. The program update method according to claim 1, wherein the memory management by the OS is realized by address conversion between a logical address and a physical address by the MMU. 請求項1から9のいずれか1項に記載の方法を用いて、端末装置のプログラム更新処理を実行するプログラム。   The program which performs the program update process of a terminal device using the method of any one of Claim 1 to 9. プログラムを含んだ端末装置であって、
プログラム及び当該プログラムの更新用データを記憶するメモリと、
OSにより前記メモリを管理するメモリ管理手段と、
プログラム更新用の差分データを取得する差分データ取得手段と、
前記差分データを用いて前記プログラムの更新を行うプログラム更新手段と、
前記メモリに格納された内容を保持したまま、OSによるメモリ管理が行われる第1の動作モードと、OSによるメモリ管理が行われない第2の動作モードとの間で動作モードを切り替える動作モード切り換え手段とを備え、
前記差分データ取得手段により取得した差分データを、前記第1の動作モードにおいて、前記メモリに格納するとともに、前記差分データのメモリにおける配置に関する情報を取得してメモリに格納した後、
前記第2の動作モードにおいて、前記メモリに格納された差分データの配置に関する情報に基づいて、前記差分データをメモリから取得し、その差分データを用いて前記プログラムの更新を行う端末装置。
A terminal device including a program,
A memory for storing a program and data for updating the program;
Memory management means for managing the memory by an OS;
Differential data acquisition means for acquiring differential data for program update;
Program update means for updating the program using the difference data;
Operation mode switching for switching the operation mode between a first operation mode in which memory management by the OS is performed and a second operation mode in which memory management by the OS is not performed while retaining the contents stored in the memory Means and
In the first operation mode, the difference data acquired by the difference data acquisition unit is stored in the memory, and information regarding the arrangement of the difference data in the memory is acquired and stored in the memory.
In the second operation mode, a terminal device that acquires the difference data from the memory based on information relating to the arrangement of the difference data stored in the memory, and updates the program using the difference data.
前記メモリは、前記第1の動作モード及び前記第2の動作モードにおいて利用可能なファイルシステムとして構成されており、
前記差分データは前記ファイルシステム上のファイルに格納され、
前記差分データの配置情報は、前記差分データを格納したファイルを特定する情報であり、
前記差分データ配置情報に基づき、前記差分データを格納したファイルを読み出すことにより前記差分データが取得されることを特徴とする請求項11に記載の端末装置。
The memory is configured as a file system that can be used in the first operation mode and the second operation mode,
The difference data is stored in a file on the file system,
The difference data arrangement information is information for specifying a file storing the difference data,
The terminal device according to claim 11, wherein the difference data is acquired by reading a file storing the difference data based on the difference data arrangement information.
前記メモリは、前記差分データがとり得る最大のサイズ以上のサイズのダミーファイルを格納しており、
前記差分データ取得手段は、取得した差分データを前記ダミーファイルに上書きする処理を行うことを特徴とする請求項12に記載の端末装置。
The memory stores a dummy file having a size greater than or equal to the maximum size that the difference data can take,
The terminal device according to claim 12, wherein the difference data acquisition unit performs a process of overwriting the acquired difference data on the dummy file.
前記差分データは、前記メモリにおける1つ以上の物理アドレス空間上の領域に格納され、
前記差分データ配置情報をメモリに格納する際に、前記領域の物理アドレス空間上の位置及びサイズと、前記差分データの格納順序に関する情報とを取得及び格納することを特徴とする請求項11に記載の端末装置。
The difference data is stored in an area on one or more physical address spaces in the memory,
12. The location and size of the area in a physical address space and information regarding the storage order of the difference data are acquired and stored when the difference data arrangement information is stored in a memory. Terminal equipment.
前記差分データ格納する前に、前記メモリにおいて前記差分データを格納するのに必要となる物理アドレス空間上の領域の数を削減する領域削減手段をさらに含んでいることを特徴とする請求項14に記載の端末装置。   15. The method according to claim 14, further comprising area reduction means for reducing the number of areas on a physical address space necessary for storing the difference data in the memory before storing the difference data. The terminal device described. 前記領域削減手段は、プログラム更新処理に不要な作業を中止し、それに利用されていたメモリ領域を解放することを特徴とする請求項15に記載の端末装置。   The terminal device according to claim 15, wherein the area reduction unit stops a work unnecessary for the program update process and releases a memory area used for the work. 前記領域削減手段は、OSの再起動を行うことを特徴とする請求項15に記載の端末装置。   The terminal device according to claim 15, wherein the area reduction unit restarts the OS. 前記差分データ取得手段は、通信手段によりプログラム更新用の差分データを前記端末装置外部から取得することを特徴とする請求項11から17のいずれか1項に記載の端末装置。   The terminal device according to any one of claims 11 to 17, wherein the difference data acquisition unit acquires the difference data for program update from the outside of the terminal device by a communication unit. 前記メモリ管理手段は、MMUによる論理アドレス及び物理アドレス間のアドレス変換によりメモリ管理を実現することを特徴とする請求項11から18のいずれか1項に記載の端末装置。   The terminal device according to claim 11, wherein the memory management unit realizes memory management by address conversion between a logical address and a physical address by an MMU. 請求項11から19のいずれか1項に記載の端末装置を含んでいることを特徴とする携帯端末。   A portable terminal comprising the terminal device according to any one of claims 11 to 19.
JP2004319596A 2004-11-02 2004-11-02 Method for updating program, program and device Pending JP2006133889A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004319596A JP2006133889A (en) 2004-11-02 2004-11-02 Method for updating program, program and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004319596A JP2006133889A (en) 2004-11-02 2004-11-02 Method for updating program, program and device

Publications (1)

Publication Number Publication Date
JP2006133889A true JP2006133889A (en) 2006-05-25

Family

ID=36727416

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004319596A Pending JP2006133889A (en) 2004-11-02 2004-11-02 Method for updating program, program and device

Country Status (1)

Country Link
JP (1) JP2006133889A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008090723A (en) * 2006-10-04 2008-04-17 Kyocera Corp Portable terminal
WO2009078285A1 (en) * 2007-12-14 2009-06-25 Sharp Kabushiki Kaisha Radio terminal, radio terminal nonvolatile memory, and diagnosis information fail-safe storage method
KR101471108B1 (en) 2011-09-25 2014-12-09 어드밴스드 마이크로 디바이시즈, 인코포레이티드 Input/output memory management unit with protection mode for preventing memory access by i/o devices
WO2015098811A1 (en) * 2013-12-27 2015-07-02 京セラドキュメントソリューションズ株式会社 Electronic device
CN111684416A (en) * 2018-02-16 2020-09-18 日立汽车系统株式会社 Vehicle control device and program update system

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008090723A (en) * 2006-10-04 2008-04-17 Kyocera Corp Portable terminal
WO2009078285A1 (en) * 2007-12-14 2009-06-25 Sharp Kabushiki Kaisha Radio terminal, radio terminal nonvolatile memory, and diagnosis information fail-safe storage method
JPWO2009078285A1 (en) * 2007-12-14 2011-04-28 シャープ株式会社 Wireless terminal, non-volatile memory of wireless terminal, and fail-safe storage method of diagnostic information
US8161474B2 (en) 2007-12-14 2012-04-17 Sharp Laboratories Of America, Inc. Diagnostic information preservation during installations of over the air update of wireless handset software
KR101471108B1 (en) 2011-09-25 2014-12-09 어드밴스드 마이크로 디바이시즈, 인코포레이티드 Input/output memory management unit with protection mode for preventing memory access by i/o devices
WO2015098811A1 (en) * 2013-12-27 2015-07-02 京セラドキュメントソリューションズ株式会社 Electronic device
CN105814545A (en) * 2013-12-27 2016-07-27 京瓷办公信息系统株式会社 Electronic device
JP6074064B2 (en) * 2013-12-27 2017-02-01 京セラドキュメントソリューションズ株式会社 Electronics
CN105814545B (en) * 2013-12-27 2019-08-27 京瓷办公信息系统株式会社 Electronic equipment
CN111684416A (en) * 2018-02-16 2020-09-18 日立汽车系统株式会社 Vehicle control device and program update system
CN111684416B (en) * 2018-02-16 2023-09-29 日立安斯泰莫株式会社 Vehicle control device and program update system

Similar Documents

Publication Publication Date Title
KR101636870B1 (en) Method and apparatus for generating minimal boot image
CN108027753B (en) In-vehicle control device, program update system, and storage medium storing program update software
US20150186224A1 (en) Data storage device and flash memory control method
US8775758B2 (en) Memory device and method for performing a write-abort-safe firmware update
JP3942612B2 (en) Storage device, memory management method, and program
US7971014B2 (en) Information processing apparatus and data recovering method
JPWO2006107095A1 (en) Computer system, memory management method, and program thereof
JP2008033788A (en) Nonvolatile storage device, data storage system, and data storage method
JP2006350430A (en) Memory controller, flash memory system and control method for flash memory
JP2001175466A (en) Method and device for generating execution program, and method for executing execution program and computer-readable program storage medium
JP4586469B2 (en) MEMORY CONTROL DEVICE, MEMORY CONTROL METHOD, PROGRAM
JP5057887B2 (en) Data update device, data update method, and data update program
KR100456736B1 (en) Method for reducing booting time of a digital device having a flash memory
JP2006133889A (en) Method for updating program, program and device
KR100698655B1 (en) System for updating a file on a mobile phone, and Boot management system for preventing the fatal error by loss of a file header in the EFS area, and Method for updating a file on a mobile phone, and Booting method for preventing the fatal error by loss of a file header in the EFS area
JP2005352535A (en) Method of protecting data
JP2004078902A (en) Storage device, memory management method, and program thereof
JP3826115B2 (en) Storage device, memory management method, and program
JP2013045285A (en) Information processor, image forming device, and program
JP6080492B2 (en) Information processing apparatus, activation method, and program
JP2008140236A (en) Memory management system, information processor and memory management method
JP2013033338A (en) Memory system
JP6782654B2 (en) In-vehicle control device and program update software
JP2007133602A (en) Information processing system and onboard equipment
KR20070008997A (en) Portable terminal and its method of data protection control and data emergency recovery function