[go: up one dir, main page]

JP2012196887A - Printer, method of controlling the same, and program - Google Patents

Printer, method of controlling the same, and program Download PDF

Info

Publication number
JP2012196887A
JP2012196887A JP2011062545A JP2011062545A JP2012196887A JP 2012196887 A JP2012196887 A JP 2012196887A JP 2011062545 A JP2011062545 A JP 2011062545A JP 2011062545 A JP2011062545 A JP 2011062545A JP 2012196887 A JP2012196887 A JP 2012196887A
Authority
JP
Japan
Prior art keywords
printing
print
image data
unit
host computer
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.)
Withdrawn
Application number
JP2011062545A
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 JP2011062545A priority Critical patent/JP2012196887A/en
Publication of JP2012196887A publication Critical patent/JP2012196887A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

【課題】画像データの処理を高速化し、印刷動作の遅延を回避する。
【解決手段】ホストコンピューターに接続可能な印刷装置は、受信部と、記憶部と、印刷部と、制御部とを備える。受信部は、ホストコンピューターから印刷データを受信する。記憶部は、印刷データに基づいて生成された印刷画像データを格納する。印刷部は、印刷画像データに基づいて印刷媒体に印刷を実行する。制御部は、印刷データに含まれるコマンドが画像データの印刷を指示するものである場合、受信部においてホストコンピューターより前記コマンドの後に受信した前記画像データを記憶部を経由することなく印刷部へ転送し、当該画像データに基づいて印刷部に印刷を実行させる。
【選択図】図2
Image data processing is speeded up and a delay in printing operation is avoided.
A printing apparatus connectable to a host computer includes a receiving unit, a storage unit, a printing unit, and a control unit. The receiving unit receives print data from the host computer. The storage unit stores print image data generated based on the print data. The printing unit executes printing on the print medium based on the print image data. When the command included in the print data instructs printing of the image data, the control unit transfers the image data received after the command from the host computer in the receiving unit to the printing unit without going through the storage unit. Then, the printing unit is caused to execute printing based on the image data.
[Selection] Figure 2

Description

本発明は、ホストコンピューターと接続可能な印刷装置、当該印刷装置の制御方法、および当該印刷装置を制御するためのプログラムに関する。   The present invention relates to a printing apparatus connectable to a host computer, a control method for the printing apparatus, and a program for controlling the printing apparatus.

店舗等に設置され、ホストコンピューターの制御の下にレシート等を発行する印刷装置が知られている(例えば、特許文献1参照)。   A printing apparatus that is installed in a store or the like and issues a receipt or the like under the control of a host computer is known (for example, see Patent Document 1).

特開2009−157474号公報JP 2009-157474 A

ホストコンピューターから受信したコマンドや印刷データに基づいて印刷ヘッドが印刷動作を実行するためのデータ(本明細書においては、このデータを印刷画像データと称する)を生成する必要がある。上記の印刷装置においては、ホストコンピューターから受信した印刷データが多量の画像データを含む場合、処理に比較的時間を要するために印刷動作の遅延が生ずる。   Based on commands and print data received from the host computer, it is necessary to generate data for the print head to execute a print operation (this data is referred to as print image data in this specification). In the printing apparatus described above, when the print data received from the host computer includes a large amount of image data, the processing takes a relatively long time, so that the printing operation is delayed.

本発明は上記課題の少なくとも一部を解決するためになされたものであり、画像データの処理を高速化し、もって印刷動作の遅延を回避することを目的とする。   The present invention has been made to solve at least a part of the above-described problems, and an object of the present invention is to speed up the processing of image data and thereby avoid a delay in a printing operation.

上記課題の少なくとも一部を解決するため、本発明は以下に列挙する種々の態様を採り得る。   In order to solve at least a part of the above-described problems, the present invention can take various modes listed below.

本発明の第1の態様は、ホストコンピューターに接続可能な印刷装置を提供する。本発明の第1の態様は、前記ホストコンピューターから印刷データを受信する受信部と、前記印刷データに基づいて生成された印刷画像データを格納する記憶部と、前記印刷画像データに基づいて印刷媒体に印刷を実行する印刷部と、前記印刷データに含まれるコマンドが画像データの印刷を指示するものである場合、前記受信部において前記ホストコンピューターより前記コマンドの後に受信した前記画像データを前記記憶部を経由することなく前記印刷部へ転送し、当該画像データに基づいて前記印刷部に印刷を実行させる制御部と、を備えることを特徴とする。   A first aspect of the present invention provides a printing apparatus that can be connected to a host computer. A first aspect of the present invention includes a receiving unit that receives print data from the host computer, a storage unit that stores print image data generated based on the print data, and a print medium based on the print image data And when the command included in the print data instructs printing of image data, the storage unit receives the image data received after the command from the host computer in the receiving unit. And a control unit that transfers the image data to the printing unit without passing through and causes the printing unit to execute printing based on the image data.

このような構成によれば、ホストコンピューターより送信された画像データは、印刷画像データの生成や記憶部への格納といった処理を経ることなく、直接受信部から印刷部へ供給されるため、処理時間の短縮を図ることができる。したがって印刷動作の遅延回避が可能である。   According to such a configuration, the image data transmitted from the host computer is supplied directly from the receiving unit to the printing unit without undergoing processing such as generation of print image data or storage in the storage unit, so that processing time is increased. Can be shortened. Therefore, it is possible to avoid a delay in the printing operation.

一般に印刷装置は、受信した画像データを揮発性メモリー(RAM等)などのレジスタや受信バッファーに格納した後、揮発性メモリーなどのプリントバッファーに記憶する。本発明では、画像データが印刷部で印刷を実行可能なデータ形式に置き換えし易いという特徴に着目し、レジスタや受信バッファーといった受信部から直接印刷部へ画像データを転送して印刷を実行している。画像データは多量になる場合が多いので、バッファー間の転送処理の省略効果が顕著となり、処理を大幅に効率化できる。   Generally, a printing apparatus stores received image data in a register such as a volatile memory (RAM or the like) or a reception buffer, and then stores it in a print buffer such as a volatile memory. In the present invention, paying attention to the feature that image data can be easily replaced with a data format that can be printed by the printing unit, printing is performed by transferring the image data directly from the receiving unit such as a register or a reception buffer to the printing unit. Yes. Since the amount of image data is often large, the effect of omitting the transfer process between the buffers becomes remarkable, and the process can be greatly improved in efficiency.

本発明の第1の態様において、ダイレクトメモリーアクセスコントローラーを更に備え、前記制御部は、前記ダイレクトメモリーアクセスコントローラーに前記画像データを前記受信部より前記印刷部へ転送させることを特徴とする。   In the first aspect of the present invention, a direct memory access controller is further provided, and the control unit causes the direct memory access controller to transfer the image data from the receiving unit to the printing unit.

このような構成とすれば、制御部の処理負荷が軽減される。したがって更なる印刷動作の高速化を図ることができる。   With such a configuration, the processing load on the control unit is reduced. Therefore, the printing operation can be further speeded up.

本発明の第1の態様において、前記制御部は、前記コマンドに含まれる引数に応じて前記ダイレクトメモリーアクセスコントローラーによる転送を有効化または無効化可能であることを特徴とする。   In the first aspect of the present invention, the control unit can enable or disable transfer by the direct memory access controller according to an argument included in the command.

このような構成によれば、画像データの受信部から印刷部への転送を制御部とダイレクトメモリーアクセスコントローラーの何れが実行するかを、画像データの数や密度を示す引数に応じて切替えることが可能となる。画像データの数や密度が少ない場合は、ダイレクトメモリーアクセスコントローラーの設定に要する時間の影響の方が転送時間よりも相対的に大きい傾向にある。このような場合、制御部により制御を実行した方が処理が速くなることがあるため、印刷データの内容や印刷装置の状態に応じた効率的な印刷制御が可能となる。   According to such a configuration, it is possible to switch which of the control unit and the direct memory access controller executes transfer of image data from the receiving unit to the printing unit according to an argument indicating the number or density of the image data. It becomes possible. When the number and density of image data are small, the influence of the time required for setting the direct memory access controller tends to be relatively larger than the transfer time. In such a case, since the process may be faster when the control is executed by the control unit, efficient print control according to the contents of the print data and the state of the printing apparatus is possible.

本発明の第1の態様において、前記印刷データに含まれるコマンドが文字印刷を指示するものである場合、前記制御部は、前記受信部において前記ホストコンピューターより受信した文字コードに基づいて前記印刷画像データを生成することを特徴とする。   In the first aspect of the present invention, when the command included in the print data is an instruction to print characters, the control unit is configured to print the print image based on a character code received from the host computer by the receiving unit. It is characterized by generating data.

このような構成によれば、処理負荷が比較的低い文字データの処理と処理負荷が比較的高い画像データの処理を区別することによって効率的な印刷処理を実行可能である。   According to such a configuration, efficient printing processing can be executed by distinguishing between processing of character data with a relatively low processing load and processing of image data with a relatively high processing load.

本発明の第2の態様は、ホストコンピューターから印刷データを受信する受信部と、前記印刷データに基づいて生成された印刷画像データを格納する記憶部と、前記印刷画像データに基づいて印刷媒体に印刷を実行する印刷部とを備える印刷装置の制御方法を提供する。本発明の第2の態様は、前記印刷データに含まれるコマンドが画像データの印刷を指示するものである場合、前記受信部において前記ホストコンピューターより前記コマンドの後に受信した前記画像データを前記記憶部を経由することなく前記印刷部へ転送し、前記画像データに基づいて前記印刷部に印刷を実行させる、ことを特徴とする。
このような構成によれば、本発明の第1の態様と同様の効果を得ることができる。
According to a second aspect of the present invention, a receiving unit that receives print data from a host computer, a storage unit that stores print image data generated based on the print data, and a print medium based on the print image data A control method of a printing apparatus including a printing unit that executes printing is provided. According to a second aspect of the present invention, when the command included in the print data instructs printing of image data, the storage unit stores the image data received after the command from the host computer in the reception unit. The image data is transferred to the printing unit without going through the process, and the printing unit is caused to execute printing based on the image data.
According to such a configuration, an effect similar to that of the first aspect of the present invention can be obtained.

本発明は、上記第2の態様に係る印刷装置の制御方法を、印刷装置が備える制御部に実行させることを特徴とするプログラムとしても実現され得る。   The present invention can also be realized as a program that causes a control unit included in a printing apparatus to execute the method for controlling the printing apparatus according to the second aspect.

本発明の第1実施形態に係る印刷装置のシステム構成を示すブロック図である。1 is a block diagram illustrating a system configuration of a printing apparatus according to a first embodiment of the present invention. 図1の印刷装置の制御方法を示すフローチャートである。3 is a flowchart illustrating a control method of the printing apparatus in FIG. 1. 本発明の第2実施形態に係る印刷装置のシステム構成を示すブロック図である。It is a block diagram which shows the system configuration | structure of the printing apparatus which concerns on 2nd Embodiment of this invention. 図3の印刷装置の制御方法を示すフローチャートである。4 is a flowchart illustrating a control method of the printing apparatus in FIG. 3. 図3の印刷装置の制御方法の別例を示すフローチャートである。4 is a flowchart illustrating another example of the control method of the printing apparatus in FIG. 3.

本発明に係る印刷装置について添付の図面を参照しつつ以下詳細に説明する。POSシステム等に用いられるサーマルラインプリンターを印刷装置の例に挙げる。POSシステムは、小売店等に設置されて売上げ精算を行なうPOS端末を、売上げ登録処理および精算処理を行なうホストコンピューターに接続して構成される。本発明に係る印刷装置はPOS端末に備えられ、売上げ精算の際にレシートを印刷・発行するために用いられる。   A printing apparatus according to the present invention will be described below in detail with reference to the accompanying drawings. An example of a printing apparatus is a thermal line printer used for a POS system or the like. The POS system is configured by connecting a POS terminal installed at a retail store or the like and performing sales settlement to a host computer that performs sales registration processing and settlement processing. The printing apparatus according to the present invention is provided in a POS terminal, and is used for printing / issuing a receipt at the time of sales settlement.

図1に本発明の第1実施形態に係る印刷装置2を示す。印刷装置2は、ホストコンピューター1に接続可能であり、印刷制御部10および印刷部13を備えている。   FIG. 1 shows a printing apparatus 2 according to the first embodiment of the present invention. The printing apparatus 2 can be connected to the host computer 1 and includes a printing control unit 10 and a printing unit 13.

印刷制御部10は、CPU(中央制御装置)および各種周辺回路より構成される制御部11を備えている。制御部11は、後述する不揮発性メモリー16あるいは不図示のROM(読み出し専用メモリー)に記憶された制御プログラム等の各種プログラムを実行することにより、印刷装置2の各部を統括的に制御する。   The print control unit 10 includes a control unit 11 including a CPU (central control device) and various peripheral circuits. The control unit 11 comprehensively controls each unit of the printing apparatus 2 by executing various programs such as a control program stored in a non-volatile memory 16 (not shown) or a ROM (read only memory) (not shown).

印刷部13は、不図示の媒体搬送機構、印刷ヘッド、およびヘッド駆動回路を備えている。媒体搬送機構は、制御部11の制御の下に、印刷装置2に収容された印刷媒体としてのロール紙の先端部を所定の搬送経路に沿って印刷ヘッドへ向けて搬送する。本実施形態の印刷ヘッドは、複数の発熱素子が印刷媒体の搬送方向に直交する向きに配列されたサーマルラインヘッドである。制御部11の制御の下に発熱素子(ドット形成素子)がロール紙の表面(記録面)に熱を与えることにより、ロール紙上に文字や画像が印刷(記録)される。印刷ヘッドを通過したロール紙の先端部は、不図示の切断機構により自動あるいは手動で切断され、レシートとして顧客に手渡される。   The printing unit 13 includes a medium transport mechanism (not shown), a print head, and a head drive circuit. Under the control of the control unit 11, the medium transport mechanism transports the leading end portion of the roll paper as the print medium accommodated in the printing apparatus 2 toward the print head along a predetermined transport path. The print head of this embodiment is a thermal line head in which a plurality of heat generating elements are arranged in a direction orthogonal to the conveyance direction of the print medium. Under the control of the control unit 11, a heating element (dot forming element) applies heat to the surface (recording surface) of the roll paper, whereby characters and images are printed (recorded) on the roll paper. The leading end of the roll paper that has passed through the print head is cut automatically or manually by a cutting mechanism (not shown) and handed to the customer as a receipt.

本実施形態の印刷装置2は、店名、売り上げた商品の名称、数量ならびに金額、および合計金額等の文字情報に加え、店のロゴ、クーポン情報、バーコード等の画像情報をレシート上に印刷可能とされている。   The printing apparatus 2 of the present embodiment can print image information such as a store logo, coupon information, and barcode on a receipt in addition to character information such as a store name, the name of a product sold, quantity and amount, and a total amount. It is said that.

図1に示されるように、印刷制御部10は、受信部12、コマンド解析部15、不揮発性メモリー16、およびプリントバッファー17を更に備えている。各種データはこれらの構成要素間をデータバス19を介して送受信可能とされている。   As shown in FIG. 1, the print control unit 10 further includes a reception unit 12, a command analysis unit 15, a nonvolatile memory 16, and a print buffer 17. Various data can be transmitted and received between these components via the data bus 19.

受信部12は、制御部11の制御の下に、ホストコンピューター1から送信される各種コマンドやデータ等を所定規格に準拠して受信するインターフェースであり、レジスターやバッファー等から構成される。受信部12には、ホストコンピューター1から有線あるいは無線通信を通じて受信した各種コマンドやデータが一時的に格納される。受信部12の少なくとも一部は、制御部11がワークエリアの形成に利用する不図示のRAM(ランダムアクセスメモリー)における所定の記憶領域に形成される構成としてもよいし、専用のメモリーを設ける構成としてもよい。   The receiving unit 12 is an interface that receives various commands and data transmitted from the host computer 1 in accordance with a predetermined standard under the control of the control unit 11, and includes a register, a buffer, and the like. The receiving unit 12 temporarily stores various commands and data received from the host computer 1 via wired or wireless communication. At least a part of the receiving unit 12 may be formed in a predetermined storage area in a RAM (Random Access Memory) (not shown) used by the control unit 11 for forming a work area, or a dedicated memory is provided. It is good.

コマンド解析部15は、制御部11の制御の下に、受信部12に格納された各種コマンドを順次読み出して解析する。ホストコンピューター1より送信されるコマンドは、印刷する文字や画像の属性や位置を指定するコマンドや、印刷装置の機能や動作を指定するコマンド等を含んでいる。コマンド解析部15は、コマンドの内容を解析することによって印刷装置2において実行される処理を特定する。コマンド解析部15は、制御部11の一機能として実現される。当該機能を実現する専用のハードウェアまたはソフトウェアを設けてもよい。   The command analysis unit 15 sequentially reads and analyzes various commands stored in the reception unit 12 under the control of the control unit 11. The commands transmitted from the host computer 1 include commands that specify the attributes and positions of characters and images to be printed, commands that specify functions and operations of the printing apparatus, and the like. The command analysis unit 15 identifies processing to be executed in the printing apparatus 2 by analyzing the contents of the command. The command analysis unit 15 is realized as a function of the control unit 11. You may provide the hardware or software for exclusive use which implement | achieves the said function.

不揮発性メモリー16はROM等によって構成され、書替え可能に、かつ不揮発的に各種データを記憶保持する。本実施形態の不揮発性メモリー16は、レシートに印刷される各種文字の形状を定義するデータ(フォントデータ)を格納している。不揮発性メモリー16に記憶保持されるデータは、予め格納されていてもよいし、ホストコンピューター1から送信されたデータを受信部12を介して格納する構成としてもよい。   The nonvolatile memory 16 is composed of a ROM or the like, and stores and holds various data in a rewritable manner in a nonvolatile manner. The nonvolatile memory 16 of the present embodiment stores data (font data) that defines the shape of various characters printed on a receipt. The data stored and held in the nonvolatile memory 16 may be stored in advance, or the data transmitted from the host computer 1 may be stored via the receiving unit 12.

プリントバッファー17は、サーマルラインヘッドを駆動するために生成される印刷画像データを格納(展開)するための領域であり、本発明の記憶部として機能する。印刷画像データは、印刷に供される文字をラスタライズして画素データとして生成したものである。例えばドットが形成される(発熱素子を駆動する)画素は1で、ドットが形成されない(発熱素子が駆動されない)画素は0で表現される。ヘッド駆動回路は、プリントバッファー17に展開された印刷画像データに基づいて、印刷媒体の搬送タイミングを規定する信号との同期をとりつつ、発熱素子の各々に駆動信号を出力することにより、所望の文字をレシート上に印刷する。   The print buffer 17 is an area for storing (developing) print image data generated for driving the thermal line head, and functions as a storage unit of the present invention. The print image data is generated as pixel data by rasterizing characters used for printing. For example, a pixel in which a dot is formed (driving a heating element) is represented by 1, and a pixel in which no dot is formed (a heating element is not driven) is represented by 0. The head drive circuit outputs a drive signal to each of the heating elements based on the print image data developed in the print buffer 17 and outputs a drive signal to each of the heating elements while synchronizing with a signal that defines the conveyance timing of the print medium. Print characters on receipt.

上記の構成を備えた本実施形態に係る印刷装置2の動作および制御方法について、図2を参照しつつ以下説明する。   The operation and control method of the printing apparatus 2 according to the present embodiment having the above-described configuration will be described below with reference to FIG.

本実施形態においては、印刷動作が実行される場合において、先ずホストコンピューター1から印刷対象が文字列であるか画像であるかを示すコマンドが送信され、受信部12に格納される(ステップS11)。当該コマンドはコマンド解析部15による解析に供され、印刷対象が文字列であるか画像であるかが認識される(ステップS12)。具体的には、印刷対象が文字列であるか画像であるかを示す引数がコマンド中に含まれており、コマンド解析部15は当該引数を参照して印刷対象を判別する。なお特定の引数が含まれている場合に印刷対象が画像であると判定し、含まれていない場合に印刷対象が文字列であると判定する構成としてもよい。   In the present embodiment, when a printing operation is executed, first, a command indicating whether the printing target is a character string or an image is transmitted from the host computer 1 and stored in the receiving unit 12 (step S11). . The command is subjected to analysis by the command analysis unit 15, and it is recognized whether the print target is a character string or an image (step S12). Specifically, an argument indicating whether the print target is a character string or an image is included in the command, and the command analysis unit 15 determines the print target with reference to the argument. The configuration may be such that when a specific argument is included, it is determined that the print target is an image, and when it is not included, the print target is determined as a character string.

印刷対象が文字列であると判定されると(ステップS12においてNo)、制御部11は後続してホストコンピューター1から送信される文字コードの受信を待機する。文字コードが受信部12に格納されると、制御部11は当該文字コードに対応するフォントデータを不揮発性メモリー16から読み出し、文字列に対応する印刷画像データを生成する(ステップS13)。生成された印刷画像データはプリントバッファー17に展開され(ステップS14)、制御部11の制御の下に所定のタイミングで印刷部13へ転送される(ステップS15)。印刷部13は印刷画像データに基づいてサーマルラインヘッドおよび媒体搬送機構を駆動し、指定された文字列をレシート上に印刷する(ステップS16)。   If it is determined that the print target is a character string (No in step S12), the control unit 11 waits for reception of a character code transmitted from the host computer 1 thereafter. When the character code is stored in the receiving unit 12, the control unit 11 reads out font data corresponding to the character code from the nonvolatile memory 16 and generates print image data corresponding to the character string (step S13). The generated print image data is developed in the print buffer 17 (step S14), and transferred to the printing unit 13 at a predetermined timing under the control of the control unit 11 (step S15). The printing unit 13 drives the thermal line head and the medium transport mechanism based on the print image data, and prints the designated character string on the receipt (step S16).

印刷部13が一度に処理できる印刷画像データの量は、サーマルラインヘッドが備える発熱素子の数に対応する。転送された印刷画像データに基づいて印刷が実行されると、印刷媒体が所定量だけ搬送され、次の印刷画像データの供給を待つ。すなわち印刷媒体の搬送動作毎に、サーマルラインヘッドが印刷可能なドット数に対応するデータ量だけ、印刷画像データがプリントバッファー17から印刷部13へ供給される。   The amount of print image data that can be processed at one time by the printing unit 13 corresponds to the number of heating elements provided in the thermal line head. When printing is executed based on the transferred print image data, the print medium is transported by a predetermined amount and waits for the supply of the next print image data. That is, for each print medium transport operation, print image data is supplied from the print buffer 17 to the printing unit 13 in an amount corresponding to the number of dots that can be printed by the thermal line head.

印刷対象が画像であると判定されると(ステップS12においてYes)、制御部11は後続してホストコンピューター1から送信される画像データの受信を待機する。この画像データは上述の印刷画像データに相当する、すなわちサーマルラインヘッドの発熱素子の各々の駆動/非駆動を直接制御する画素データとして提供される。受信部12における画像データの受信を確認すると、制御部11は当該画像データをデータバス19を介して直接、すなわちプリントバッファー17を経由することなく印刷部13へ転送する(ステップS17)。印刷部13は、制御部11の制御の下に、供給された画像データに基づいてサーマルラインヘッドおよび媒体搬送機構を駆動し、所定の画像をレシート上に印刷する(ステップS18)。   If it is determined that the print target is an image (Yes in step S12), the control unit 11 waits for reception of image data transmitted from the host computer 1 thereafter. This image data corresponds to the above-described print image data, that is, is provided as pixel data for directly controlling the driving / non-driving of each heating element of the thermal line head. When the reception unit 12 confirms the reception of the image data, the control unit 11 transfers the image data to the printing unit 13 via the data bus 19 directly, that is, without going through the print buffer 17 (step S17). The printing unit 13 drives the thermal line head and the medium transport mechanism based on the supplied image data under the control of the control unit 11, and prints a predetermined image on the receipt (step S18).

上述のように、印刷部13が一度に処理できる画像データの量は、サーマルラインヘッドが備える発熱素子の数に対応する。したがって画像データの受信部12から印刷部13への転送は、印刷媒体の搬送動作毎にサーマルラインヘッドが印刷可能なドット数に対応するデータ量毎に行なう必要がある。このデータ量は、ホストコンピューター1より先行して送信されるコマンド中に引数として定義されており、コマンド解析部15は当該引数を参照して制御部11への通知を行なう。制御部11は引数の指定するデータ量毎に直接転送を実行する。   As described above, the amount of image data that can be processed by the printing unit 13 at a time corresponds to the number of heating elements provided in the thermal line head. Therefore, it is necessary to transfer the image data from the receiving unit 12 to the printing unit 13 for each data amount corresponding to the number of dots that can be printed by the thermal line head for each printing medium conveyance operation. This amount of data is defined as an argument in a command transmitted in advance from the host computer 1, and the command analysis unit 15 notifies the control unit 11 with reference to the argument. The control unit 11 performs direct transfer for each data amount specified by the argument.

上記の構成によれば、ホストコンピューター1より送信された画像データは、印刷画像データの生成とプリントバッファー17への格納、およびプリントバッファー17から印刷部13への転送といった処理を経ることなく、直接受信部12から印刷部13へ供給されるため、処理時間を大幅に短縮することができる。   According to the above configuration, the image data transmitted from the host computer 1 is directly transmitted without processing such as generation of print image data, storage in the print buffer 17, and transfer from the print buffer 17 to the printing unit 13. Since the data is supplied from the receiving unit 12 to the printing unit 13, the processing time can be significantly reduced.

本発明の第2実施形態に係る印刷装置22を図3に示す。第1実施形態と同一、同等もしくは同様の機能・構成を有する要素については同一の参照番号を付与し、繰り返しとなる説明は省略する。本実施形態は、印刷制御部10がDMAC(ダイレクトメモリーアクセスコントローラー)18を備えている点において第1実施形態と相違する。   A printing apparatus 22 according to a second embodiment of the present invention is shown in FIG. Elements having the same, equivalent or similar functions and configurations as in the first embodiment are given the same reference numerals, and repeated descriptions are omitted. This embodiment is different from the first embodiment in that the print control unit 10 includes a DMAC (direct memory access controller) 18.

DMAC18は、制御部11の内部あるいは外部に設けられたプロセッサーである。制御部11から所定の指示を受けるとバッファーやメモリーに直接アクセスし、データバス19を介してこれらの要素間のデータ転送を制御する。   The DMAC 18 is a processor provided inside or outside the control unit 11. When a predetermined instruction is received from the control unit 11, the buffer or memory is directly accessed, and data transfer between these elements is controlled via the data bus 19.

本実施形態に係る印刷装置22の動作および制御方法について、図4を参照しつつ説明する。図2に示した第1実施形態に係る制御方法と同一の処理については同一の参照番号を付与し、繰り返しとなる説明は省略する。すなわち文字列を印刷する際の処理については第1実施形態と同一である。   The operation and control method of the printing apparatus 22 according to the present embodiment will be described with reference to FIG. The same processes as those in the control method according to the first embodiment shown in FIG. 2 are denoted by the same reference numerals, and repeated descriptions are omitted. That is, the processing for printing a character string is the same as that in the first embodiment.

本実施形態においては、印刷対象が画像であると判定されると(ステップS12においてYes)、制御部11はDMAC18のDMA制御を有効化する。DMAC18は後続してホストコンピューター1から送信される画像データの受信を待機する。   In this embodiment, when it is determined that the print target is an image (Yes in step S12), the control unit 11 validates the DMA control of the DMAC 18. The DMAC 18 then waits for reception of image data transmitted from the host computer 1.

DMAC18は受信部12に直接アクセス(ダイレクトメモリーアクセス)して画像データの受信を確認すると、当該画像データをデータバス19を介して直接、すなわちプリントバッファー17を経由することなく印刷部13へDMA転送する(ステップS27)。印刷部13は、制御部11の制御の下に、供給された画像データに基づいてサーマルラインヘッドおよび媒体搬送機構を駆動し、所定の画像をレシート上に印刷する(ステップS18)。   When the DMAC 18 directly accesses the receiving unit 12 (direct memory access) and confirms reception of the image data, the DMAC 18 DMA-transfers the image data directly to the printing unit 13 via the data bus 19, that is, without going through the print buffer 17. (Step S27). The printing unit 13 drives the thermal line head and the medium transport mechanism based on the supplied image data under the control of the control unit 11, and prints a predetermined image on the receipt (step S18).

上記の構成によれば、ホストコンピューター1より送信された画像データは、印刷画像データの生成とプリントバッファー17への格納、およびプリントバッファー17から印刷部13への転送といった処理を経ることなく、直接受信部12から印刷部13へ供給されるため、処理時間を大幅に短縮することができる。またDMAC18による画像データの印刷部13への供給はDMA制御によって行なわれるため、制御部11の処理負荷が軽減される。したがって更なる印刷動作の高速化を図ることができる。   According to the above configuration, the image data transmitted from the host computer 1 is directly transmitted without processing such as generation of print image data, storage in the print buffer 17, and transfer from the print buffer 17 to the printing unit 13. Since the data is supplied from the receiving unit 12 to the printing unit 13, the processing time can be significantly reduced. Further, since the DMAC 18 supplies the image data to the printing unit 13 by DMA control, the processing load on the control unit 11 is reduced. Therefore, the printing operation can be further speeded up.

上述のように、画像データの受信部12から印刷部13への転送は、印刷媒体の搬送動作毎にサーマルラインヘッドが印刷可能なドット数に対応するデータ量毎に行なう必要がある。このデータ量は、ホストコンピューター1より先行して送信されるコマンド中に引数として定義されており、コマンド解析部15は当該引数を参照して制御部11への通知を行なう。制御部11は引数の指定するデータ量毎にDMA転送を実行するようにDMAC18へ指示を行なう。   As described above, it is necessary to transfer the image data from the receiving unit 12 to the printing unit 13 for each data amount corresponding to the number of dots that can be printed by the thermal line head for each printing medium transport operation. This amount of data is defined as an argument in a command transmitted in advance from the host computer 1, and the command analysis unit 15 notifies the control unit 11 with reference to the argument. The control unit 11 instructs the DMAC 18 to execute DMA transfer for each data amount designated by the argument.

なおDMA制御の有効/無効を示す引数をホストコンピューター1より先行して送信されるコマンドに含め、当該引数をコマンド解析部15が参照する構成としてもよい。この場合、画像データの受信部12から印刷部13への転送を制御部11とDMAC18の何れが実行するかを、画像データの数や密度を示す引数に応じて切替えることが可能となる。したがって状況に応じた高速印刷動作の維持が可能となる。例えば画像データの数や密度が少ない場合は、DMAC18の設定に要する時間の影響の方が転送時間よりも相対的に大きい傾向にある。このような場合、制御部により制御を実行した方が処理が速くなることがあるため、印刷データの内容や印刷装置の状態に応じた効率的な印刷制御が可能となる。   Note that an argument indicating validity / invalidity of DMA control may be included in a command transmitted in advance from the host computer 1, and the argument may be referred to by the command analysis unit 15. In this case, it is possible to switch which of the control unit 11 and the DMAC 18 executes transfer of image data from the receiving unit 12 to the printing unit 13 according to an argument indicating the number or density of image data. Therefore, it is possible to maintain a high-speed printing operation according to the situation. For example, when the number and density of image data are small, the influence of the time required for setting the DMAC 18 tends to be relatively larger than the transfer time. In such a case, since the process may be faster when the control is executed by the control unit, efficient print control according to the contents of the print data and the state of the printing apparatus is possible.

この例における印刷装置22の制御方法について、図5を参照しつつ説明する。図4に示した第2実施形態に係る制御方法と同一の処理については同一の参照番号を付与し、繰り返しとなる説明は省略する。   A control method of the printing apparatus 22 in this example will be described with reference to FIG. The same processes as those in the control method according to the second embodiment shown in FIG. 4 are given the same reference numerals, and repeated descriptions are omitted.

この例においては、印刷対象が画像であると判定されると(ステップS12においてYes)、ホストコンピューター1より送信されたコマンドに含まれているDMA制御の有効/無効を示す引数がコマンド解析部15によって参照され、DMA制御の有効化が指示されているかを判定する(ステップS30)。   In this example, when it is determined that the print target is an image (Yes in step S12), an argument indicating the validity / invalidity of DMA control included in the command transmitted from the host computer 1 is the command analysis unit 15. To determine whether or not the DMA control is instructed (step S30).

DMA制御の有効化が指示されていると判定されると(ステップS30においてYes)、制御部11がDMAC18のDMA制御を有効化する。第2実施形態と同様にして、受信部12において受信された画像データをDMAC18が印刷部13へDMA転送する(ステップS27)。   If it is determined that DMA control activation is instructed (Yes in step S30), the control unit 11 validates the DMA control of the DMAC 18. As in the second embodiment, the DMAC 18 DMA-transfers the image data received by the receiving unit 12 to the printing unit 13 (step S27).

DMA制御の無効化が指示されていると判定されると(ステップS30においてNo)、第1実施形態と同様にして、受信部12において受信された画像データを制御部11が印刷部13へ転送する(ステップS17)。バス分割制御等を利用すれば、制御部11による転送処理中にDMAC18は別のタスクへの対応が可能であり、より効率的な制御処理が可能となる。   If it is determined that the DMA control invalidation is instructed (No in step S30), the control unit 11 transfers the image data received by the receiving unit 12 to the printing unit 13 as in the first embodiment. (Step S17). If bus division control or the like is used, the DMAC 18 can cope with another task during the transfer processing by the control unit 11, and more efficient control processing is possible.

上記各実施形態において、印刷制御部10が実行する制御の少なくとも一部は、DMAC18やホストコンピューター1にインストールされたプリンタドライバが備えるソフトウェアによって実現されてもよい。   In each of the above embodiments, at least a part of the control executed by the print control unit 10 may be realized by software included in the DMAC 18 or a printer driver installed in the host computer 1.

本発明に係る印刷装置の制御方法は、印刷媒体として単票紙を用いるページプリンターにも適用可能である。文書の各ページにおけるヘッダーやフッターに画像の印刷が必要な場合において、処理負荷の軽減と印刷動作の遅延回避が期待できる。   The control method of the printing apparatus according to the present invention is also applicable to a page printer that uses a cut sheet as a print medium. When it is necessary to print an image on the header or footer of each page of the document, it is possible to reduce the processing load and avoid the delay of the printing operation.

本発明に係る印刷装置の制御方法は、印刷媒体の搬送方向に配列された複数の発熱素子を備えるサーマルヘッドがキャリッジに搭載され、当該キャリッジを印刷媒体の搬送方向に直交する向きに走査しながら印刷を行なうシリアルプリンターにも適用可能である。この場合においても、印刷部13が一度に処理できる画像データの量は、サーマルヘッドが備える発熱素子の数に対応する。転送された画像データに基づいて印刷が実行されると、キャリッジが所定量だけ走査され、次の画像データの供給を待つ。すなわちキャリッジの単位量走査毎にサーマルヘッドが印刷可能なドット数に対応するデータ量だけ、画像データがプリントバッファー17から印刷部13へ供給される。このデータ量をホストコンピューター1から先行して送信されるコマンドに含まれる引数で定義すればよい。   In the printing apparatus control method according to the present invention, a thermal head including a plurality of heating elements arranged in a print medium conveyance direction is mounted on a carriage, and the carriage is scanned in a direction perpendicular to the print medium conveyance direction. It is also applicable to serial printers that perform printing. Even in this case, the amount of image data that can be processed by the printing unit 13 at a time corresponds to the number of heating elements included in the thermal head. When printing is executed based on the transferred image data, the carriage is scanned by a predetermined amount and waits for the supply of the next image data. That is, image data is supplied from the print buffer 17 to the printing unit 13 by a data amount corresponding to the number of dots that can be printed by the thermal head for each unit scan of the carriage. This amount of data may be defined by an argument included in a command transmitted in advance from the host computer 1.

本発明に係る印刷装置の駆動方法は、インクジェット方式、ドットインパクト方式の印刷ヘッドを備えるプリンターにも適用可能である。画像データもしくは印刷画像データを構成する各画素データは、インクジェット方式のプリンターにおいてはインク滴の噴射/非噴射を規定するものとなり、ドットインパクト方式のプリンターにおいてはニードルの駆動/非駆動を規定するものとなる。何れの方式においても前述のデータ構成に基づいてライン方式のヘッドとシリアル方式のヘッドの双方について適用可能である。   The driving method of the printing apparatus according to the present invention can also be applied to a printer including an ink jet type or dot impact type print head. Each pixel data constituting the image data or the print image data defines ejection / non-ejection of ink droplets in an ink jet type printer, and defines driving / non-driving of a needle in a dot impact type printer. It becomes. Any of these methods can be applied to both a line-type head and a serial-type head based on the above-described data configuration.

上記した発明の実施の形態は、本発明の理解を容易にするためのものであり、本発明を限定するものではない。本発明は、その趣旨並びに特許請求の範囲を逸脱することなく、変更、改良され得ると共に、本発明にはその等価物が含まれる。   The above-described embodiments of the present invention are intended to facilitate understanding of the present invention, and do not limit the present invention. The present invention can be changed and improved without departing from the spirit and scope of the claims, and equivalents thereof are included in the present invention.

1:ホストコンピューター、2:印刷装置、11:制御部、12:受信部、13:印刷部、15:コマンド解析部(制御部)、17:プリントバッファー(記憶部)、18:DMAC   1: host computer, 2: printing device, 11: control unit, 12: reception unit, 13: printing unit, 15: command analysis unit (control unit), 17: print buffer (storage unit), 18: DMAC

Claims (6)

ホストコンピューターに接続可能な印刷装置であって、
前記ホストコンピューターから印刷データを受信する受信部と、
前記印刷データに基づいて生成された印刷画像データを格納する記憶部と、
前記印刷画像データに基づいて印刷媒体に印刷を実行する印刷部と、
前記印刷データに含まれるコマンドが画像データの印刷を指示するものである場合、前記受信部において前記ホストコンピューターより前記コマンドの後に受信した前記画像データを前記記憶部を経由することなく前記印刷部へ転送し、当該画像データに基づいて前記印刷部に印刷を実行させる制御部と、
を備えることを特徴とする印刷装置。
A printing device connectable to a host computer,
A receiving unit for receiving print data from the host computer;
A storage unit for storing print image data generated based on the print data;
A printing unit that executes printing on a print medium based on the print image data;
When the command included in the print data is an instruction to print image data, the image data received after the command from the host computer in the receiving unit is sent to the printing unit without going through the storage unit. A control unit for transferring and causing the printing unit to execute printing based on the image data;
A printing apparatus comprising:
ダイレクトメモリーアクセスコントローラーを更に備え、
前記制御部は、前記ダイレクトメモリーアクセスコントローラーに前記画像データを前記受信部より前記印刷部へ転送させることを特徴とする請求項1に記載の印刷装置。
Further equipped with a direct memory access controller,
The printing apparatus according to claim 1, wherein the control unit causes the direct memory access controller to transfer the image data from the receiving unit to the printing unit.
前記制御部は、前記コマンドに含まれる引数に応じて前記ダイレクトメモリーアクセスコントローラーによる転送を有効化または無効化可能であることを特徴とする請求項2に記載の印刷装置。   The printing apparatus according to claim 2, wherein the control unit can enable or disable transfer by the direct memory access controller according to an argument included in the command. 前記印刷データに含まれるコマンドが文字印刷を指示するものである場合、前記制御部は、前記受信部において前記ホストコンピューターより受信した文字コードに基づいて前記印刷画像データを生成することを特徴とする請求項1から3のいずれか一項に記載の印刷装置。   When the command included in the print data is an instruction to print characters, the control unit generates the print image data based on the character code received from the host computer in the receiving unit. The printing apparatus according to any one of claims 1 to 3. ホストコンピューターから印刷データを受信する受信部と、前記印刷データに基づいて生成された印刷画像データを格納する記憶部と、前記印刷画像データに基づいて印刷媒体に印刷を実行する印刷部とを備える印刷装置の制御方法であって、
前記印刷データに含まれるコマンドが画像データの印刷を指示するものである場合、前記受信部において前記ホストコンピューターより前記コマンドの後に受信した前記画像データを前記記憶部を経由することなく前記印刷部へ転送し、
前記画像データに基づいて前記印刷部に印刷を実行させる、
ことを特徴とする印刷装置の制御方法。
A receiving unit that receives print data from a host computer, a storage unit that stores print image data generated based on the print data, and a printing unit that executes printing on a print medium based on the print image data A method for controlling a printing apparatus,
When the command included in the print data is an instruction to print image data, the image data received after the command from the host computer in the receiving unit is sent to the printing unit without going through the storage unit. Forward,
Causing the printing unit to execute printing based on the image data;
A control method for a printing apparatus.
請求項5に記載の印刷装置の制御方法を、印刷装置が備える制御部に実行させることを特徴とするプログラム。   A program for causing a control unit included in a printing apparatus to execute the method for controlling the printing apparatus according to claim 5.
JP2011062545A 2011-03-22 2011-03-22 Printer, method of controlling the same, and program Withdrawn JP2012196887A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011062545A JP2012196887A (en) 2011-03-22 2011-03-22 Printer, method of controlling the same, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011062545A JP2012196887A (en) 2011-03-22 2011-03-22 Printer, method of controlling the same, and program

Publications (1)

Publication Number Publication Date
JP2012196887A true JP2012196887A (en) 2012-10-18

Family

ID=47179599

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011062545A Withdrawn JP2012196887A (en) 2011-03-22 2011-03-22 Printer, method of controlling the same, and program

Country Status (1)

Country Link
JP (1) JP2012196887A (en)

Similar Documents

Publication Publication Date Title
US9324011B2 (en) Processing apparatus and processing method for processing print jobs
US9001171B2 (en) Double-sided receipt printing method and double-sided receipt printer
US10046577B2 (en) Printing device, printing system, and control method of a printing device
JP2007038557A (en) Printing apparatus control method, printing apparatus, and program
US9387693B2 (en) Two-sided receipt printing method, two-sided receipt printing device, and recording medium storing a program executed by a control unit that controls a two-sided receipt printing device
JP2012196887A (en) Printer, method of controlling the same, and program
JP2012113608A (en) Control device, recording system, control method of control device, and program
US20230014534A1 (en) Printing system and printing method
JP2012196886A (en) Printer, method of controlling the same, and program
JP2013230662A (en) Recording control device, recording device and control method of recording device
JP2024013936A (en) Image forming apparatus, image forming apparatus control method, and program
JP5760705B2 (en) RECORDING DEVICE, RECORDING DEVICE CONTROL METHOD, AND PROGRAM
US20190210377A1 (en) Printer and printer system
JP6682865B2 (en) Printing apparatus and printing apparatus control method
JP2001219566A (en) Printer host, storage medium storing its operation program, and ink jet printer
JP2015219683A (en) Printing apparatus and printing apparatus control method
JP5786394B2 (en) Printing apparatus, printing system, printing method, and program
JP5842351B2 (en) Printing apparatus, printing system, printing method, and program
JP2011084027A (en) Recording device, control method of recording device, and program
JP2025034889A (en) Recording device, control method, storage medium, and program
JP6680118B2 (en) Printing device and control method
JP2001277645A (en) Print control method for inkjet printer
JP2008023961A (en) Printer, printer control method, and network system
JP2020049705A (en) Image formation apparatus, image formation method and program
JP2001096835A (en) Printing system, printing apparatus, printing method, and recording medium

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20140603