JP2013129066A - Recording apparatus, control method of recording apparatus, and program - Google Patents

Recording apparatus, control method of recording apparatus, and program Download PDF

Info

Publication number
JP2013129066A
JP2013129066A JP2011278289A JP2011278289A JP2013129066A JP 2013129066 A JP2013129066 A JP 2013129066A JP 2011278289 A JP2011278289 A JP 2011278289A JP 2011278289 A JP2011278289 A JP 2011278289A JP 2013129066 A JP2013129066 A JP 2013129066A
Authority
JP
Japan
Prior art keywords
execution command
initial
data
initial execution
command
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
JP2011278289A
Other languages
Japanese (ja)
Inventor
Shunichi Wakasa
俊一 若狭
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.)
Seiko Epson Corp
Original Assignee
Seiko Epson 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 Seiko Epson Corp filed Critical Seiko Epson Corp
Priority to JP2011278289A priority Critical patent/JP2013129066A/en
Publication of JP2013129066A publication Critical patent/JP2013129066A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

PROBLEM TO BE SOLVED: To enable easy addition of initial processing to be executed after application of power or reset, without updating a firmware.SOLUTION: A printer 12 includes: an initial processing execution part 30a for sequentially executing an initial execution command described on initial execution command data 43 on the basis of the data after the application of power or the reset; and a command addition part 30b for accessing to a nonvolatile memory 35 when an addition instruction command that instructs an addition of a predetermined initial execution command to the initial execution command data 43 is input from a host computer 10, and for adding the predetermined initial execution command to the initial execution command data 43.

Description

本発明は、制御装置に接続可能な記録装置、当該記録装置の制御方法、及び、当該記録装置を制御するためのプログラムに関する。   The present invention relates to a recording apparatus connectable to a control apparatus, a control method for the recording apparatus, and a program for controlling the recording apparatus.

従来、電源が投入された場合、初期処理を行うよう構成された記録装置が知られている(例えば、特許文献1参照)。一般に、初期処理は、ファームウェアの機能により実行される。   2. Description of the Related Art Conventionally, a recording apparatus configured to perform initial processing when power is turned on is known (see, for example, Patent Document 1). In general, the initial process is executed by a firmware function.

特開2010−19262号公報JP 2010-19262 A

ここで、上述した記録装置では、電源投入後、又は、リセット後に行う初期処理に、新たに所定の初期処理を追加したいという場合が生じ得る。この場合、従来は、ファームウェアを書き換える必要があった。しかしながら、ファームウェアは、記録装置の基本動作を制御するためのプログラムであり、比較的複雑なプログラミングがされており、また、書き換えが正常に行われなかった場合、記録装置の以後の動作に多大な悪影響を与えることがある。このため、通常、ファームウェアの書き換えは、できるだけ行わない方が望ましい。これに応えるべく、記録装置が備える不揮発性メモリーに、実行すべき初期処理の一覧を示す情報を記憶し、当該一覧を示す情報を編集することにより、初期処理の追加を行えるようにすることが考えられる。しかし、この場合、不揮発性メモリーの性質(書き換え方法等)を考慮して、ユーザーができるだけ容易に初期処理の追加を行えるようにする必要がある。
本発明は、上述した事情に鑑みてなされたものであり、ファームウェアの書き換えを伴うことなく、容易に、電源の投入後、又は、リセット後に実行すべき初期処理の追加を行えるようにすることを目的とする。
Here, in the above-described recording apparatus, there may be a case where it is desired to newly add a predetermined initial process to the initial process performed after power-on or reset. In this case, conventionally, it was necessary to rewrite the firmware. However, the firmware is a program for controlling the basic operation of the recording apparatus, is relatively complicated programming, and if the rewriting is not performed normally, the firmware has a great deal of subsequent operations. May cause adverse effects. For this reason, it is usually preferable not to rewrite the firmware as much as possible. In order to respond to this, it is possible to store information indicating a list of initial processes to be executed in a nonvolatile memory included in the recording apparatus and edit the information indicating the list so that the initial process can be added. Conceivable. However, in this case, it is necessary to allow the user to add initial processing as easily as possible in consideration of the nature of the nonvolatile memory (rewriting method and the like).
The present invention has been made in view of the above-described circumstances, and it is possible to easily add an initial process to be executed after power-on or reset without rewriting firmware. Objective.

上記目的を達成するために、本発明は、制御装置に接続可能な記録装置であって、電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータが記憶された不揮発性メモリーと、電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する初期処理実行部と、前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記するコマンド追記部と、を備えることを特徴とする。
この構成によれば、記録装置は、電源の投入後、又は、リセット後に実行すべき1又は複数の初期処理に係る初期実行コマンドが記述された初期実行コマンドデータを、不揮発性メモリーに記憶しておき、電源の投入後、又は、リセット後、当該初期実行コマンドデータに基づいて、実行すべき初期処理を順次実行していく構成であるため、ファームウェアの書き換えを伴うことなく、初期実行コマンドデータの編集により、実行すべき初期処理の追加が可能となる。特に、制御装置から記録装置に対して、追記指示コマンドを出力すれば、記録装置が、自動で、不揮発性メモリーにアクセスして、追加すべき初期実行コマンドを初期実行コマンドデータに追加する構成であるため、実行すべき初期処理を追加する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリーに直接アクセスし、当該不揮発性メモリーの所定の記憶領域に記憶されている初期実行コマンドデータを、手順に沿って編集する、といった煩雑な作業を行うことなく、制御装置の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
In order to achieve the above object, the present invention is a recording device that can be connected to a control device, and has one or more initial execution commands for executing an initial process to be executed after power-on or reset. The initial execution command is sequentially executed based on the non-volatile memory storing the described initial execution command data and the initial execution command data stored in the non-volatile memory after the power is turned on or reset. An initial process execution unit that performs the process, and an additional write instruction command that instructs to add a predetermined initial execution command to the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the initial execution command data And a command appending unit for appending the predetermined initial execution command.
According to this configuration, the recording apparatus stores, in the nonvolatile memory, initial execution command data in which an initial execution command related to one or more initial processes to be executed after power-on or reset is stored. In addition, after the power is turned on or reset, the initial execution command data is sequentially executed based on the initial execution command data. By editing, it is possible to add an initial process to be executed. In particular, when the appending command is output from the control device to the recording device, the recording device automatically accesses the nonvolatile memory and adds the initial execution command to be added to the initial execution command data. Therefore, when adding an initial process to be executed, the user directly accesses the nonvolatile memory using a dedicated software tool, and the initial execution command data stored in a predetermined storage area of the nonvolatile memory. It is only necessary to output a postscript instruction command by the function of the control device without performing a complicated operation such as editing according to the procedure, and the operation is very easy.

また、本発明は、前記初期実行コマンドデータは、前記不揮発性メモリーの所定の記憶領域に、各初期実行コマンドを示すデータが実行順に連続して書き込まれたデータ部と、当該記憶領域における前記データ部のサイズを示す情報を含む情報部と、を含んで構成され、前記コマンド追記部は、前記制御装置から追記指示コマンドが入力された場合、前記データ部の末尾アドレスから追記すべき所定の初期実行コマンドを示すデータを書き込むと共に、前記情報部における前記データ部のサイズを示す情報を、当該書き込み後の前記データ部のサイズを示す情報に書き換えることを特徴とする。
ここで、初期実行コマンドデータを、関係データベースとし、これにより、初期実行コマンドデータに記述された各初期実行コマンドの管理を容易化することも考えられるが、この場合、関係データベースの管理情報(例えば、記憶領域における各フィールドのアドレスと、各フィールドに格納されたデータとを対応付ける情報)を記憶する必要があり、また、不必要に記憶領域を確保する事態が生じ得るため、不揮発性メモリーの効率的な利用に課題がある。
これを踏まえ、上記構成によれば、初期実行コマンドデータにおけるデータ部では、各初期コマンドを示すデータが実行順に連続して書き込まれているため、当該データ部が占める憶領域が必要最小限で済むと共に、各コマンドを実行する順番を管理するための情報を記憶する必要がない。また、初期実行コマンドデータにおける情報部は、データ部のサイズを示す情報という、記憶領域においてデータ部が記憶されている領域を特定するために必要な最小限の情報を保持している。このため、この情報部のサイズ自体が小さく、不揮発性メモリーの効率的な利用を実現できる。
According to the present invention, the initial execution command data includes a data part in which data indicating each initial execution command is sequentially written in a predetermined storage area of the nonvolatile memory in the execution order, and the data in the storage area. An information part including information indicating the size of the part, and the command appending part, when an appending instruction command is input from the control device, is a predetermined initial to be appended from the end address of the data part The data indicating the execution command is written, and the information indicating the size of the data portion in the information portion is rewritten to information indicating the size of the data portion after the writing.
Here, it is considered that the initial execution command data is a relational database, thereby facilitating the management of each initial execution command described in the initial execution command data. In this case, it is necessary to store the address of each field in the storage area and the data stored in each field), and the storage area may be unnecessarily reserved. There is a problem in effective use.
Based on this, according to the above configuration, in the data portion in the initial execution command data, the data indicating each initial command is written successively in the execution order, so that the storage area occupied by the data portion can be minimized. At the same time, there is no need to store information for managing the order in which the commands are executed. In addition, the information part in the initial execution command data holds minimum information necessary for specifying an area where the data part is stored in the storage area, which is information indicating the size of the data part. For this reason, the size of the information section itself is small, and the efficient use of the nonvolatile memory can be realized.

また、本発明は、前記不揮発性メモリーには、フォントデータが格納されたコードページが記憶され、このコードページは、仕向地に応じて、その初期設定が異なっており、追記指示コマンドには、特定の仕向地に応じた前記コードページの初期設定を行うための初期実行コマンドの追記を指示するものがあることを特徴とする。
この構成によれば、追記指示コマンドを利用して、仕向地に応じて、コードページの初期設定を容易に変更可能である。
Further, according to the present invention, the nonvolatile memory stores a code page in which font data is stored, and the initial setting of the code page differs depending on the destination. There is an instruction to additionally write an initial execution command for performing the initial setting of the code page according to a specific destination.
According to this configuration, the initial setting of the code page can be easily changed according to the destination by using the additional write instruction command.

また、本発明は、前記制御装置から、前記初期実行コマンドデータに記述されている所定の初期実行コマンドの削除を指示する削除指示コマンドが入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータから当該所定の初期実行コマンドを削除するコマンド削除部と、を備えることを特徴とする。
この構成によれば、初期実行コマンドデータから所定の初期実行コマンドを削除する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリーに直接アクセスし、当該不揮発性メモリーの所定の記憶領域に記憶されている初期実行コマンドデータを、手順に沿って編集する、といった煩雑な作業を行うことなく、制御装置の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
In the present invention, when a deletion instruction command for instructing deletion of a predetermined initial execution command described in the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the initial A command deletion unit that deletes the predetermined initial execution command from the execution command data.
According to this configuration, when deleting a predetermined initial execution command from the initial execution command data, the user directly accesses the non-volatile memory using a dedicated software tool and accesses a predetermined storage area of the non-volatile memory. The additional execution instruction command may be output by the function of the control device without performing a complicated operation such as editing the stored initial execution command data according to the procedure, and the operation is very easy.

また、上記目的を達成するために、本発明は、制御装置に接続可能な記録装置の制御方法であって、電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータを不揮発性メモリーに記憶し、電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する一方、前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記することを特徴とする。
この制御方法によれば、記録装置は、電源の投入後、又は、リセット後に実行すべき1又は複数の初期処理に係る初期実行コマンドが記述された初期実行コマンドデータを、不揮発性メモリーに記憶しておき、電源の投入後、又は、リセット後、当該初期実行コマンドデータに基づいて、実行すべき初期処理を順次実行していく構成であるため、ファームウェアの書き換えを伴うことなく、初期実行コマンドデータの編集により、実行すべき初期処理の追加が可能となる。特に、制御装置から記録装置に対して、追記指示コマンドを出力すれば、記録装置が、自動で、不揮発性メモリーにアクセスして、追加すべき初期実行コマンドを初期実行コマンドデータに追加する構成であるため、実行すべき初期処理を追加する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリーに直接アクセスし、当該不揮発性メモリーの所定の記憶領域に記憶されている初期実行コマンドデータを、手順に沿って編集する、といった煩雑な作業を行うことなく、制御装置の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
In order to achieve the above object, the present invention provides a control method for a recording apparatus that can be connected to a control apparatus, and performs an initial execution for executing an initial process to be executed after power-on or reset The initial execution command data in which one or more commands are described is stored in the nonvolatile memory, and the initial execution is performed based on the initial execution command data stored in the nonvolatile memory after power-on or reset. While the command is sequentially executed, when a write instruction command for instructing addition of a predetermined initial execution command to the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the initial execution command data The above-mentioned predetermined initial execution command is additionally written to.
According to this control method, the recording apparatus stores, in the nonvolatile memory, initial execution command data in which an initial execution command related to one or more initial processes to be executed after power-on or reset is described. In addition, after the power is turned on or after the reset, the initial execution command data is executed without rewriting the firmware because the initial processing to be executed is sequentially executed based on the initial execution command data. This makes it possible to add initial processing to be executed. In particular, when the appending command is output from the control device to the recording device, the recording device automatically accesses the nonvolatile memory and adds the initial execution command to be added to the initial execution command data. Therefore, when adding an initial process to be executed, the user directly accesses the nonvolatile memory using a dedicated software tool, and the initial execution command data stored in a predetermined storage area of the nonvolatile memory. It is only necessary to output a postscript instruction command by the function of the control device without performing a complicated operation such as editing according to the procedure, and the operation is very easy.

また、上記目的を達成するために、本発明は、制御装置に接続可能に構成され、電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータが記憶された不揮発性メモリーを備える記録装置を制御する制御部により実行されるプログラムであって、前記制御部を、電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する初期処理実行部と、前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記するコマンド追記部と、として機能させることを特徴とする。
このプログラムを実行すれば、記録装置は、電源の投入後、又は、リセット後に実行すべき1又は複数の初期処理に係る初期実行コマンドが記述された初期実行コマンドデータを、不揮発性メモリーに記憶しておき、電源の投入後、又は、リセット後、当該初期実行コマンドデータに基づいて、実行すべき初期処理を順次実行していく構成であるため、ファームウェアの書き換えを伴うことなく、初期実行コマンドデータの編集により、実行すべき初期処理の追加が可能となる。特に、制御装置から記録装置に対して、追記指示コマンドを出力すれば、記録装置が、自動で、不揮発性メモリーにアクセスして、追加すべき初期実行コマンドを初期実行コマンドデータに追加する構成であるため、実行すべき初期処理を追加する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリーに直接アクセスし、当該不揮発性メモリーの所定の記憶領域に記憶されている初期実行コマンドデータを、手順に沿って編集する、といった煩雑な作業を行うことなく、制御装置の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
In order to achieve the above object, the present invention is configured to be connectable to a control device, and describes one or a plurality of initial execution commands for executing an initial process to be executed after power-on or reset. A program that is executed by a control unit that controls a recording device that includes a nonvolatile memory in which the initial execution command data is stored, and that the control unit is turned on after power is turned on or after the nonvolatile memory is reset. An initial process execution unit that sequentially executes the initial execution command based on the initial execution command data stored in the memory, and an additional instruction command that instructs to add a predetermined initial execution command to the initial execution command data. When input from a device, the nonvolatile memory is accessed, and the predetermined initial execution command is added to the initial execution command data. Wherein the function as a command appending section for appending a.
When this program is executed, the recording device stores in the nonvolatile memory initial execution command data in which an initial execution command related to one or more initial processes to be executed after power-on or reset is described. In addition, after the power is turned on or after the reset, the initial execution command data is executed without rewriting the firmware because the initial processing to be executed is sequentially executed based on the initial execution command data. This makes it possible to add initial processing to be executed. In particular, when the appending command is output from the control device to the recording device, the recording device automatically accesses the nonvolatile memory and adds the initial execution command to be added to the initial execution command data. Therefore, when adding an initial process to be executed, the user directly accesses the nonvolatile memory using a dedicated software tool, and the initial execution command data stored in a predetermined storage area of the nonvolatile memory. It is only necessary to output a postscript instruction command by the function of the control device without performing a complicated operation such as editing according to the procedure, and the operation is very easy.

本発明によれば、ファームウェアの書き換えを伴うことなく、容易に、電源の投入後、又は、リセット後に実行すべき初期処理の追加を行える。   According to the present invention, it is possible to easily add an initial process to be executed after turning on the power or after resetting without rewriting the firmware.

本実施形態に係る記録システムの機能的構成を示すブロック図である。It is a block diagram which shows the functional structure of the recording system which concerns on this embodiment. コードテーブルを示す図である。It is a figure which shows a code table. 初期実行コマンドデータを示す図である。It is a figure which shows initial execution command data. 初期処理実行部の動作を示すフローチャートである。It is a flowchart which shows operation | movement of an initial process execution part. コマンド追記部の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a command addition part. コマンド削除部の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a command deletion part.

以下、図面を参照して本発明の実施形態について説明する。
図1は、本実施形態に係る記録システム1の機能的構成を示すブロック図である。
記録システム1は、スーパーマーケットやコンビニエンスストア等の店舗に適用され、店舗に来店した顧客の代金の支払いに応じてレシートを発行するシステムであり、図1に示すように、ホストコンピューター10(制御装置)と、POSサーバー11と、プリンター12(記録装置)とを備えている。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing a functional configuration of a recording system 1 according to the present embodiment.
The recording system 1 is a system that is applied to a store such as a supermarket or a convenience store, and issues a receipt in response to payment for a customer who has visited the store. As shown in FIG. 1, a host computer 10 (control device) And a POS server 11 and a printer 12 (recording device).

POSサーバー11は、ネットワークを介してホストコンピューター10に通信可能に接続されており、店舗で販売している商品の商品コードや、名称、金額等のレシートの発行のために必要となる情報を示すデータをデータベースとして記憶する。ホストコンピューター10は、レシートの発行に際し、適宜、POSサーバー11に記憶されたデータベースを参照し、必要な情報を取得する。   The POS server 11 is communicably connected to the host computer 10 via a network, and indicates information necessary for issuing a receipt such as a product code, name, and price of a product sold at a store. Store data as a database. When the receipt is issued, the host computer 10 refers to the database stored in the POS server 11 as appropriate, and acquires necessary information.

ホストコンピューター10は、ホスト側制御部15と、ホスト側表示部16と、ホスト側入力部17と、インターフェイス部18(I/F)と、ホスト側記憶部19と、を備える。
ホスト側制御部15は、ホストコンピューター10の各部を中枢的に制御するものであり、演算実行部としてのCPUや、このCPUに実行される基本制御プログラムや、この基本制御プログラムに係るデータ等を不揮発的に記憶するROM、CPUに実行されるプログラムやこのプログラムに係るデータ等を一時的に記憶するRAM、その他の周辺回路等を備える。
図1に示すように、ホスト側制御部15は、POSアプリケーション実行部20と、プリンタードライバー実行部21と、を備えているが、これらについては後述する。
The host computer 10 includes a host-side control unit 15, a host-side display unit 16, a host-side input unit 17, an interface unit 18 (I / F), and a host-side storage unit 19.
The host-side control unit 15 centrally controls each unit of the host computer 10 and stores a CPU as a calculation execution unit, a basic control program executed by the CPU, data related to the basic control program, and the like. A ROM that stores data in a nonvolatile manner, a program that is executed by the CPU, a RAM that temporarily stores data related to the program, and other peripheral circuits are provided.
As shown in FIG. 1, the host side control unit 15 includes a POS application execution unit 20 and a printer driver execution unit 21, which will be described later.

ホスト側表示部16は、液晶ディスプレーパネルや、有機ELパネル等の表示パネルを備え、ホスト側制御部15の制御の下、表示パネルに各種情報を表示する。
ホスト側入力部17は、キーボードや、マウス、バーコードリーダー、カードリーダー等の入力デバイスに接続され、これら入力デバイスの出力信号をホスト側制御部15に出力する。バーコードリーダーは商品の包装紙等に記録されたバーコードの読み取りに利用され、カードリーダーはクレジットカードや、会員カード等に記録された情報の読み取りに利用される。バーコードリーダーやカードリーダー等の入力デバイスを用いて取得した情報は、レシートの発行に係る処理に用いられる。
インターフェイス部18(I/F)は、ホスト側制御部15の制御の下、プリンター12との間で通信規格に準拠した通信を行う。
ホスト側記憶部19は、各種データを書き換え可能に記憶する部位であり、ハードディスクや、EEPROM等の記憶装置を備える。
The host side display unit 16 includes a display panel such as a liquid crystal display panel or an organic EL panel, and displays various information on the display panel under the control of the host side control unit 15.
The host side input unit 17 is connected to input devices such as a keyboard, a mouse, a barcode reader, and a card reader, and outputs output signals from these input devices to the host side control unit 15. The bar code reader is used for reading a bar code recorded on a product wrapping paper or the like, and the card reader is used for reading information recorded on a credit card, a member card or the like. Information acquired using an input device such as a barcode reader or a card reader is used for processing relating to receipt issuance.
The interface unit 18 (I / F) performs communication based on the communication standard with the printer 12 under the control of the host-side control unit 15.
The host-side storage unit 19 is a part that stores various data in a rewritable manner, and includes a storage device such as a hard disk or an EEPROM.

一方、プリンター12は、ロール状に巻かれた感熱ロール紙を、ローラー状のプラテンにより搬送し、この感熱ロール紙の記録面に、発熱素子を備えたラインサーマルヘッドによって熱を与えることにより画像を記録した上で、所定の位置で感熱ロール紙を切断することにより、レシートを発行するサーマルヘッド式プリンターである。
図1に示すように、プリンター12は、制御部30と、表示部31と、入力部32と、プリントエンジン33と、不揮発性メモリー35と、インターフェイス部36(I/F)と、を備える。
制御部30は、プリンター12の各部を中枢的に制御するものであり、演算実行部としてのCPUや、このCPUに実行されるファームウェア41や、このファームウェア41に係るデータ等を不揮発的に記憶するROM、CPUに実行されるプログラムやこのプログラムに係るデータ等を一時的に記憶するRAM、その他の周辺回路等を備える。
この制御部30は、初期処理実行部30a、コマンド追記部30b、及び、コマンド削除部30cを備えているが、これら機能ブロックについては後述する。
表示部31は、プリンター12の動作状態等の各種情報を表示する液晶パネルや有機ELパネル等の表示パネルや、LED等を備え、制御部30の制御の下、当該表示パネルに各種情報を表示し、又は、LEDの点灯/消灯する。
入力部32は、プリンター12に設けられた各種操作スイッチに接続され、操作スイッチに対する操作を検出し操作信号として制御部30に出力する。
プリントエンジン33は、制御部30の制御の下、各種センサーの検出値を監視しながら、上述したラインサーマルヘッドのほか、感熱ロール紙を搬送するプラテンローラーを駆動するための搬送モーターや、切断機構が備えるカッターを駆動するためのカッター駆動モーターを動作させて、感熱ロール紙に画像を記録し、画像を記録した感熱ロール紙を切断することによりレシートを発行する。
インターフェイス部36(I/F)は、制御部30の制御の下、ホストコンピューター10との間で通信規格に準拠した通信を行う。
不揮発性メモリー35は、EEPROM等のメモリーを備え、各種データを書き換え可能に記憶する。不揮発性メモリー35には、プリンター12の動作を制御するためのファームウェア41が記憶されるほか、コードページ40と、初期実行コマンドデータ43と、が記憶される。
On the other hand, the printer 12 conveys the roll of heat-sensitive roll paper by a roller-shaped platen, and heats the recording surface of the heat-sensitive roll paper by a line thermal head equipped with a heating element to form an image. It is a thermal head type printer that issues a receipt by cutting the thermal roll paper at a predetermined position after recording.
As shown in FIG. 1, the printer 12 includes a control unit 30, a display unit 31, an input unit 32, a print engine 33, a nonvolatile memory 35, and an interface unit 36 (I / F).
The control unit 30 centrally controls each unit of the printer 12, and stores a CPU as an operation execution unit, firmware 41 executed by the CPU, data related to the firmware 41, and the like in a nonvolatile manner. A ROM, a program executed by the CPU, a RAM that temporarily stores data related to the program, and other peripheral circuits are provided.
The control unit 30 includes an initial process execution unit 30a, a command addition unit 30b, and a command deletion unit 30c. These functional blocks will be described later.
The display unit 31 includes a display panel such as a liquid crystal panel or an organic EL panel that displays various information such as the operation state of the printer 12, and an LED, and displays various information on the display panel under the control of the control unit 30. Or, the LED is turned on / off.
The input unit 32 is connected to various operation switches provided in the printer 12, detects an operation on the operation switch, and outputs it to the control unit 30 as an operation signal.
The print engine 33 monitors the detection values of various sensors under the control of the control unit 30 and, in addition to the above-described line thermal head, a transport motor for driving a platen roller for transporting the thermal roll paper, and a cutting mechanism. A cutter driving motor for driving the cutter included in the printer is operated to record an image on the thermal roll paper, and a receipt is issued by cutting the thermal roll paper on which the image is recorded.
The interface unit 36 (I / F) performs communication based on the communication standard with the host computer 10 under the control of the control unit 30.
The nonvolatile memory 35 includes a memory such as an EEPROM and stores various data in a rewritable manner. The nonvolatile memory 35 stores firmware 41 for controlling the operation of the printer 12, and also stores a code page 40 and initial execution command data 43.

図2は、コードページ40の内容を模式的に示す図である。
コードページ40とは、プリンター12によって記録可能な文字のそれぞれのフォントデータを集合して記憶するテーブルのことである。フォントデータとは、文字を記録媒体に記録可能な態様で表現する実データ(ビットマップフォントデータや、スケイラブルフォントデータ等)のことである。
図2に示すように、コードページ40は、その記憶領域が分割されることによって、複数の格納領域kが形成されており、1つの格納領域kに、1つのフォントデータが格納可能である。
格納領域kのそれぞれには、各領域の先頭アドレスに応じて、各領域を一意に示す番地が割り振られており、1つの番地を特定することにより、1つの格納領域kが特定される。
本実施形態では、図2に示すように、コードページ40に形成された格納領域kのうち、番地XXの格納領域k1には、通貨記号を示すフォントデータが格納される。この格納領域k1に格納されるデータについては、後述する。
FIG. 2 is a diagram schematically showing the contents of the code page 40.
The code page 40 is a table that collects and stores font data of characters that can be recorded by the printer 12. The font data is actual data (bitmap font data, scalable font data, etc.) that expresses characters in a form that can be recorded on a recording medium.
As shown in FIG. 2, the code page 40 is divided into storage areas, thereby forming a plurality of storage areas k. One font data can be stored in one storage area k.
Each of the storage areas k is assigned an address uniquely indicating each area according to the head address of each area. By specifying one address, one storage area k is specified.
In the present embodiment, as shown in FIG. 2, among the storage areas k formed in the code page 40, font data indicating a currency symbol is stored in the storage area k1 of the address XX. Data stored in the storage area k1 will be described later.

次いで、POSアプリケーション実行部20及びプリンタードライバー実行部21の説明を通して、記録システム1がレシートを発行する際の基本的な動作について説明する。
POSアプリケーション実行部20は、ホストコンピューター10に予めインストールされたPOSアプリケーションを実行することにより、取引毎に、適宜、POSサーバー11にアクセスした上で、取引において購入された商品を示す情報や、商品の単価を示す情報、購入金額を示す情報等のレシートに記載すべき情報を取得する。そして、POSアプリケーション実行部20は、取得した情報に基づいて、レシートに記録すべき画像に係る記録データを生成し、プリンタードライバー実行部21に出力する。レシートに記録すべき画像には、商品の名称を示す文字に係る画像や、値段を示す文字に係る画像等の文字に係る画像が含まれている。POSアプリケーション実行部20が生成する記録データにおいては、これら文字は、アスキーコードやUnicode等の所定の文字コードとして表現されている。
プリンタードライバー実行部21は、ホストコンピューター10に予めインストールされたプリンタードライバーを実行することにより、POSアプリケーション実行部20から入力された記録データに基づいて、プリンター12のコマンド仕様に対応した記録コマンドを生成し、制御部30に出力する。この記録コマンドには、搬送機構に感熱ロール紙を搬送させるコマンドや、ラインサーマルヘッドを駆動させるコマンド、切断機構に感熱ロール紙を切断させるコマンド等の、プリンター12にレシートを発行させるための各種コマンドが含まれている。
記録コマンドが入力された制御部30は、この記録コマンドに基づいてプリンター12の各部を制御し、レシートを発行する。
Next, basic operations when the recording system 1 issues a receipt will be described through the description of the POS application execution unit 20 and the printer driver execution unit 21.
The POS application execution unit 20 executes the POS application installed in the host computer 10 in advance to access the POS server 11 as appropriate for each transaction, and then displays information indicating the product purchased in the transaction, Information to be described in the receipt, such as information indicating the unit price of the product and information indicating the purchase price. Then, based on the acquired information, the POS application execution unit 20 generates recording data relating to the image to be recorded on the receipt, and outputs it to the printer driver execution unit 21. The image to be recorded on the receipt includes an image related to characters such as an image related to a character indicating the name of a product and an image related to a character indicating a price. In the recording data generated by the POS application execution unit 20, these characters are expressed as a predetermined character code such as an ASCII code or Unicode.
The printer driver execution unit 21 generates a recording command corresponding to the command specification of the printer 12 based on the recording data input from the POS application execution unit 20 by executing a printer driver installed in the host computer 10 in advance. And output to the control unit 30. The recording command includes various commands for causing the printer 12 to issue a receipt, such as a command for causing the conveyance mechanism to convey the thermal roll paper, a command for driving the line thermal head, and a command for causing the cutting mechanism to cut the thermal roll paper. It is included.
The control unit 30 to which the recording command is input controls each unit of the printer 12 based on the recording command and issues a receipt.

次いで、プリンタードライバー実行部21による文字コードに対する処理について説明する。
POSアプリケーション実行部20から記録データが入力された場合、プリンタードライバー実行部21は、当該記録データを解析し、記録データに含まれる文字コードを抽出する。
次いで、プリンタードライバー実行部21は、抽出した文字コードを、番地情報に変換する。番地情報とは、コードページ40において、抽出した文字コードの文字に対応するフォントデータが格納された格納領域kの番地を示す情報のことである。なお、文字コードと、番地情報と、が対応づけられたテーブルがホスト側記憶部19に記憶されており、プリンタードライバー実行部21は、当該テーブルを参照して、文字コードを番地情報に変換する。例えば、図2を参照し、文字としての「¥」を示す文字コードについては、プリンタードライバー実行部21は、当該文字コードを、番地XXを示す番地情報に変換する。
プリンタードライバー実行部21は、文字コードを番地情報に変換した上で、記録コマンドをプリンター12に出力する。
上述したように、記録コマンドが入力されると、制御部30は、記録コマンドに基づいてプリントエンジン33を制御してレシートを発行する。その際、制御部30は、レシートに記録すべき文字については、番地情報に基づいて、コードページ40における格納領域kを特定し、特定した格納領域kに格納されているフォントデータに基づいて、文字に係る画像の記録を実行する。例えば、制御部30は、番地XXを示す番地情報に基づいて、コードページ40における格納領域k1を特定し、特定した格納領域k1に格納されているフォントデータに基づいて、通貨記号の画像を感熱ロール紙に記録する。
Next, processing for character codes by the printer driver execution unit 21 will be described.
When recording data is input from the POS application execution unit 20, the printer driver execution unit 21 analyzes the recording data and extracts a character code included in the recording data.
Next, the printer driver execution unit 21 converts the extracted character code into address information. The address information is information indicating the address of the storage area k in which the font data corresponding to the character of the extracted character code is stored in the code page 40. Note that a table in which the character code and the address information are associated with each other is stored in the host-side storage unit 19, and the printer driver execution unit 21 refers to the table and converts the character code into the address information. . For example, referring to FIG. 2, for a character code indicating “¥” as a character, the printer driver execution unit 21 converts the character code into address information indicating an address XX.
The printer driver execution unit 21 converts the character code into address information and outputs a recording command to the printer 12.
As described above, when a recording command is input, the control unit 30 controls the print engine 33 based on the recording command to issue a receipt. At that time, for the characters to be recorded on the receipt, the control unit 30 specifies the storage area k in the code page 40 based on the address information, and based on the font data stored in the specified storage area k, Recording of images related to characters is executed. For example, the control unit 30 specifies the storage area k1 in the code page 40 based on the address information indicating the address XX, and heats the currency symbol image based on the font data stored in the specified storage area k1. Record on roll paper.

次いで、初期実行コマンドデータ43について説明する。   Next, the initial execution command data 43 will be described.

図3は、不揮発性メモリー35に記憶されている初期実行コマンドデータ43を模式的に示す図である。
初期実行コマンドデータ43とは、電源の投入後、又は、リセット後に実行すべきコマンドを一覧的に記憶したデータである。リセットとは、プリンター12の電源がオンの状態のときに、電源がオンの状態を維持しつつ、プリンター12を再び始動の状態に戻すことを言い、本実施形態では、ホストコンピューター10からリセットを指示するコマンドが入力されることにより、リセットに係る処理が開始される。このリセット後は、電源導入後と同様の処理が行われる。
初期処理とは、電源の投入後、又は、リセット後に実行すべき処理として予め定められている処理のことであり、例えば、CPUやRAMに対するリセット等の必要な初期処理や、各種プログラムに対する所定のイニシャル処理等の各種初期化に係る処理、プリントエンジン33の各種機構の初期動作確認に係る処理等である。
そして、初期実行コマンドデータ43には、初期処理を実行する場合、プリンター12を正常に作動させるために必ず実行すべき処理として、ファームウェア41の機能によって行われる処理とは別に、付加的に実行すべき処理のコマンド(以下、「初期実行コマンド」という。)が一覧的に記憶されている。つまり、初期実行コマンドデータ43に1のコマンドが登録されている場合、プリンター12は、初期処理の実行に際し、ファームウェア41の機能により行われる初期処理と併せて、当該1のコマンドを実行する。
FIG. 3 is a diagram schematically showing the initial execution command data 43 stored in the nonvolatile memory 35.
The initial execution command data 43 is data that stores a list of commands to be executed after the power is turned on or reset. The term “reset” refers to returning the printer 12 to the start-up state again while maintaining the power-on state when the printer 12 is on. In this embodiment, the reset is performed from the host computer 10. When a command to instruct is input, processing related to reset is started. After this reset, the same processing as after the power supply is introduced is performed.
The initial process is a process that is predetermined as a process to be executed after the power is turned on or after the reset. For example, a necessary initial process such as a reset for the CPU or RAM, a predetermined process for various programs, and the like. For example, a process related to various initializations such as an initial process, a process related to initial operation confirmation of various mechanisms of the print engine 33, and the like.
In addition, in the initial execution command data 43, when initial processing is executed, it is additionally executed separately from processing performed by the function of the firmware 41 as processing that must be executed in order to operate the printer 12 normally. Commands for power processing (hereinafter referred to as “initial execution commands”) are stored in a list. That is, when one command is registered in the initial execution command data 43, the printer 12 executes the first command together with the initial processing performed by the function of the firmware 41 when executing the initial processing.

図3に示すように、初期実行コマンドデータ43は、情報部43aと、データ部43bとにより構成されている。
データ部43bには、初期実行コマンドを示すデータが実行順に連続して書き込まれている。図3の例では、データ部43bには、それぞれ8バイトからなる初期実行コマンドを示すデータが、実行順に、5つ、連続して書き込まれている。
情報部43aには、データ部43bのサイズを示す情報であるサイズ情報が書き込まれている。図3の例では、データ部43bのサイズは40バイト(8バイト×5)であるため、情報部43aには、データ部43bのサイズが40バイトであることを示すサイズ情報が書き込まれている。
なお、情報部43a、及び、データ部43bが記憶されている記憶領域の先頭アドレスは、固定である。
このように本実施形態では、初期実行コマンドデータ43におけるデータ部43bに、各初期コマンドを示すデータが実行順に連続して書き込まれているため、当該データ部43bが占める記憶領域が必要最小限で済むと共に、各コマンドを実行する順番を管理するための情報を記憶する必要がない。また、初期実行コマンドデータ43における情報部43aは、データ部43bのサイズを示す情報という、記憶領域においてデータ部43bが記憶されている領域を特定するために必要な最小限の情報を保持している。このため、この情報部43aのサイズ自体が小さく、不揮発性メモリー35の効率的な利用を実現できる。ここで、初期実行コマンドデータ43を、関係データベースとし、これにより、初期実行コマンドデータ43に記述された各初期実行コマンドの管理を容易化することも考えられるが、この場合、関係データベースの管理情報(例えば、記憶領域における各フィールドのアドレスと、各フィールドに格納されたデータとを対応付ける情報)を記憶する必要があり、また、不必要に記憶領域を確保する事態が生じ得るため、不揮発性メモリー35の効率的な利用に課題がある。
As shown in FIG. 3, the initial execution command data 43 includes an information part 43a and a data part 43b.
In the data portion 43b, data indicating the initial execution command is written successively in the execution order. In the example of FIG. 3, data indicating initial execution commands each consisting of 8 bytes are sequentially written in the data portion 43b in the order of execution.
In the information section 43a, size information that is information indicating the size of the data section 43b is written. In the example of FIG. 3, since the size of the data part 43b is 40 bytes (8 bytes × 5), size information indicating that the size of the data part 43b is 40 bytes is written in the information part 43a. .
Note that the start address of the storage area in which the information part 43a and the data part 43b are stored is fixed.
As described above, in the present embodiment, data indicating each initial command is continuously written in the data portion 43b in the initial execution command data 43 in the order of execution. Therefore, the storage area occupied by the data portion 43b is minimized. In addition, it is not necessary to store information for managing the order in which the commands are executed. Further, the information part 43a in the initial execution command data 43 holds minimum information necessary for specifying the area where the data part 43b is stored in the storage area, which is information indicating the size of the data part 43b. Yes. For this reason, the size of the information unit 43a itself is small, and efficient use of the nonvolatile memory 35 can be realized. Here, the initial execution command data 43 may be a relational database, thereby facilitating the management of each initial execution command described in the initial execution command data 43. In this case, however, the management information of the relational database (For example, information that associates the address of each field in the storage area with the data stored in each field) must be stored, and a situation in which the storage area is unnecessarily reserved may occur. There is a problem in the efficient use of 35.

この初期実行コマンドデータ43は、以下のことを目的として生成されたデータである。
すなわち、上位機種のプリンター、及び、下位機種のプリンター等、基本的なプラットフォームが共通し、プラットフォーム上で動くソフトウェアの体系が共通しているものにおいて、プリンター間で、初期処理に際して行うべき処理の大部分が共通している場合がある。このような場合に、それぞれ異なる初期処理を行うようなファームウェア41を別個にプログラミングし、インストールすれば、開発容易性が阻害され、また、開発コストの向上を招くおそれがある。
本実施形態では、初期実行コマンドデータ43を予め不揮発性メモリー35に記憶する構成とし、初期処理に際して行うべき処理のうち、異なる機種のプリンター間で共通する処理に関しては、ファームウェア41の機能として実行できるようファームウェア41をプログラミングし、一方、共通していない処理に関しては、当該処理に係るコマンドを、それぞれのプリンターの初期実行コマンドデータ43に記述する。これにより、少なくともファームウェア41の初期処理に係るプログラムに関しては、異なる機種のプリンター間で共通化することができ、別個のプログラムを開発する場合と比較して開発容易性の向上、及び、開発コストの削減を実現できる。
The initial execution command data 43 is data generated for the following purpose.
That is, in the case where the basic platform is common and the software system that runs on the platform is the same, such as the upper model printer and the lower model printer, a large amount of processing should be performed between the printers in the initial processing. The parts may be common. In such a case, if the firmware 41 that performs different initial processes is separately programmed and installed, the ease of development may be hindered and the development cost may be increased.
In the present embodiment, the initial execution command data 43 is stored in advance in the nonvolatile memory 35, and among the processes to be performed during the initial process, processes common to printers of different models can be executed as functions of the firmware 41. On the other hand, for the processing that is not common, the commands related to the processing are described in the initial execution command data 43 of each printer. As a result, at least the program related to the initial processing of the firmware 41 can be shared among printers of different models, improving the ease of development compared to the case of developing a separate program, and reducing the development cost. Reduction can be realized.

また、同一機種のプリンターであっても、プリンターが出荷される仕向地によって、初期処理に際して行うべき処理が異なる場合がある。本実施形態では、初期実行コマンドデータ43を予め不揮発性メモリー35に記憶する構成とし、初期処理に際して行うべき処理のうち、仕向地にかかわらず共通する処理に関しては、ファームウェアの機能として実行できるようファームウェアをプログラミングし、一方、仕向地によって異なる処理に関しては、それぞれのプリンターの初期実行コマンドデータ43に登録する。これにより、少なくともファームウェアの初期処理に係るプログラムに関しては、仕向地にかかわらず共通化することができ、仕向地に応じて別個のプログラムを開発する場合と比較して開発容易性の向上、及び、開発コストの削減を実現している。   Even for the same type of printer, the processing to be performed in the initial processing may differ depending on the destination where the printer is shipped. In the present embodiment, the initial execution command data 43 is stored in the nonvolatile memory 35 in advance, and among the processes to be performed during the initial process, the processes that are common regardless of the destination are processed so as to be executed as firmware functions. On the other hand, the processing that differs depending on the destination is registered in the initial execution command data 43 of each printer. Thereby, at least for the program related to the initial processing of the firmware, it can be shared regardless of the destination, and the improvement in the development ease compared with the case of developing a separate program according to the destination, and Reduces development costs.

本実施形態では、初期実行コマンドデータ43には、通貨記号書換処理実行コマンドTC、が記述されている。図3の例では、初期実行コマンドデータ43に記述された初期実行コマンドのうち、最初に記述されている初期実行コマンドが、通貨記号書換処理実行コマンドTCである。
通貨記号書換処理実行コマンドTCとは、仕向地に対応して、コードページ40における通貨記号を示すフォントデータの上書きを実行させるコマンドである。
すなわち、日本の通貨記号は「¥」であり、また、北米の通貨記号は「$」であるように、通貨記号は仕向地によって異なる。そして、通貨記号書換処理実行コマンドTCに係る処理は、コードページ40に形成された格納領域kのうち、通貨記号のフォントデータが格納される格納領域k(図2の例では格納領域k1)に対して、仕向地に対応した通貨記号のフォントデータを書き込む処理である。
例えば、仕向地が日本であるプリンター12における通貨記号書換処理実行コマンドTCは、格納領域k1に「¥」を示すフォントデータを上書きさせるコマンドであり、当該コマンドを読み出した制御部30は、不揮発性メモリー35のコードページ40にアクセスして、格納領域k1に「¥」を示すフォントデータを上書きする。また例えば、仕向地が北米であるプリンター12における通貨記号書換処理実行コマンドTCは、格納領域k1に「$」を示すフォントデータを書き込ませるコマンドであり、当該コマンドを実行した制御部30は、不揮発性メモリー35のコードページ40にアクセスして、格納領域k1に「$」を示すフォントデータを上書きする。
上記通貨記号のフォントデータの書き換えは、コードページ40の初期設定に該当する。つまり、コードページ40の初期設定は、仕向地に応じて異なっている。
In the present embodiment, the initial execution command data 43 describes a currency symbol rewriting process execution command TC. In the example of FIG. 3, the initial execution command described first among the initial execution commands described in the initial execution command data 43 is the currency symbol rewriting process execution command TC.
The currency symbol rewriting process execution command TC is a command for executing overwriting of font data indicating a currency symbol in the code page 40 corresponding to the destination.
That is, the currency symbol differs depending on the destination, such as “¥” for the currency symbol in Japan and “$” for the North American currency symbol. The processing related to the currency symbol rewriting process execution command TC is performed in the storage area k (store area k1 in the example of FIG. 2) in which the font data of the currency symbol is stored among the storage areas k formed in the code page 40. On the other hand, it is a process of writing font symbol font data corresponding to the destination.
For example, the currency symbol rewriting process execution command TC in the printer 12 whose destination is Japan is a command for overwriting the font data indicating “¥” in the storage area k1, and the control unit 30 that has read the command is nonvolatile. The code page 40 in the memory 35 is accessed, and the font data indicating “¥” is overwritten in the storage area k1. Further, for example, the currency symbol rewriting process execution command TC in the printer 12 whose destination is North America is a command for writing font data indicating “$” in the storage area k1, and the control unit 30 that has executed the command is a non-volatile memory. The code page 40 of the volatile memory 35 is accessed, and the font data indicating “$” is overwritten in the storage area k1.
The rewriting of the font data of the currency symbol corresponds to the initial setting of the code page 40. That is, the initial setting of the code page 40 differs depending on the destination.

次いで、制御部30が備える初期処理実行部30aの動作について説明する。
図4は、初期処理実行部30aの動作を示すフローチャートである。
初期処理実行部30aの機能は、CPUがプログラムを読み出して実行する等、ハードウェアとソフトウェアとの協働により実現される。
まず、初期処理実行部30aは、電源が投入されたか否か、又は、リセットが指示されたか否かを監視する(ステップSA1)。
電源が投入された、又は、リセットが指示された場合(ステップSA1:YES)、初期処理実行部30aは、初期実行コマンドデータ43の情報部43aにアクセスし、データ部43bのサイズを取得する(ステップSA2)。
次いで、初期処理実行部30aは、データ部43bの先頭アドレスにアクセスし、先頭アドレスの直後に書き込まれている初期実行コマンドを、1つ分、読み出して、実行する(ステップSA3)。その際、初期処理実行部30aは、読み出した初期実行コマンドを示すデータのサイズを取得し、サイズを示す情報をRAMの所定の記憶領域に記憶する。以後、初期処理実行部30aは、初期実行コマンドを読み出す度に、読み出した初期実行コマンドを示すデータのサイズを取得し、RAMに記憶されたサイズを示す情報に加算していく。以下の説明では、読み出した初期実行コマンドを示すデータのサイズの累計を、「累計サイズ」という。RAMの所定の記憶領域に記憶されたサイズを示す情報は、累計サイズを示している。
Next, the operation of the initial process execution unit 30a included in the control unit 30 will be described.
FIG. 4 is a flowchart showing the operation of the initial process execution unit 30a.
The function of the initial processing execution unit 30a is realized by cooperation of hardware and software, such as a CPU reading and executing a program.
First, the initial process execution unit 30a monitors whether power is turned on or whether reset is instructed (step SA1).
When the power is turned on or reset is instructed (step SA1: YES), the initial process execution unit 30a accesses the information unit 43a of the initial execution command data 43 and acquires the size of the data unit 43b ( Step SA2).
Next, the initial process execution unit 30a accesses the start address of the data unit 43b, reads one execution command written immediately after the start address, and executes it (step SA3). At this time, the initial process execution unit 30a acquires the size of the data indicating the read initial execution command, and stores the information indicating the size in a predetermined storage area of the RAM. Thereafter, each time the initial execution command is read, the initial process execution unit 30a acquires the size of the data indicating the read initial execution command and adds it to the information indicating the size stored in the RAM. In the following description, the total size of data indicating the read initial execution command is referred to as “total size”. Information indicating the size stored in a predetermined storage area of the RAM indicates the cumulative size.

ステップSA3においてデータ部43bの先頭アドレスの直後に書き込まれている初期実行コマンドを実行した後、初期処理実行部30aは、累計サイズが、ステップSA2で取得したデータ部43bのサイズとなったか否かを判別する(ステップSA4)。
累計サイズが、ステップSA2で取得したデータ部43bのサイズとなっているということは、データ部43bに書き込まれている初期実行コマンドの全てについて、読み出し、及び、実行が完了しているということである。
ステップSA4において、累計サイズが、ステップSA2で取得したデータ部43bのサイズとなった場合(ステップSA4:YES)、初期処理実行部30aは、処理を終了する。これにより、初期実行コマンドデータ43に記述された全ての初期実行コマンドについて、各初期実行コマンドに係る初期処理が完了する。
一方、ステップSA4において、累計サイズが、ステップSA2で取得したデータ部43bのサイズとなっていない場合(ステップSA4:NO)、初期処理実行部30aは、直前に読み出し、実行した初期実行コマンドの次に書き込まれている初期実行コマンドを、読み出して実行し(ステップSA5)、処理手順をステップSA4へ移行する。
After executing the initial execution command written immediately after the head address of the data part 43b in step SA3, the initial process execution part 30a determines whether or not the cumulative size is the size of the data part 43b acquired in step SA2. Is determined (step SA4).
The fact that the cumulative size is the size of the data part 43b acquired in step SA2 means that all the initial execution commands written in the data part 43b have been read and executed. is there.
In step SA4, when the cumulative size becomes the size of the data part 43b acquired in step SA2 (step SA4: YES), the initial process execution unit 30a ends the process. Thereby, the initial process related to each initial execution command is completed for all the initial execution commands described in the initial execution command data 43.
On the other hand, in step SA4, when the cumulative size is not the size of the data part 43b acquired in step SA2 (step SA4: NO), the initial process execution unit 30a reads the immediately preceding and executed initial execution command. The initial execution command written in is read and executed (step SA5), and the processing procedure proceeds to step SA4.

次いで、制御部30が備えるコマンド追記部30bの動作について説明する。
コマンド追記部30bの機能は、CPUがプログラムを読み出して実行する等、ハードウェアとソフトウェアとの協働により実現される。
図5は、コマンド追記部30bの動作を示すフローチャートである。
まず、コマンド追記部30bは、ホストコンピューター10から追記指示コマンドが入力されたか否かを監視する(ステップSB1)。
追記指示コマンドとは、初期実行コマンドデータ43に対して所定の初期実行コマンドを追記することを指示する制御コマンドであり、少なくとも、追加すべき所定の初期実行コマンドを示すデータが含まれる。本実施形態では、ユーザーは、POSアプリケーションの機能、プリンタードライバーの機能、又は、これらソフトウェア双方の機能により、ホストコンピューター10を操作して、プリンター12に対して、所定の初期実行コマンドに係る追記指示コマンドを出力させることが可能となる。例えば、プリンタードライバーの機能により、追記指示コマンドを出力するためのユーザーインターフェイスが提供されており、ユーザーは、当該ユーザーインターフェイスに必要な情報を入力することにより、ホストコンピューター10に追記指示コマンドを出力させることが可能となる。この追記指示コマンドは、新たに開発された制御コマンドであり、本実施形態に係るプリンター12は、このような追記指示コマンドに基づいて、所定の初期実行コマンドの初期実行コマンドデータ43への追記が可能である点において、従来と異なる。
Next, the operation of the command appending unit 30b included in the control unit 30 will be described.
The function of the command appending unit 30b is realized by cooperation of hardware and software, such as a CPU reading and executing a program.
FIG. 5 is a flowchart showing the operation of the command appending unit 30b.
First, the command appending unit 30b monitors whether or not an appending instruction command is input from the host computer 10 (step SB1).
The additional write instruction command is a control command for instructing the initial execution command data 43 to add a predetermined initial execution command, and includes at least data indicating the predetermined initial execution command to be added. In this embodiment, the user operates the host computer 10 with the function of the POS application, the function of the printer driver, or the functions of both of these software, and instructs the printer 12 to add information related to a predetermined initial execution command. It is possible to output commands. For example, a user interface for outputting an additional write instruction command is provided by the function of the printer driver, and the user causes the host computer 10 to output an additional write instruction command by inputting information necessary for the user interface. It becomes possible. This additional write instruction command is a newly developed control command, and the printer 12 according to the present embodiment can add a predetermined initial execution command to the initial execution command data 43 based on such an additional write instruction command. It is different from the prior art in that it is possible.

次いで、コマンド追記部30bは、初期実行コマンドデータ43の情報部43aを参照する等して、データ部43bの末尾アドレスにアクセスする(ステップSB2)。
次いで、コマンド追記部30bは、データ部43bの末尾アドレスから、追記指示コマンドに含まれる初期実行コマンドを示すデータを書き込む(ステップSB3)。
次いで、コマンド追記部30bは、ステップSB3における書き込み後のデータ部43bのサイズを取得する(ステップSB4)。
次いで、コマンド追記部30bは、初期実行コマンドデータ43の情報部43aにアクセスし、情報部43aのサイズ情報の内容を、ステップSB4で取得したサイズを示すように書き換える(ステップSB5)。
以上により、ホストコンピューター10から入力された追記指示コマンドに基づく、初期実行コマンドデータ43への初期実行コマンドの追記が完了し、以後、電源が投入され、また、リセットが指示された場合は、新たに追記された初期実行コマンドに基づく初期処理が行われる。
Next, the command appending part 30b accesses the tail address of the data part 43b by referring to the information part 43a of the initial execution command data 43 (step SB2).
Next, the command appending unit 30b writes data indicating the initial execution command included in the appending instruction command from the end address of the data unit 43b (step SB3).
Next, the command appending part 30b acquires the size of the data part 43b after writing in Step SB3 (Step SB4).
Next, the command appending unit 30b accesses the information unit 43a of the initial execution command data 43, and rewrites the content of the size information in the information unit 43a to indicate the size acquired in Step SB4 (Step SB5).
As described above, the addition of the initial execution command to the initial execution command data 43 based on the additional write instruction command input from the host computer 10 is completed. Thereafter, when the power is turned on or reset is instructed, Initial processing based on the initial execution command added to is performed.

このように、本実施形態に係るプリンター12は、電源の投入後、又は、リセット後に実行すべき初期処理に係る初期実行コマンドが記述された初期実行コマンドデータ43を、不揮発性メモリー35に記憶しておき、電源の投入後、又は、リセット後、当該初期実行コマンドデータ43に基づいて、実行すべき初期処理を順次実行していく構成である。このため、ファームウェア41の書き換えを伴うことなく、初期実行コマンドデータ43の編集により、実行すべき初期処理の追加が可能となる。
特に、ホストコンピューター10からプリンター12に対して、追記指示コマンドを出力すれば、プリンター12が、自動で、不揮発性メモリー35にアクセスして、追加すべき初期実行コマンドを初期実行コマンドデータ43に追記する構成である。このため、実行すべき初期処理を追加する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリー35に直接アクセスし、当該不揮発性メモリー35の所定の記憶領域に記憶されている初期実行コマンドデータ43を、手順に沿って編集する、といった煩雑な作業を行うことなく、ホストコンピューター10の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
As described above, the printer 12 according to this embodiment stores, in the nonvolatile memory 35, the initial execution command data 43 in which the initial execution command related to the initial process to be executed after the power is turned on or after the reset is described. In addition, after the power is turned on or reset, the initial processing to be executed is sequentially executed based on the initial execution command data 43. Therefore, it is possible to add an initial process to be executed by editing the initial execution command data 43 without rewriting the firmware 41.
In particular, if an additional write instruction command is output from the host computer 10 to the printer 12, the printer 12 automatically accesses the nonvolatile memory 35 and adds an initial execution command to be added to the initial execution command data 43. It is the structure to do. Therefore, when adding an initial process to be executed, the user directly accesses the nonvolatile memory 35 using a dedicated software tool and stores the initial execution stored in a predetermined storage area of the nonvolatile memory 35. It is only necessary to output an additional write instruction command by the function of the host computer 10 without performing a complicated operation such as editing the command data 43 according to the procedure, and the operation is very easy.

上述したように、本実施形態では、初期実行コマンドデータ43に記述されている初期実行コマンドには、通貨記号書換処理実行コマンドTCが含まれているが、これに関して、プリンター12の出荷前の製造工程において以下の処理が行われる。
すなわち、ある1のプリンター12の製造工程において、当該プリンター12の仕向地が決定すると、当該プリンター12(必ずしも完成品である必要なく、プリンター12の制御基板だけであってもよい。)に対して、ホストコンピューター10と同等の機能を有する制御装置から、初期実行コマンドデータ43に、仕向地に対応した通貨記号書換処理実行コマンドTCを追記することを指示する追記指示コマンドを出力する。プリンター12のコマンド追記部30bは、入力された追記指示コマンドに基づいて、図5のフローチャートで示した処理を実行し、初期実行コマンドデータ43への通貨記号書換処理実行コマンドTCの追記を行う。
ここで、仕向地は、製造工程の後半に決定されることが多く、また、一度決まった仕向地の変更が行われることもある。そして、本実施形態に係るプリンター12では、追記指示コマンドを利用して、非常に容易に、初期実行コマンドデータ43に、仕向地に対応した通貨記号書換処理実行コマンドTCを追記することが可能であり、製造容易性の向上、製造コストの削減を実現できる。
As described above, in the present embodiment, the initial execution command described in the initial execution command data 43 includes the currency symbol rewriting process execution command TC. The following processing is performed in the process.
That is, in the manufacturing process of a certain printer 12, when the destination of the printer 12 is determined, the printer 12 (not necessarily a finished product, but only the control board of the printer 12) may be used. Then, a control unit having a function equivalent to that of the host computer 10 outputs a postscript instruction command for instructing to add a currency symbol rewriting process execution command TC corresponding to the destination to the initial execution command data 43. The command appending unit 30b of the printer 12 executes the process shown in the flowchart of FIG. 5 based on the input appending instruction command, and appends the currency symbol rewriting process execution command TC to the initial execution command data 43.
Here, the destination is often determined in the second half of the manufacturing process, and the destination may be changed once. In the printer 12 according to the present embodiment, it is possible to add the currency symbol rewrite processing execution command TC corresponding to the destination to the initial execution command data 43 very easily using the additional instruction command. Yes, it is possible to improve manufacturability and reduce manufacturing costs.

次いで、制御部30が備えるコマンド削除部30cの動作について説明する。
コマンド削除部30cの機能は、CPUがプログラムを読み出して実行する等、ハードウェアとソフトウェアとの協働により実現される。
図6は、コマンド削除部30cの動作を示すフローチャートである。
まず、コマンド削除部30cは、ホストコンピューター10から削除指示コマンドが入力されたか否かを監視する(ステップSC1)。
削除指示コマンドとは、初期実行コマンドデータ43から所定の初期実行コマンドを削除することを指示する制御コマンドであり、少なくとも、削除すべき所定の初期実行コマンドを特定するために必要な情報を含むデータが含まる。本実施形態では、ユーザーは、POSアプリケーションの機能、プリンタードライバーの機能、又は、これらソフトウェア双方の機能により、ホストコンピューター10を操作して、プリンター12に対して、所定の初期実行コマンドに係る削除指示コマンドを出力させることが可能となる。例えば、プリンタードライバーの機能により、削除指示コマンドを出力するためのユーザーインターフェイスが提供されており、ユーザーは、当該ユーザーインターフェイスに必要な情報を入力することにより、ホストコンピューター10に削除指示コマンドを出力させることが可能となる。この削除指示コマンドは、新たに開発された制御コマンドであり、本実施形態に係るプリンター12は、このような削除指示コマンドに基づいて、所定の初期実行コマンドの初期実行コマンドデータ43あらの削除が可能である点において、従来と異なる。
Next, the operation of the command deletion unit 30c included in the control unit 30 will be described.
The function of the command deletion unit 30c is realized by cooperation of hardware and software, such as a CPU reading and executing a program.
FIG. 6 is a flowchart showing the operation of the command deletion unit 30c.
First, the command deletion unit 30c monitors whether or not a deletion instruction command is input from the host computer 10 (step SC1).
The deletion instruction command is a control command instructing to delete a predetermined initial execution command from the initial execution command data 43, and at least data including information necessary for specifying a predetermined initial execution command to be deleted Is included. In the present embodiment, the user operates the host computer 10 with the function of the POS application, the function of the printer driver, or the function of both of these software, and instructs the printer 12 to delete related to a predetermined initial execution command. It is possible to output commands. For example, a user interface for outputting a delete instruction command is provided by the function of the printer driver, and the user causes the host computer 10 to output a delete instruction command by inputting necessary information to the user interface. It becomes possible. This deletion instruction command is a newly developed control command, and the printer 12 according to the present embodiment deletes the initial execution command data 43 of a predetermined initial execution command based on such a deletion instruction command. It is different from the prior art in that it is possible.

次いで、コマンド削除部30cは、初期実行コマンドデータ43のデータ部43bにアクセスし、削除すべき所定の初期実行コマンドを示すデータを削除する(ステップSC2)。当該データの削除は、例えば、以下のように行われる。すなわち、コマンド削除部30cは、初期実行コマンドを削除した後、当該削除した初期実行コマンド以降に記述されている初期実行コマンドによって、当該削除した初期実行コマンドが記憶されていた領域を詰めるか、又は、削除すべき初期実行コマンドを示すデータを、Nullデータによって上書きする。
次いで、コマンド削除部30cは、ステップSC2における削除後のデータ部43bのサイズを取得する(ステップSC3)。ステップSC2において、当該削除した初期実行コマンドが記憶されていた領域を詰めた場合は、サイズは小さくなり、Nullデータによって上書きした場合は、サイズは変わらない。
次いで、コマンド削除部30cは、初期実行コマンドデータ43の情報部43aにアクセスし、情報部43aのサイズ情報の内容を、ステップSC3で取得したサイズを示すように書き換える(ステップSC4)。
以上により、ホストコンピューター10から入力された削除指示コマンドに基づく、初期実行コマンドデータ43からの初期実行コマンドの削除が完了し、以後、電源が投入され、また、リセットが指示された場合は、削除された初期実行コマンドに基づく初期処理は行われない。
Next, the command deletion unit 30c accesses the data unit 43b of the initial execution command data 43 and deletes data indicating a predetermined initial execution command to be deleted (step SC2). The deletion of the data is performed as follows, for example. That is, after deleting the initial execution command, the command deletion unit 30c closes the area in which the deleted initial execution command is stored with the initial execution command described after the deleted initial execution command, or The data indicating the initial execution command to be deleted is overwritten with Null data.
Next, the command deletion unit 30c acquires the size of the data unit 43b after the deletion in step SC2 (step SC3). In step SC2, when the area where the deleted initial execution command is stored is filled, the size is reduced, and when overwritten by Null data, the size does not change.
Next, the command deletion unit 30c accesses the information unit 43a of the initial execution command data 43, and rewrites the content of the size information in the information unit 43a to indicate the size acquired in step SC3 (step SC4).
As described above, the deletion of the initial execution command from the initial execution command data 43 based on the deletion instruction command input from the host computer 10 is completed, and thereafter, when the power is turned on and the reset is instructed, the deletion is performed. The initial processing based on the initial execution command thus performed is not performed.

なお、プリンター12の制御部30は、ホストコンピューター10から入力されたコマンドに応じて、以下の処理を行う構成となる。
すなわち、ホストコンピューター10から、初期実行コマンドデータ43のサイズ(データ部43bのみのサイズでもよい。)について、応答を要求するコマンドが入力された場合、制御部30は、初期実行コマンドデータ43のサイズを取得し、応答する。
また、ホストコンピューター10から、初期実行コマンドデータ43を記憶可能な領域として確保されている記憶領域のサイズと、当該記憶領域に記憶されている初期実行コマンドデータ43の実データのサイズとの差分(つまり、初期実行コマンドデータ43に係るデータを記憶可能な残りの領域のサイズ)について、応答を要求するコマンドが入力された場合、制御部30は、当該差分を取得し、応答する。
また、ホストコンピューター10から、初期実行コマンドデータ43に記述されている初期実行コマンドの全てについて、又は、特定の初期実行コマンドについて、コマンドを示すデータの送信を要求するコマンドが入力された場合、制御部30は、対応するコマンドを示すデータを送信する。
また、ホストコンピューター10から、初期実行コマンドデータ43全体の削除を指示するコマンドが入力された場合、制御部30は、不揮発性メモリー35から初期実行コマンドデータ43を削除する。
このように、本実施形態に係るプリンター12では、従来、ソフトウェアツール等を利用して、直接、不揮発性メモリー35にアクセスして行っていた処理を、ホストコンピューター10から特定のコマンドを出力することにより実行可能となっており、各処理に要する作業が容易化する。
Note that the control unit 30 of the printer 12 is configured to perform the following processing in accordance with a command input from the host computer 10.
That is, when a command requesting a response is input from the host computer 10 with respect to the size of the initial execution command data 43 (the size of only the data portion 43b), the control unit 30 determines the size of the initial execution command data 43. Get and respond.
Further, the difference between the size of the storage area secured as an area where the initial execution command data 43 can be stored from the host computer 10 and the actual data size of the initial execution command data 43 stored in the storage area ( That is, when a command for requesting a response is input for the size of the remaining area in which data related to the initial execution command data 43 can be stored, the control unit 30 acquires the difference and responds.
In addition, when a command requesting transmission of data indicating a command is input from the host computer 10 for all of the initial execution commands described in the initial execution command data 43 or for a specific initial execution command, the control is performed. The unit 30 transmits data indicating the corresponding command.
Further, when a command instructing deletion of the entire initial execution command data 43 is input from the host computer 10, the control unit 30 deletes the initial execution command data 43 from the nonvolatile memory 35.
As described above, in the printer 12 according to the present embodiment, a specific command is output from the host computer 10 for processing that has conventionally been performed by directly accessing the nonvolatile memory 35 using a software tool or the like. The operation required for each process is facilitated.

以上説明したように、本実施形態に係るプリンター12では、不揮発性メモリー35に、初期実行コマンドが記述された初期実行コマンドデータ43が記憶されている。そして、プリンター12は、電源の投入後、又は、リセット後、初期実行コマンドデータ43に基づいて、当該データに記述された初期実行コマンドを順次実行する初期処理実行部30aと、初期実行コマンドデータ43への所定の初期実行コマンドの追記を指示する追記指示コマンドがホストコンピューター10から入力された場合、不揮発性メモリー35にアクセスし、初期実行コマンドデータ43に当該所定の初期実行コマンドを追記するコマンド追記部30bと、を備える。
このように、本実施形態に係るプリンター12は、電源の投入後、又は、リセット後に実行すべき初期処理に係る初期実行コマンドが記述された初期実行コマンドデータ43を、不揮発性メモリー35に記憶しておき、電源の投入後、又は、リセット後、当該初期実行コマンドデータ43に基づいて、実行すべき初期処理を順次実行していく構成であるため、ファームウェア41の書き換えを伴うことなく、初期実行コマンドデータ43の編集により、実行すべき初期処理の追加が可能となる。
特に、ホストコンピューター10からプリンター12に対して、追記指示コマンドを出力すれば、プリンター12が、自動で、不揮発性メモリー35にアクセスして、追加すべき初期実行コマンドを初期実行コマンドデータ43に追記する構成であるため、実行すべき初期処理を追加する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリー35に直接アクセスし、当該不揮発性メモリー35の所定の記憶領域に記憶されている初期実行コマンドデータ43を、手順に沿って編集する、といった煩雑な作業を行うことなく、ホストコンピューター10の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
As described above, in the printer 12 according to the present embodiment, the initial execution command data 43 in which the initial execution command is described is stored in the nonvolatile memory 35. Then, after the power is turned on or reset, the printer 12 sequentially executes the initial execution command 30 described in the data based on the initial execution command data 43, and the initial execution command data 43. When an additional write instruction command for instructing additional write of a predetermined initial execution command is input from the host computer 10, the nonvolatile memory 35 is accessed, and a command additional write for adding the predetermined initial execution command to the initial execution command data 43 is performed. Part 30b.
As described above, the printer 12 according to this embodiment stores, in the nonvolatile memory 35, the initial execution command data 43 in which the initial execution command related to the initial process to be executed after the power is turned on or after the reset is described. In addition, after the power is turned on or reset, the initial execution to be executed is sequentially executed based on the initial execution command data 43. Therefore, the initial execution is not performed without rewriting the firmware 41. By editing the command data 43, it is possible to add an initial process to be executed.
In particular, if an additional write instruction command is output from the host computer 10 to the printer 12, the printer 12 automatically accesses the nonvolatile memory 35 and adds an initial execution command to be added to the initial execution command data 43. Therefore, when adding an initial process to be executed, the user directly accesses the nonvolatile memory 35 using a dedicated software tool and is stored in a predetermined storage area of the nonvolatile memory 35. The additional write instruction command may be output by the function of the host computer 10 without performing a complicated operation such as editing the initial execution command data 43 that is included in the procedure, and the operation is very easy.

また、本実施形態では、初期実行コマンドデータ43におけるデータ部43bでは、各初期コマンドを示すデータが実行順に連続して書き込まれているため、当該データ部43bが占める記憶領域が必要最小限で済むと共に、各コマンドを実行する順番を管理するための情報を記憶する必要がない。また、初期実行コマンドデータ43における情報部43aは、データ部43bのサイズを示す情報という、記憶領域においてデータ部43bが記憶されている領域を特定するために必要な最小限の情報を保持している。このため、この情報部43aのサイズ自体が小さく、不揮発性メモリー35の効率的な利用を実現できる。ここで、初期実行コマンドデータ43を、関係データベースとし、これにより、初期実行コマンドデータ43に記述された各初期実行コマンドの管理を容易化することも考えられるが、この場合、関係データベースの管理情報(例えば、記憶領域における各フィールドのアドレスと、各フィールドに格納されたデータとを対応付ける情報)を記憶する必要があり、また、不必要に記憶領域を確保する事態が生じ得るため、不揮発性メモリー35の効率的な利用に課題がある。   Further, in the present embodiment, in the data portion 43b in the initial execution command data 43, data indicating each initial command is continuously written in the execution order, so that the storage area occupied by the data portion 43b can be minimized. At the same time, there is no need to store information for managing the order in which the commands are executed. Further, the information part 43a in the initial execution command data 43 holds minimum information necessary for specifying the area where the data part 43b is stored in the storage area, which is information indicating the size of the data part 43b. Yes. For this reason, the size of the information unit 43a itself is small, and efficient use of the nonvolatile memory 35 can be realized. Here, the initial execution command data 43 may be a relational database, thereby facilitating the management of each initial execution command described in the initial execution command data 43. In this case, however, the management information of the relational database (For example, information that associates the address of each field in the storage area with the data stored in each field) must be stored, and a situation in which the storage area is unnecessarily reserved may occur. There is a problem in the efficient use of 35.

また、本実施形態では、不揮発性メモリー35には、フォントデータが格納されたコードページ40が記憶されており、このコードページ40は、仕向地に応じて、その初期設定が異なる。より具体的には、仕向地に応じて、通貨記号に係るフォントデータについて、初期処理において書き換えるべきフォントデータが異なる。そして、本実施形態では、追記指示コマンドには、特定の仕向地に応じたコードページ40の初期設定を行うための初期実行コマンドの追記を指示するものがあるため、追記指示コマンドを利用して、仕向地に応じて、コードページの初期設定を容易に変更可能である。   In the present embodiment, the nonvolatile memory 35 stores a code page 40 in which font data is stored, and the code page 40 has an initial setting that differs depending on the destination. More specifically, the font data to be rewritten in the initial process differs for the font data related to the currency symbol depending on the destination. In the present embodiment, the additional instruction command includes an instruction to add an initial execution command for performing the initial setting of the code page 40 according to a specific destination, so the additional instruction command is used. The initial setting of the code page can be easily changed according to the destination.

また、本実施形態では、コマンド削除部30cは、ホストコンピューター10から、初期実行コマンドデータ43に記述されている所定の初期実行コマンドの削除を指示する削除指示コマンドが入力された場合、不揮発性メモリー35にアクセスし、初期実行コマンドデータ43から当該所定の初期実行コマンドを削除する。
これによれば、初期実行コマンドデータ43から所定の初期実行コマンドを削除する際、ユーザーは、専用のソフトウェアツールを利用して、不揮発性メモリー35に直接アクセスし、当該不揮発性メモリー35の所定の記憶領域に記憶されている初期実行コマンドデータ43を、手順に沿って編集する、といった煩雑な作業を行うことなく、ホストコンピューター10の機能により追記指示コマンドを出力すればよく、作業が非常に容易である。
In the present embodiment, the command deletion unit 30c is configured such that when a deletion instruction command for instructing deletion of a predetermined initial execution command described in the initial execution command data 43 is input from the host computer 10, the nonvolatile memory 35 is deleted, and the predetermined initial execution command is deleted from the initial execution command data 43.
According to this, when deleting a predetermined initial execution command from the initial execution command data 43, the user directly accesses the nonvolatile memory 35 using a dedicated software tool, and stores the predetermined storage in the nonvolatile memory 35. The initial execution command data 43 stored in the area can be output according to the function of the host computer 10 without performing a complicated operation such as editing in accordance with the procedure, and the operation is very easy. is there.

なお、上述した実施の形態は、あくまでも本発明の一態様を示すものであり、本発明の範囲内で任意に変形および応用が可能である。
例えば、上述した実施形態の例では、コードページ40の初期設定は、仕向地に応じた通貨記号の書き換えであったが、コードページ40の初期設定には、この他にも、例えば、言語に応じて複数のコードページ40が登録する場合において、特定の言語のコードページ40を有効とするように設定すること、がある。すなわち、コードページ40の初期設定は、コードページ40に関して、電源の投入後、又は、リセット後に行うべき処理の全てを含む概念である。
また例えば、上述した実施形態では、プリンター12は、サーマル式のプリンターであったが、記録装置の記録形式はこれに限らず、インクジェット式、ドットインパクト式等でもよい。
また例えば、図1に示す各機能ブロックはハードウェアとソフトウェアの協働により任意に実現可能であり、特定のハードウェア構成を示唆するものではない。
また例えば、制御部30の機能を、プリンター12に外部接続される別の装置に持たせてもよい。
また、外部接続される記憶媒体に記憶させたプログラムを実行することにより、図3、図4、及び、図5で示した各フローチャートの各ステップを実行してもよい。
The above-described embodiment is merely an aspect of the present invention, and can be arbitrarily modified and applied within the scope of the present invention.
For example, in the example of the above-described embodiment, the initial setting of the code page 40 is rewriting of the currency symbol according to the destination, but other than the initial setting of the code page 40, for example, the language Accordingly, when a plurality of code pages 40 are registered, the code page 40 in a specific language may be set to be valid. That is, the initial setting of the code page 40 is a concept including all of the processes to be performed after the power is turned on or after the reset regarding the code page 40.
Further, for example, in the above-described embodiment, the printer 12 is a thermal printer, but the recording format of the recording apparatus is not limited to this, and may be an ink jet type, a dot impact type, or the like.
Further, for example, each functional block shown in FIG. 1 can be arbitrarily realized by cooperation of hardware and software, and does not suggest a specific hardware configuration.
Further, for example, the function of the control unit 30 may be provided in another device externally connected to the printer 12.
Further, each step of each flowchart shown in FIGS. 3, 4, and 5 may be executed by executing a program stored in an externally connected storage medium.

1…記録システム、10…ホストコンピューター(制御装置)、12…プリンター(記録装置)、30…制御部、30a…初期処理実行部、30b…コマンド追記部、30c…コマンド削除部、35…不揮発性メモリー、40…コードページ、43…初期実行コマンドデータ、43a…情報部、43b…データ部。   DESCRIPTION OF SYMBOLS 1 ... Recording system, 10 ... Host computer (control apparatus), 12 ... Printer (recording apparatus), 30 ... Control part, 30a ... Initial process execution part, 30b ... Command addition part, 30c ... Command deletion part, 35 ... Non-volatile Memory, 40 ... code page, 43 ... initial execution command data, 43a ... information part, 43b ... data part.

Claims (6)

制御装置に接続可能な記録装置であって、
電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータが記憶された不揮発性メモリーと、
電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する初期処理実行部と、
前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記するコマンド追記部と、を備えることを特徴とする記録装置。
A recording device connectable to a control device,
A non-volatile memory storing initial execution command data in which one or more initial execution commands for executing initial processing to be executed after power-on or after resetting are stored;
An initial process execution unit that sequentially executes the initial execution command based on the initial execution command data stored in the nonvolatile memory after power-on or reset;
When a write-once instruction command for instructing addition of a predetermined initial execution command to the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the predetermined initial execution command is added to the initial execution command data. And a command appending unit for appending the command.
前記初期実行コマンドデータは、
前記不揮発性メモリーの所定の記憶領域に、各初期実行コマンドを示すデータが実行順に連続して書き込まれたデータ部と、
当該記憶領域における前記データ部のサイズを示す情報を含む情報部と、を含んで構成され、
前記コマンド追記部は、
前記制御装置から追記指示コマンドが入力された場合、前記データ部の末尾アドレスから追記すべき所定の初期実行コマンドを示すデータを書き込むと共に、前記情報部における前記データ部のサイズを示す情報を、当該書き込み後の前記データ部のサイズを示す情報に書き換えることを特徴とする請求項1に記載の記録装置。
The initial execution command data is:
A data portion in which data indicating each initial execution command is successively written in the execution order in a predetermined storage area of the nonvolatile memory;
An information part including information indicating the size of the data part in the storage area,
The command appending unit
When an appending instruction command is input from the control device, data indicating a predetermined initial execution command to be appended from the end address of the data part is written, and information indicating the size of the data part in the information part is The recording apparatus according to claim 1, wherein the recording apparatus is rewritten with information indicating a size of the data portion after writing.
前記不揮発性メモリーには、フォントデータが格納されたコードページが記憶され、このコードページは、仕向地に応じて、その初期設定が異なっており、
追記指示コマンドには、特定の仕向地に応じた前記コードページの初期設定を行うための初期実行コマンドの追記を指示するものがあることを特徴とする請求項1又は2に記載の記録装置。
The nonvolatile memory stores a code page in which font data is stored, and the code page has different initial settings depending on the destination,
The recording apparatus according to claim 1, wherein the additional recording instruction command includes an instruction to add an initial execution command for performing the initial setting of the code page according to a specific destination.
前記制御装置から、前記初期実行コマンドデータに記述されている所定の初期実行コマンドの削除を指示する削除指示コマンドが入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータから当該所定の初期実行コマンドを削除するコマンド削除部と、を備えることを特徴とする請求項1ないし3のいずれかに記載の記録装置。   When a deletion instruction command for instructing deletion of a predetermined initial execution command described in the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the predetermined execution command data is The recording apparatus according to claim 1, further comprising: a command deleting unit that deletes the initial execution command. 制御装置に接続可能な記録装置の制御方法であって、
電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータを不揮発性メモリーに記憶し、
電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する一方、
前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記することを特徴とする記録装置の制御方法。
A method for controlling a recording device connectable to a control device, comprising:
Storing initial execution command data in which one or more initial execution commands for executing initial processing to be executed after power-on or after resetting are described in a nonvolatile memory;
After the power is turned on or reset, the initial execution command is sequentially executed based on the initial execution command data stored in the nonvolatile memory,
When a write-once instruction command for instructing addition of a predetermined initial execution command to the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the predetermined initial execution command is added to the initial execution command data. A method for controlling a recording apparatus, comprising:
制御装置に接続可能に構成され、
電源の投入後、又は、リセット後に実行すべき初期処理を実行するための初期実行コマンドが1又は複数記述された初期実行コマンドデータが記憶された不揮発性メモリーを備える記録装置を制御する制御部により実行されるプログラムであって、
前記制御部を、
電源の投入後、又は、リセット後、前記不揮発性メモリーに記憶された前記初期実行コマンドデータに基づいて、前記初期実行コマンドを順次実行する初期処理実行部と、
前記初期実行コマンドデータへの所定の初期実行コマンドの追記を指示する追記指示コマンドが前記制御装置から入力された場合、前記不揮発性メモリーにアクセスし、前記初期実行コマンドデータに当該所定の初期実行コマンドを追記するコマンド追記部と、として機能させることを特徴とするプログラム。
Configured to be connectable to the control unit,
By a control unit that controls a recording apparatus including a non-volatile memory in which one or more initial execution command data for executing an initial process to be executed after power-on or after resetting is stored. A program to be executed,
The control unit
An initial process execution unit that sequentially executes the initial execution command based on the initial execution command data stored in the nonvolatile memory after power-on or reset;
When a write-once instruction command for instructing addition of a predetermined initial execution command to the initial execution command data is input from the control device, the nonvolatile memory is accessed, and the predetermined initial execution command is added to the initial execution command data. And a command appending unit for appending a program.
JP2011278289A 2011-12-20 2011-12-20 Recording apparatus, control method of recording apparatus, and program Pending JP2013129066A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011278289A JP2013129066A (en) 2011-12-20 2011-12-20 Recording apparatus, control method of recording apparatus, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011278289A JP2013129066A (en) 2011-12-20 2011-12-20 Recording apparatus, control method of recording apparatus, and program

Publications (1)

Publication Number Publication Date
JP2013129066A true JP2013129066A (en) 2013-07-04

Family

ID=48907073

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011278289A Pending JP2013129066A (en) 2011-12-20 2011-12-20 Recording apparatus, control method of recording apparatus, and program

Country Status (1)

Country Link
JP (1) JP2013129066A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2020044689A (en) * 2018-09-18 2020-03-26 セイコーエプソン株式会社 Control method of printer and printer

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2020044689A (en) * 2018-09-18 2020-03-26 セイコーエプソン株式会社 Control method of printer and printer
JP7147405B2 (en) 2018-09-18 2022-10-05 セイコーエプソン株式会社 PRINTING DEVICE CONTROL METHOD AND PRINTING DEVICE

Similar Documents

Publication Publication Date Title
JP4270152B2 (en) Print control program, print control apparatus, and print control method
JP5810609B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
JP5909871B2 (en) Recording device
KR101429850B1 (en) Recording device and control method of a recording device
JP5842335B2 (en) Image recording apparatus, image recording apparatus control method, and program
US20150002889A1 (en) Control device, control system, and control method of a control device
JP2012141880A (en) Controller, recording system, control method of controller and program
JP4793384B2 (en) Label printing device
CN101539844B (en) Information processing apparatus and method
JP2013129066A (en) Recording apparatus, control method of recording apparatus, and program
US20060055950A1 (en) Image data registration method, image data registration program, and printing apparatus
JP6127542B2 (en) PRINT CONTROL DEVICE, CONTROL METHOD AND PROGRAM FOR PRINT CONTROL DEVICE
JP5862045B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
JP5987415B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
JP5760705B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
JP2012123704A (en) Control apparatus, control method of control apparatus, and program
JP5861377B2 (en) RECORDING DEVICE, RECORDING SYSTEM, AND RECORDING DEVICE CONTROL METHOD
JP2017037508A (en) Information processor, and control method of information processor
JP2013257805A (en) Control device, control method of control device, and program
JP2006044232A (en) Printing apparatus, program, and printing control method
JP5857656B2 (en) CONTROL DEVICE, CONTROL DEVICE CONTROL METHOD, AND PROGRAM
JP2014054846A (en) Control device, control method for control device, and program
JP2006076163A (en) Print controller, program, and test printing method of print controller
JPH10283426A (en) Device for issuing check and method for managing check issue
JP2013114292A (en) Control device, control method of the same and program