JPH09114609A - Printer - Google Patents

Printer

Info

Publication number
JPH09114609A
JPH09114609A JP7293673A JP29367395A JPH09114609A JP H09114609 A JPH09114609 A JP H09114609A JP 7293673 A JP7293673 A JP 7293673A JP 29367395 A JP29367395 A JP 29367395A JP H09114609 A JPH09114609 A JP H09114609A
Authority
JP
Japan
Prior art keywords
host
size
data
buffer
communication
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
JP7293673A
Other languages
Japanese (ja)
Inventor
Takashi Morita
隆司 森田
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.)
Ricoh Co Ltd
Original Assignee
Ricoh Co Ltd
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 Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP7293673A priority Critical patent/JPH09114609A/en
Publication of JPH09114609A publication Critical patent/JPH09114609A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To automatically set the optimum size of a reception butter. SOLUTION: A CPU 2 adjusts the size of the reception butter 9 based on whether host I/Fs 6-8 perform bidirectional communication or the communication of only a reception direction in the case of receiving data from host machines 21-25 through the host I/Fs 6-8. Also, based on the kind of the protocol of the host machines 21-25 and an operated emulation program, the size of the reception buffer 9 is adjusted.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【発明の属する技術分野】本発明は、ホスト装置からの
印刷データに基づいて印刷を行うプリンタに関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a printer that prints based on print data from a host device.

【0002】[0002]

【従来の技術】一般に、ホスト装置からプリンタに対し
て送られてくる印刷データは、文字コード、イメージデ
ータ、制御コマンド等の種類が有る。また、プリンタと
ホスト装置間の通信手段が双方向の通信が可能であり、
且つプリンタ側で問い合わせコマンドをサポートしてい
る場合には、ホスト装置からプリンタに対して種々の情
報をこの問い合わせコマンドにより問い合わせる場合が
ある。この問い合わせコマンドに対してプリンタは、該
当する情報を通信手段を介して返答する。
2. Description of the Related Art Generally, print data sent from a host device to a printer has various types such as character codes, image data, and control commands. In addition, the communication means between the printer and the host device is capable of bidirectional communication,
When the printer supports the inquiry command, the host device may inquire various information to the printer by the inquiry command. In response to this inquiry command, the printer returns the corresponding information via the communication means.

【0003】また、プリンタにおいてホストから受信し
たデータはコマンド解釈部(エミュレーション・プログ
ラム)で処理する前に、一旦受信バッファに蓄積され
る。この受信バッファは両者の通信速度とコマンド解析
部の処理速度の差のために、両者の処理が円滑に進むよ
うにダムのような役目を有し、また、この受信バッファ
の容量が大きい場合には、インタプリタ側の処理を待た
ずにホストからデータを受信してこの受信バッファに記
憶することができるので、ホスト側の処理が早く完了す
るというメリットがある。
Data received from the host in the printer is temporarily stored in the reception buffer before being processed by the command interpreter (emulation program). This receive buffer has a dumb-like role so that both processes can proceed smoothly due to the difference between the communication speed of the two and the processing speed of the command analysis unit. Also, when the capacity of this receive buffer is large, Can receive data from the host and store it in this reception buffer without waiting for processing on the interpreter side, which has the advantage of completing the processing on the host side quickly.

【0004】[0004]

【発明が解決しようとする課題】ところで、この受信バ
ッファの容量が大きい場合、ホスト装置がプリンタに対
して問い合わせコマンドを送った時に、未だコマンド解
析部により処理されていない大量のデータが受信バッフ
ァに残っている可能性がある。したがって、この場合に
は問い合わせコマンドに対するプリンタからホスト装置
への応答は、この問い合わせコマンドの前の全ての受信
データを処理した後になるので、中々ホスト装置にはさ
れない状態となり、この状態になるとホスト装置によっ
てはタイムアウト監視を行っていてエラーとなるという
問題点がある。
If the capacity of the reception buffer is large, when the host device sends an inquiry command to the printer, a large amount of data that has not been processed by the command analysis unit is stored in the reception buffer. It may remain. Therefore, in this case, since the response from the printer to the host device in response to the inquiry command comes after processing all the received data before this inquiry command, it is in a state in which the host device is not processed so much in this state. Depending on the situation, there is a problem that an error occurs due to timeout monitoring.

【0005】なお、このような問題を解決するためにユ
ーザが受信バッファの大きさをオペレーションパネルか
ら設定可能にしたものも知られているが、このような構
成では複数のホストI/Fを接続している場合や、ネッ
トワーク等を介して複数のホスト装置を共有している場
合には、ユーザにとって使用前に受信バッファの最適な
大きさを確認したり、設定しなおす作業が煩わしいとい
う問題点がある。
In order to solve such a problem, it is known that the user can set the size of the reception buffer from the operation panel. In such a configuration, a plurality of host I / Fs are connected. When using multiple host devices via a network or the like, it is troublesome for the user to check the optimal size of the receive buffer before using it and to reset it. There is.

【0006】本発明は上記従来の問題点に鑑み、受信バ
ッファの最適な大きさを自動的に設定することができる
プリンタを提供することを目的とする。
In view of the above conventional problems, it is an object of the present invention to provide a printer capable of automatically setting the optimum size of the reception buffer.

【0007】[0007]

【課題を解決するための手段】本発明は上記目的を達成
するために、複数のホスト装置との間で双方向通信又は
受信方向のみの通信をそれぞれ行うことによりホスト装
置からのデータを受信する複数のインタフェースと、前
記インタフェースを介して受信したデータを一時記憶す
るための受信バッファと、データを受信したインタフェ
ースが双方向通信を行うか、又は受信方向のみの通信を
行うかに基づいて前記受信バッファの大きさを調整する
手段とを有することを特徴とする。
In order to achieve the above object, the present invention receives data from a host device by performing bidirectional communication or communication only in the receiving direction with a plurality of host devices. The reception based on a plurality of interfaces, a reception buffer for temporarily storing data received via the interfaces, and whether the interface receiving the data performs bidirectional communication or communication in the reception direction only. And a means for adjusting the size of the buffer.

【0008】本発明はまた、複数のホスト装置との間で
双方向通信又は受信方向のみの通信をそれぞれ行うこと
によりホスト装置からのデータを受信する複数のインタ
フェースと、前記インタフェースを介して受信したデー
タを一時記憶するための受信バッファと、データを受信
した相手先ホスト装置のプロトコルの種類に基づいて前
記受信バッファの大きさを調整する手段とを有すること
を特徴とする。
The present invention also provides a plurality of interfaces for receiving data from the host device by performing bidirectional communication or communication only in the receiving direction with the plurality of host devices, and the reception via the interfaces. It is characterized by having a receiving buffer for temporarily storing data and means for adjusting the size of the receiving buffer based on the type of protocol of the destination host device which received the data.

【0009】本発明はまた、複数のホスト装置との間で
双方向通信又は受信方向のみの通信をそれぞれ行うこと
によりホスト装置からのデータを受信する複数のインタ
フェースと、前記インタフェースを介して受信したデー
タを一時記憶するための受信バッファと、複数の相手先
ホスト装置のコマンドをそれぞれ解釈する複数のコマン
ド解釈手段と、データを受信した場合にどのコマンド解
釈手段が動作しているかに基づいて前記受信バッファの
大きさを調整する手段とを有することを特徴とする。
The present invention also provides a plurality of interfaces for receiving data from the host device by performing bidirectional communication or communication only in the receiving direction with the plurality of host devices, and the reception via the interfaces. A receiving buffer for temporarily storing data, a plurality of command interpreting means for interpreting commands of a plurality of destination host devices, and the receiving operation based on which command interpreting means is operating when receiving the data. And a means for adjusting the size of the buffer.

【0010】[0010]

【実施例】以下、図面を参照して本発明の実施例を説明
する。図1は本発明に係るプリンタの一実施例としてレ
ーザビームプリンタの画像処理部(コントローラ)を示
すブロック図、図2はホストマシンから送られてくる印
刷データが印刷されるまでの手順を示す説明図、図3は
図1のホストバッファの管理情報を示す説明図、図4は
通信方向に基づいてバッファサイズを変更する処理を説
明するためのフローチャート、図5は相手先プロトコル
に基づいてバッファサイズを変更する処理を説明するた
めのフローチャート、図6はエミュレーションプログラ
ムに基づいてバッファサイズを変更する処理を説明する
ためのフローチャートである。
Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram showing an image processing unit (controller) of a laser beam printer as one embodiment of a printer according to the present invention, and FIG. 2 is an explanation showing a procedure until print data sent from a host machine is printed. 3, FIG. 3 is an explanatory diagram showing the management information of the host buffer of FIG. 1, FIG. 4 is a flowchart for explaining the process of changing the buffer size based on the communication direction, and FIG. 5 is a buffer size based on the partner protocol. Is a flowchart for explaining the processing for changing the buffer size, and FIG. 6 is a flowchart for explaining the processing for changing the buffer size based on the emulation program.

【0011】図1において、CPU2はコントローラ1
全体を制御し、このCPU2を動作させるための命令
と、プリントコマンドを解釈して印刷画像データに変換
するためのエミュレーションプログラム等はプログラム
ROM3に格納されている。RAM4は一時的な情報な
どを格納するためのワークエリアなどを有するメモリで
あり、フォントROM5は文字画像情報を格納するため
のメモリである。
In FIG. 1, the CPU 2 is a controller 1
An instruction for controlling the whole and operating the CPU 2, an emulation program for interpreting the print command and converting it into print image data, and the like are stored in the program ROM 3. The RAM 4 is a memory having a work area for storing temporary information and the like, and the font ROM 5 is a memory for storing character image information.

【0012】ホストI/F6〜8はホストマシン21〜
25との間で通信を行うためのインタフェース部であ
り、この例ではホストI/F6はホストマシン21との
間で単方向通信を行うセントロニクスI/Fであり、ホ
ストI/F7はホストマシン22との間で双方向通信が
可能なRS232CI/Fであり、ホストI/F8はホ
ストマシン23〜25との間でネットワーク26を介し
て通信を行うネットワークI/Fである。ホストバッフ
ァ9はホストマシン21〜25から受信したデータを一
時記憶するための受信バッファである。
The host I / Fs 6 to 8 are host machines 21 to 21.
The host I / F 6 is a Centronics I / F that performs unidirectional communication with the host machine 21, and the host I / F 7 is a host machine 22 in this example. Is a RS232C I / F capable of bidirectional communication with the host machine, and the host I / F 8 is a network I / F which communicates with the host machines 23 to 25 via the network 26. The host buffer 9 is a reception buffer for temporarily storing the data received from the host machines 21 to 25.

【0013】パネルI/F10は操作部11との間の通
信制御を行うインタフェース部であり、操作部11はプ
リンタの状態などを示す表示部及びオペレータがプリン
タを制御するためのスイッチ部から成る。ビデオメモリ
11は印刷画像データをページ単位で格納可能であり、
ビデオI/F12はビデオメモリ11上の画像データを
プリンタエンジン13に送る。プリンタエンジン13は
ビデオI/F12から送られてくる画像データをレーザ
ビーム、電子写真プロセスなどにより紙などの印刷媒体
上に形成する。バス14にはCPU2、プログラムRO
M3、RAM4、フォントROM5、ホストバッファ
9、パネルI/F10及びビデオメモリ11が接続され
ている。
The panel I / F 10 is an interface section for controlling communication with the operation section 11, and the operation section 11 is composed of a display section showing the printer status and a switch section for the operator to control the printer. The video memory 11 can store print image data in page units,
The video I / F 12 sends the image data in the video memory 11 to the printer engine 13. The printer engine 13 forms the image data sent from the video I / F 12 on a print medium such as paper by a laser beam, an electrophotographic process, or the like. The bus 14 has a CPU 2 and a program RO
M3, RAM 4, font ROM 5, host buffer 9, panel I / F 10 and video memory 11 are connected.

【0014】次に、図2を参照してホストマシン21〜
25から送られてくる印刷データが印刷されるまでの手
順を説明する。ホストマシン21〜25から送られてく
る印刷データはホストI/F6〜8により受信され、ホ
ストI/F6〜8は印刷データを受信するとこのデータ
受信をCPU2に対して割り込みにより通知する。CP
U2はこの割り込みにより受信データをホストI/F6
〜8から読み出し、一旦ホストバッファ9に格納する。
Next, referring to FIG. 2, the host machines 21-
The procedure until the print data sent from 25 is printed will be described. The print data sent from the host machines 21 to 25 is received by the host I / Fs 6 to 8. When the host I / Fs 6 to 8 receive the print data, the CPU 2 is notified of the data reception by interruption. CP
U2 receives the received data by the host I / F6
8 to 8 and once stored in the host buffer 9.

【0015】エミュレーションプログラム30は印刷デ
ータをホストバッファ9から順次読み出して解析し、印
刷画像を作成するモジュールである。ここで、ホストマ
シン21〜25から送られてくるコマンドは、ホストマ
シン21〜25毎に数種類のコマンド体系があり、これ
らに対応するために複数種類のエミュレーションプログ
ラム30がプログラムROM3に予め格納され、専用コ
マンド又は操作部11を介して切り換えることができ
る。
The emulation program 30 is a module that sequentially reads print data from the host buffer 9 and analyzes it to create a print image. Here, the commands sent from the host machines 21 to 25 have several kinds of command systems for each of the host machines 21 to 25, and a plurality of kinds of emulation programs 30 are stored in advance in the program ROM 3 in order to correspond to them. It can be switched through a dedicated command or the operation unit 11.

【0016】また、ホストマシン21〜25から送られ
てくる印刷データには、 ・文字を指定する文字コード ・イメージデータを印刷するためのイメージデータ ・グラフィックを印刷するためのグラフィックスコマン
ド ・印刷位置などを制御するための制御コマンド ・プリンタの状態やプリンタの構成等を問い合わせるた
めのコマンド が含まれる。
The print data sent from the host machines 21 to 25 includes: -a character code for specifying a character-image data for printing image data-a graphics command for printing a graphic-printing position Control commands to control the printer, etc.-Contains commands to inquire about the printer status and printer configuration.

【0017】エミュレーションプログラム30はこれら
の印刷データを解析して識別し、ビデオメモリ11上で
ページ単位で印刷画像を形成する。また、問い合わせコ
マンドの場合にはその応答データを、問い合わせコマン
ドを受信したホストI/F6〜8を介してホストマシン
21〜25に返送する。実際の描画作業は各描画モジュ
ールがエミュレーションプログラムからの指示を受けて
行い、文字を描画する場合には文字描画モジュール31
が文字コードに対応した文字画像情報をフォントROM
5から参照し、印刷画像をビデオメモリ11上でページ
単位で描画する。
The emulation program 30 analyzes and identifies these print data and forms a print image on the video memory 11 page by page. In the case of an inquiry command, the response data is returned to the host machines 21 to 25 via the host I / Fs 6 to 8 that received the inquiry command. Each drawing module performs the actual drawing work in response to an instruction from the emulation program. When drawing a character, the character drawing module 31 is used.
Is a font ROM that stores character image information corresponding to the character code.
5, the print image is drawn on the video memory 11 page by page.

【0018】また、イメージ描画モジュール31、グラ
フィックス描画モジュール32がそれぞれイメージデー
タ、グラフィックスデータに基づいて印刷画像をビデオ
メモリ11上でページ単位で描画する。1ページ分の印
刷画像が完成すると、この印刷画像がビデオメモリ11
かビデオI/F12を介してプリンタエンジン13に送
られ、紙などに印刷される。
The image drawing module 31 and the graphics drawing module 32 draw the print image on the video memory 11 page by page based on the image data and the graphics data, respectively. When the print image for one page is completed, this print image is displayed on the video memory 11
Alternatively, it is sent to the printer engine 13 via the video I / F 12 and printed on paper or the like.

【0019】次に、ホストバッファ9について説明する
と、ホストバッファ9はCPU2によりFIFI(Firs
t In First Out)形式で管理される。これをプログラム
で管理するために図3に示すように少なくとも4つの情
報で管理され、この情報はホストバッファ9の先頭アド
レスを示す先頭ポインタP1と、印刷データの入力アド
レスを示す入力ポインタP2と、印刷データの出力アド
レスを示す出力ポインタP3と、ホストバッファ9の終
了アドレスを示す終了ポインタP4により構成されてい
る。
Next, the host buffer 9 will be described.
t In First Out) format. In order to manage this by a program, it is managed by at least four pieces of information as shown in FIG. 3, and this information includes a head pointer P1 indicating the head address of the host buffer 9, an input pointer P2 indicating the input address of print data, and The output pointer P3 indicates the output address of the print data, and the end pointer P4 indicates the end address of the host buffer 9.

【0020】図3において、ホストバッファ9の初期状
態では、入力ポインタP2と出力ポインタP3が先頭ポ
インタP1と同じ値に設定され、この状態でホストI/
F6〜8を介してデータを受信すると、その受信データ
を入力ポインタP2が示すアドレスに格納し、入力ポイ
ンタP2をその次のアドレスに設定する。したがって、
入力ポインタP2と出力ポインタP3の各値の差がホス
トバッファ9のデータ数となる。
In FIG. 3, in the initial state of the host buffer 9, the input pointer P2 and the output pointer P3 are set to the same value as the head pointer P1.
When the data is received via F6 to 8, the received data is stored in the address indicated by the input pointer P2, and the input pointer P2 is set to the next address. Therefore,
The difference between the values of the input pointer P2 and the output pointer P3 is the number of data in the host buffer 9.

【0021】ホストバッファ9からデータを読み出す場
合には、入力ポインタP2を越えない範囲で出力ポイン
タP3が示すアドレスから順次データを取り出すと共
に、出力ポインタP3の値を更新する。また、入力ポイ
ンタP2と出力ポインタP3が終了ポインタP4まで到
達すると、各ポインタP2、P3を先頭ポインタP1に
移動させることによりホストバッファ9を循環して使用
する。
When reading data from the host buffer 9, the data is sequentially fetched from the address indicated by the output pointer P3 within a range not exceeding the input pointer P2, and the value of the output pointer P3 is updated. When the input pointer P2 and the output pointer P3 reach the end pointer P4, the host buffer 9 is circulated and used by moving the pointers P2 and P3 to the head pointer P1.

【0022】これらのポインタP1〜P4はCPU2に
より起動時にRAM4上に変数として作成され、この時
の初期値として先頭ポインタP1はホストバッファ9の
先頭アドレスに設定され、終了ポインタP4は先頭ポイ
ンタP1にホストバッファ9の大きさを加算したアドレ
スに、また、入力ポインタP2と出力ポインタP3は先
頭ポインタP1と同じ値に設定される。そして、データ
の入出力時には上記の如く入力ポインタP2と出力ポイ
ンタP3の値を変更してバッファ9の管理を行う。
These pointers P1 to P4 are created as variables on the RAM 4 by the CPU 2 at the time of activation. At this time, the head pointer P1 is set to the head address of the host buffer 9, and the end pointer P4 is set to the head pointer P1. The address obtained by adding the size of the host buffer 9 is set, and the input pointer P2 and the output pointer P3 are set to the same value as the head pointer P1. When data is input / output, the values of the input pointer P2 and the output pointer P3 are changed as described above to manage the buffer 9.

【0023】この実施例では一例としてホストバッファ
9の大きさ情報として2種類が予め準備されている。大
きい方はホストマシン21〜25との通信形態が受信の
みの場合に使用され、小さい方はホストマシン21〜2
5に応答データを返信する通信形態の場合に使用され
る。前者はセントロニクスのホストI/F6を介して受
信する場合であり、以下の説明ではこの場合のサイズを
MAXサイズと呼ぶ。また、後者はRS232Cのホス
トI/F7を介して受信する場合であり、この場合のサ
イズをMINサイズと呼ぶ。また、ネットワーク26、
ホストI/F8を介して受信する場合は、ホストマシン
23〜25に応じて単方向と双方向の2種類がある。
In this embodiment, as an example, two types of size information of the host buffer 9 are prepared in advance. The larger one is used when the communication form with the host machines 21 to 25 is only reception, and the smaller one is the host machines 21 to 2.
It is used in the case of a communication mode in which response data is returned to The former is a case of receiving via the host I / F 6 of Centronics, and the size in this case will be called MAX size in the following description. The latter is a case of receiving via the host I / F 7 of RS232C, and the size in this case is called MIN size. In addition, the network 26,
When receiving via the host I / F 8, there are two types, unidirectional and bidirectional, depending on the host machines 23 to 25.

【0024】図4は通信方向が既知のホストI/F6、
7を介してデータを受信した場合の処理を示し、ホスト
I/F6、7を介してデータを受信すると先ず双方向受
信か否かをチェックする(ステップS11)。ここで、
前述したようにホストI/F6〜8はデータを受信する
と割り込みによりデータ受信をCPU2に通知するの
で、CPU2はどのホストI/F6〜8からの割り込み
かにより通信形態を判別することができる。
FIG. 4 shows a host I / F 6 whose communication direction is known,
The process when data is received via 7 is shown. When data is received via the host I / Fs 6 and 7, it is first checked whether bidirectional reception is performed (step S11). here,
As described above, when the host I / Fs 6 to 8 receive the data, the CPU 2 notifies the CPU 2 of the data reception by the interrupt. Therefore, the CPU 2 can determine the communication mode depending on which of the host I / Fs 6 to 8 is the interrupt.

【0025】ステップS11において双方向受信と判断
した場合には、ホストバッファ9の大きさがMINサイ
ズに設定されているか否かをチェックする(ステップS
12)。そして、MINサイズに設定されている場合に
は受信データをそのMINサイズのホストバッファ9に
格納し(ステップS13)、他方、MINサイズに設定
されていない場合にはホストバッファ9が空になるまで
待機し(ステップS14)、空になると終了ポインタP
4をMINサイズ用に設定し(ステップS15)、ステ
ップS13に進んで受信データをそのMINサイズのホ
ストバッファ9に格納する。
When it is determined that the reception is bidirectional in step S11, it is checked whether the size of the host buffer 9 is set to the MIN size (step S).
12). If the MIN size is set, the received data is stored in the host buffer 9 of the MIN size (step S13). On the other hand, if the MIN size is not set, the host buffer 9 becomes empty. It waits (step S14), and when it becomes empty, the end pointer P
4 is set for the MIN size (step S15), and the process proceeds to step S13 to store the received data in the host buffer 9 of the MIN size.

【0026】これに対し、ステップS11において双方
向受信でない場合には、ホストバッファ9の大きさがM
AXサイズに設定されているか否かをチェックする(ス
テップS16)。そして、MAXサイズに設定されてい
る場合には受信データをそのMAXサイズのホストバッ
ファ9に格納し(ステップS13)、他方、MAXサイ
ズに設定されていない場合にはホストバッファ9が空に
なるまで待機し(ステップS17)、空になると終了ポ
インタP4をMAXサイズ用に設定し(ステップS1
8)、ステップS13に進んで受信データをそのMAX
サイズのホストバッファ9に格納する。
On the other hand, when the bidirectional reception is not performed in step S11, the size of the host buffer 9 is M.
It is checked whether the AX size is set (step S16). If it is set to the MAX size, the received data is stored in the host buffer 9 of that MAX size (step S13). On the other hand, if it is not set to the MAX size, the host buffer 9 becomes empty. It waits (step S17), and when it becomes empty, sets the end pointer P4 for MAX size (step S1).
8) Go to step S13 and set the received data to MAX
The size is stored in the host buffer 9.

【0027】次に、図5及び図6を参照して通信方向が
未知のネットワーク26、ホストI/F8を介してデー
タを受信した場合の処理を説明する。ここで、ネットワ
ーク26を介して通信を行う場合、ホストマシン23〜
25の種類によりプロトコル(通信規約)が異なる。例
えばMacintosh 社のAppletalk というプロトコルを使用
するホストマシンはプリント時にプリンタの種々の情報
を問い合わせ、それに適した印刷データを作成するが、
TCP/IPというプロトコルを使用するホストマシンは問い
合わせを行わず、印刷データを転送するのみである。
Next, the processing when data is received via the network 26 and the host I / F 8 whose communication direction is unknown will be described with reference to FIGS. Here, when performing communication via the network 26, the host machines 23 to
The protocol (communication protocol) differs depending on the 25 types. For example, a host machine that uses the Appletalk protocol of the Macintosh company inquires various information of the printer at the time of printing and creates print data suitable for it.
The host machine that uses the TCP / IP protocol does not make an inquiry, but only transfers print data.

【0028】そこで、図5に示す処理ではネットワーク
I/F8を介してデータを受信すると、先ず、相手先ホ
ストマシン23〜25が応答データの送信が必要なプロ
トコルか否かをチェックする(ステップS21)。そし
て、応答データの送信が必要なプロトコルと判断した場
合には、図4に示す場合と同様にホストバッファ9の大
きさがMINサイズに設定されているか否かをチェック
し(ステップS22)、MINサイズに設定されている
場合には受信データをそのMINサイズのホストバッフ
ァ9に格納し(ステップS23)、他方、MINサイズ
に設定されていない場合にはホストバッファ9が空にな
るまで待機し(ステップS24)、空になると終了ポイ
ンタP4をMINサイズ用に設定し(ステップS2
5)、ステップS23に進んで受信データをそのMIN
サイズのホストバッファ9に格納する。
Therefore, in the processing shown in FIG. 5, when data is received via the network I / F 8, first, the destination host machines 23 to 25 check whether or not the protocol requires transmission of response data (step S21). ). When it is determined that the protocol requires the transmission of the response data, it is checked whether or not the size of the host buffer 9 is set to the MIN size as in the case shown in FIG. 4 (step S22), and the MIN is set. If the size is set, the received data is stored in the host buffer 9 of the MIN size (step S23). On the other hand, if the MIN size is not set, the host buffer 9 waits until it becomes empty ( At step S24), when it becomes empty, the end pointer P4 is set for the MIN size (step S2).
5) Go to step S23 and set the received data to the MIN
The size is stored in the host buffer 9.

【0029】また、ステップS21において応答データ
の送信が必要なプロトコルでない場合にも同様に、ホス
トバッファ9の大きさがMAXサイズに設定されている
か否かをチェックし(ステップS26)、MAXサイズ
に設定されている場合には受信データをそのMAXサイ
ズのホストバッファ9に格納し(ステップS23)、他
方、MAXサイズに設定されていない場合にはホストバ
ッファ9が空になるまで待機し(ステップS27)、空
になると終了ポインタP4をMAXサイズ用に設定し
(ステップS28)、ステップS23に進んで受信デー
タをそのMAXサイズのホストバッファ9に格納する。
Also, when the response data is not required to be transmitted in step S21, it is similarly checked whether or not the size of the host buffer 9 is set to the MAX size (step S26), and the size is changed to the MAX size. If it is set, the received data is stored in the host buffer 9 of that MAX size (step S23), while if it is not set to the MAX size, it waits until the host buffer 9 becomes empty (step S27). ), When it becomes empty, the end pointer P4 is set for the MAX size (step S28), and the process proceeds to step S23 to store the received data in the host buffer 9 of the MAX size.

【0030】また、図6に示す処理では、相手先に基づ
いてエミュレーションプログラムを変更した場合には、
問い合わせコマンドが有るエミュレーションプログラム
か否かをチェックする(ステップS31)。そして、問
い合わせコマンドが有るエミュレーションプログラムと
判断した場合には、図4及び図5に示す場合と同様にホ
ストバッファ9の大きさがMINサイズに設定されてい
るか否かをチェックし(ステップS32)、MINサイ
ズに設定されている場合には受信データをそのMINサ
イズのホストバッファ9に格納し(ステップS33)、
他方、MINサイズに設定されていない場合にはホスト
バッファ9が空になるまで待機し(ステップS34)、
空になると終了ポインタP4をMINサイズ用に設定し
(ステップS35)、ステップS33に進んで受信デー
タをそのMINサイズのホストバッファ9に格納する。
In the process shown in FIG. 6, when the emulation program is changed based on the destination,
It is checked whether the emulation program has an inquiry command (step S31). When it is determined that the emulation program has an inquiry command, it is checked whether or not the size of the host buffer 9 is set to the MIN size as in the case shown in FIGS. 4 and 5 (step S32). If the MIN size is set, the received data is stored in the host buffer 9 of the MIN size (step S33),
On the other hand, if the MIN size is not set, the host buffer 9 waits until it becomes empty (step S34),
When it becomes empty, the end pointer P4 is set for the MIN size (step S35), and the process proceeds to step S33 to store the received data in the host buffer 9 of the MIN size.

【0031】また、ステップS31において問い合わせ
コマンドが有るエミュレーションプログラムでない場合
にも同様に、ホストバッファ9の大きさがMAXサイズ
に設定されているか否かをチェックし(ステップS3
6)、MAXサイズに設定されている場合には受信デー
タをそのMAXサイズのホストバッファ9に格納し(ス
テップS33)、他方、MAXサイズに設定されていな
い場合にはホストバッファ9が空になるまで待機し(ス
テップS37)、空になると終了ポインタP4をMAX
サイズ用に設定し(ステップS38)、ステップS33
に進んで受信データをそのMAXサイズのホストバッフ
ァ9に格納する。
Similarly, if the emulation program does not have an inquiry command in step S31, it is similarly checked whether the size of the host buffer 9 is set to the MAX size (step S3).
6) If the maximum size is set, the received data is stored in the maximum size host buffer 9 (step S33). On the other hand, if the maximum size is not set, the host buffer 9 becomes empty. Waits until (step S37) and becomes empty, the end pointer P4 is set to MAX.
Set for size (step S38), step S33
Then, the received data is stored in the host buffer 9 of the MAX size.

【0032】[0032]

【発明の効果】以上説明したように本発明によれば、デ
ータを受信したインタフェースが双方向通信を行うか、
又は受信方向のみの通信を行うかに基づいて受信バッフ
ァの大きさを調整するので、受信バッファの最適な大き
さを自動的に設定することができる。
As described above, according to the present invention, whether the interface that receives data performs bidirectional communication,
Alternatively, since the size of the reception buffer is adjusted based on whether communication is performed only in the reception direction, the optimum size of the reception buffer can be automatically set.

【0033】本発明はまた、データを受信した相手先ホ
スト装置のプロトコルの種類に基づいて受信バッファの
大きさを調整するので、受信バッファの最適な大きさを
自動的に設定することができる。
Further, according to the present invention, the size of the receiving buffer is adjusted based on the type of protocol of the destination host device which received the data, so that the optimum size of the receiving buffer can be automatically set.

【0034】本発明はまた、データを受信した場合にど
のコマンド解釈手段が動作しているかに基づいて受信バ
ッファの大きさを調整するので、受信バッファの最適な
大きさを自動的に設定することができる。
The present invention also adjusts the size of the receive buffer based on which command interpreting means is operating when receiving data, so that the optimum size of the receive buffer is automatically set. You can

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明に係るプリンタの一実施形態としてレー
ザビームプリンタの画像処理部(コントローラ)を示す
ブロック図である。
FIG. 1 is a block diagram showing an image processing unit (controller) of a laser beam printer as an embodiment of a printer according to the present invention.

【図2】ホストマシンから送られてくる印刷データが印
刷されるまでの手順を示す説明図である。
FIG. 2 is an explanatory diagram showing a procedure until print data sent from a host machine is printed.

【図3】図1のホストバッファの管理情報を示す説明図
である。
FIG. 3 is an explanatory diagram showing management information of a host buffer of FIG.

【図4】通信方向に基づいてバッファサイズを変更する
処理を説明するためのフローチャートである。
FIG. 4 is a flowchart illustrating a process of changing a buffer size based on a communication direction.

【図5】相手先プロトコルに基づいてバッファサイズを
変更する処理を説明するためのフローチャートである。
FIG. 5 is a flowchart for explaining a process of changing a buffer size based on a partner protocol.

【図6】エミュレーションプログラムに基づいてバッフ
ァサイズを変更する処理を説明するためのフローチャー
トである。
FIG. 6 is a flowchart illustrating a process of changing a buffer size based on an emulation program.

【符号の説明】[Explanation of symbols]

2 CPU 3 プログラムROM 9 ホストバッファ 6〜8 ホストI/F 21〜25 ホストマシン 2 CPU 3 program ROM 9 host buffer 6-8 host I / F 21-25 host machine

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 複数のホスト装置との間で双方向通信又
は受信方向のみの通信をそれぞれ行うことによりホスト
装置からのデータを受信する複数のインタフェースと、 前記インタフェースを介して受信したデータを一時記憶
するための受信バッファと、 データを受信したインタフェースが双方向通信を行う
か、又は受信方向のみの通信を行うかに基づいて前記受
信バッファの大きさを調整する手段とを有するプリン
タ。
1. A plurality of interfaces for receiving data from a host device by performing two-way communication or communication only in the receiving direction with a plurality of host devices, and temporarily storing data received via the interfaces. A printer having a receiving buffer for storing, and means for adjusting the size of the receiving buffer based on whether the interface receiving the data performs bidirectional communication or communication in the receiving direction only.
【請求項2】 複数のホスト装置との間で双方向通信又
は受信方向のみの通信をそれぞれ行うことによりホスト
装置からのデータを受信するための複数のインタフェー
スと、 前記インタフェースを介して受信したデータを一時記憶
するための受信バッファと、 データを受信した相手先ホスト装置のプロトコルの種類
に基づいて前記受信バッファの大きさを調整する手段と
を有するプリンタ。
2. A plurality of interfaces for receiving data from the host device by performing two-way communication or communication only in the receiving direction with the plurality of host devices, and data received via the interfaces. And a means for adjusting the size of the reception buffer based on the protocol type of the destination host device that received the data.
【請求項3】 複数のホスト装置との間で双方向通信又
は受信方向のみの通信をそれぞれ行うことによりホスト
装置からのデータを受信する複数のインタフェースと、 前記インタフェースを介して受信したデータを一時記憶
するための受信バッファと、 複数の相手先ホスト装置のコマンドをそれぞれ解釈する
複数のコマンド解釈手段と、 データを受信した場合にどのコマンド解釈手段が動作し
ているかに基づいて前記受信バッファの大きさを調整す
る手段とを有するプリンタ。
3. A plurality of interfaces that receive data from the host device by performing bidirectional communication or communication only in the receiving direction with the plurality of host devices, and temporarily store the data received via the interfaces. A receive buffer for storing, a plurality of command interpreting means for interpreting commands of a plurality of destination host devices, and a size of the receive buffer based on which command interpreting means operates when receiving data. And a means for adjusting the height.
JP7293673A 1995-10-16 1995-10-16 Printer Pending JPH09114609A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP7293673A JPH09114609A (en) 1995-10-16 1995-10-16 Printer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP7293673A JPH09114609A (en) 1995-10-16 1995-10-16 Printer

Publications (1)

Publication Number Publication Date
JPH09114609A true JPH09114609A (en) 1997-05-02

Family

ID=17797761

Family Applications (1)

Application Number Title Priority Date Filing Date
JP7293673A Pending JPH09114609A (en) 1995-10-16 1995-10-16 Printer

Country Status (1)

Country Link
JP (1) JPH09114609A (en)

Similar Documents

Publication Publication Date Title
US5617518A (en) Output control method and system of servers
WO2000058823A1 (en) Network system and network interface card
US5689730A (en) Network interface apparatus adaptable to multifunction peripheral apparatus
JPH09114609A (en) Printer
JP3017343B2 (en) Print control apparatus and method
US7433071B2 (en) Printing method and apparatus of multi function product and computer-readable recording medium for storing computer program for controlling the product
JP3129679B2 (en) Printer
JPH1191209A (en) Printer
JP2001228996A (en) Image forming system
JP3421171B2 (en) Combined printing device
KR100402917B1 (en) Method for reprint and system thereof
JPH08123639A (en) Information processing system and printer used for the same
JP3217485B2 (en) Printing device
JPH09269877A (en) Image forming device
JP3241902B2 (en) Print control device and print control method
JP3056948B2 (en) PRINTING APPARATUS, CONTROLLER THEREOF, AND METHOD OF CONTROLLING PRINTING APPARATUS
JP3222675B2 (en) Printing apparatus and display control method for printing apparatus
JP2555970B2 (en) Online automatic external character registration method
JPH09277656A (en) Printing device
JPH08337031A (en) Printing apparatus and controlling method therefor, and printing system and controlling method therefor
KR100544165B1 (en) Method for changing registered information of printer in printer driver
JPH10202987A (en) Printer device
JPH08164640A (en) Printer and printing system using the printer
JPH11272434A (en) Picture forming device
JPH09259079A (en) Communication controller, communication control method, and memory