JPS6027936A - Control system of printer - Google Patents
Control system of printerInfo
- Publication number
- JPS6027936A JPS6027936A JP58135141A JP13514183A JPS6027936A JP S6027936 A JPS6027936 A JP S6027936A JP 58135141 A JP58135141 A JP 58135141A JP 13514183 A JP13514183 A JP 13514183A JP S6027936 A JPS6027936 A JP S6027936A
- Authority
- JP
- Japan
- Prior art keywords
- function
- code
- printer
- external device
- character
- 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
Links
Landscapes
- Record Information Processing For Printing (AREA)
- Accessory Devices And Overall Control Thereof (AREA)
Abstract
Description
【発明の詳細な説明】
(技術分野)
本発明は外部装置の指示によシプリンタの機能コードを
変更、削除するフ0リンタ制御方式に関するものである
。DETAILED DESCRIPTION OF THE INVENTION (Technical Field) The present invention relates to a printer control method for changing or deleting printer function codes according to instructions from an external device.
(従来技術)
一般にプリンタは第1図の文字コード表に従って文字・
記号等を印字している。この文字コード表において1の
b8.b7.b6.b5は文字コードの上位4ビツト、
2のb4.b3゜b2.blは文字コードの下位4ビツ
トを表わす。3は上記上位4ビツトのb8をMSB (
最上位ビット)とし、b5をLSB (最下位ビット)
トシて16進数で表わしたものであり、4は上記下位4
ビツトのb4をMSB 、 b 1をI、SBとして1
6進数で表わしたものである。5は文字・記号等のエリ
ア、6は機能キャラクタのエリアである。この様な構成
の文字コード表において文字It A ITを指定する
にはコード′”41″′、機能キャラクタ” FS ”
を指定するにはコード” i c ”を与える。(Prior art) Printers generally print characters and characters according to the character code table shown in Figure 1.
Symbols, etc. are printed. In this character code table, 1 b8. b7. b6. b5 is the upper 4 bits of the character code,
2 b4. b3゜b2. bl represents the lower 4 bits of the character code. 3 is the MSB (
(most significant bit) and b5 is LSB (least significant bit)
It is expressed in hexadecimal, and 4 is the lower 4 above.
Bit b4 is MSB, b1 is I, SB is 1
It is expressed in hexadecimal. 5 is an area for characters, symbols, etc., and 6 is an area for functional characters. To specify the character It A IT in a character code table with this structure, use the code ``41'''' and the function character ``FS''.
To specify, give the code "ic".
近年、外部装置としてのパーソナル・コンピー−可能で
あること、すなわち汎用性が要求されている。しかし上
記文字コード表中の機能キャラクタエリアロ内の機能の
使い方が各ノE−ソナル・コンピュータ毎に異なってい
るため従来から一部その対策が行なわれてきた。従来の
対策としては各・ぐ−ソナル・コンピータ毎の機能キャ
ラクタエリア6内の機能コード変換表(例えばROM
)をプリンタ内に設け、オペレータがこの変換表をスイ
ッチ等の手段によシ選択するようにしていた。ところが
・ぐ−ソナル・コンピータの種類が増え上記変換表が増
えると上記方法ではすべての・ξ−ソナル・コンピュー
タに対応できる機能をプリンタが持つことが困難となる
欠点があった。さらに他の対策として接続されるパーソ
ナル・コンピー−りに応じてフ0リンタの機能判定用の
7°ログラムを変更する等もあるが変更作業が困難であ
り実用的でない。In recent years, there has been a demand for personal computers to be used as external devices, that is, to have versatility. However, since the usage of the functions in the function character alias in the character code table differs from computer to computer, some countermeasures have been taken in the past. As a conventional measure, the function code conversion table (for example, ROM
) is provided in the printer, and the operator selects this conversion table using means such as a switch. However, as the types of computer computers increase and the number of conversion tables described above increases, the method described above has the disadvantage that it becomes difficult for printers to have the functionality to be compatible with all the computer systems. Another measure is to change the 7° program for determining the printer's function depending on the connected personal computer, but this is difficult and impractical.
(発明の目的)
本発明は以上の点に鑑みてなされたものであシ、目的と
するところは11i′i単な操作で各棟の外部装置にプ
リンタを接続する改良されたプリンタの制御方式を提供
することである。(Objective of the Invention) The present invention has been made in view of the above points, and aims to provide an improved printer control system that connects a printer to an external device in each building with a simple operation. The goal is to provide the following.
(発明の構成)
本発明は上記目的を達成するためプリンタ内部に機能コ
ード格納用のテーブルを設け、該テーブルの予め機能毎
に割シ当てられたアドレスに外部装置に決められた該機
能に対する機能コードを予め外部装置から転送し格納し
ておき、以降外部装置から転送される機能コードによシ
上記テーブル内をサーチして該コードに対する機能を知
るものであり以下詳細に説明する。(Structure of the Invention) In order to achieve the above object, the present invention provides a table for storing function codes inside the printer, and a function code corresponding to the function determined in an external device is assigned to an address assigned in advance for each function in the table. A code is transferred and stored in advance from an external device, and thereafter the table is searched using the function code transferred from the external device to find out the function corresponding to the code, which will be described in detail below.
(実施例)
第2図に本発明に係るプリンタ制御回路の構成図を示し
、7はプリンタを制御するマイクロコンビーータ(CP
U)、8は70ログラムが格納されている読出し専用メ
モリ(ROM)、9は印字データ、テーブル、フラグ類
を格納する読出し書込み可能メモリ(RAM )、7
oは図示せぬインタフェース部やスペース、改行モータ
及び印字ヘッドを駆動するドライバ部が接続される入出
力ポート(I10ポh )、171dr−タパス、12
はアドレスバスである。この様に構成されたプリンタ制
御回路においてRAM 9には予め機能毎に第3図(c
)に示す如くアドレスが割g当てられているものとする
。ここでは−例として10字/インチの機能がアドレス
” 0000” 、12字/インチの機能がアドレス”
0001°′、17字/インチの機能がアドレス”00
02”に割シ当てられるものとする。ただしアドレスは
上記例に限定されるものではないし、機能とアドレスと
の対応もこれに限定されるものでないことは言うまでも
ない。ここで図示せぬ外部装置からI10ポート10を
介してCPU7に第3図(a)に示す電文が転送される
と(CPU 7には第3図(b)のデータが入力される
)、CPU7は予めROM 8に格納きれているプログ
ラムによシ上記電文を解読する。今、電文のESCAを
機能コードの機能テーブルへの格納指示、続<(00)
+1.(Ol))I。(Example) FIG. 2 shows a configuration diagram of a printer control circuit according to the present invention, and 7 is a microcontroller (CP) that controls the printer.
U), 8 is a read-only memory (ROM) that stores 70 programs, 9 is a read-write memory (RAM) that stores print data, tables, flags, etc., 7
o is an input/output port (I10 port) to which an interface section (not shown), a space, a line feed motor, and a driver section for driving the print head are connected, 171dr-tapas, 12
is the address bus. In the printer control circuit configured in this way, the RAM 9 is stored in advance for each function as shown in Fig. 3 (c).
) Assume that addresses are assigned as shown in FIG. Here - as an example, the function of 10 characters/inch is the address "0000", and the function of 12 characters/inch is the address "0000".
0001°', 17 characters/inch function is address "00"
02". However, the address is not limited to the above example, and it goes without saying that the correspondence between functions and addresses is not limited to this. When the message shown in FIG. 3(a) is transferred to the CPU 7 via the I10 port 10 (the data shown in FIG. 3(b) is input to the CPU 7), the CPU 7 transfers the data stored in the ROM 8 in advance. Decipher the above message using the program.Now, instruct the ESCA of the message to store the function code in the function table.Continue <(00)
+1. (Ol))I.
(02) Hを機能テーブルの格納番地、続く*をセパ
レータ、続(FS 、 GS 、 R8を文字ピッチ指
定用の機能キャラクタ、続く:をエンドコード、として
定義I7ておく。ここで(00)H等のHは16進数を
意味する。CPU 7は電文中にESCAを検出すると
以降機能テーブルへの格能動作を行なう。この動作はE
SCAに続く電文(00)HでRAM9のアドレス゛’
o o o o ”を指定してセパレータ*に続く電
文FSのコード°’ l C” (00011100)
を格納することである。従ってこの外部装置は10字/
インチの文字ピッチを機能キャラクタ゛’FS”で指定
することを示す。外部装置がlO字/インチの文字ピッ
チを他の機能キャラクタ゛’R8”でプリンタに指示す
る場合にはアドレス°’ o o o o ”に機能キ
ャラクタR3のコード” I E ” (000111
10)を格納すれば良い。尚、12字/インチ、17字
/インチについても同様である。(02) Define H as the storage address of the function table, * as the separator, continuation (FS, GS, R8 as the function character for specifying character pitch, and continuation: as the end code). Here, (00)H etc., H means a hexadecimal number. When the CPU 7 detects ESCA in the message, it performs a function operation on the function table. This operation is
The message (00)H following SCA indicates the address of RAM9.
o o o o” and the message FS code following the separator * °' l C” (00011100)
is to store. Therefore, this external device has 10 characters/
Indicates that the character pitch in inches is specified by the function character 'FS'.When an external device instructs the printer to specify the character pitch in 10 characters/inch by another function character 'R8', the address °' o o o o “The code for the functional character R3 is “I E” (000111
10) should be stored. The same applies to 12 characters/inch and 17 characters/inch.
次にこの機能テーブルを使用する場合にはCPU7に外
部装置から機能コード’ L D ” (機能キャラク
タGS )が転送されるとCPU 7はRAM 9内の
機能テーブルのデータを参照してデータ+11 p +
+と同じデータが格納されている機能テーブルアドレス
を見つけ出す。第3図(C)の如く外部装置の指示で機
能コードが機能テーブル内に格納されていたとするとC
PU 7はアドレス“” OOOl ”に同一データ”
l D ”が格納されていることを知り、このアドレ
スに固定して設けられた機能12字/インチの文字ピッ
チで以後の動作を行なう。このようにしてプリンタの有
する機能の分、RAM9内に機能テーブルを設は外部装
置から実際の印字処理を行なう前に機能コードをフォー
マットに従ってプリンタに入力すれば良い。Next, when using this function table, when the function code 'LD'' (function character GS) is transferred from the external device to the CPU 7, the CPU 7 refers to the data of the function table in the RAM 9 and sets the data +11p. +
Find the function table address where the same data as + is stored. If a function code is stored in the function table according to an instruction from an external device as shown in Figure 3 (C), then C
PU 7 has the same data at address ""OOOl""
Knowing that ``D'' is stored, the printer performs the following operations at a character pitch of 12 characters/inch, which is fixed at this address. Once the function table is set up, the function code can be inputted into the printer according to the format from an external device before the actual printing process is performed.
以上説明したように外部装置から機能コードが任意に指
定できることによシ各種の外部装置にプリンタを接続で
きる利点がある。As explained above, since a function code can be specified arbitrarily from an external device, there is an advantage that the printer can be connected to various external devices.
第1の実施例では機能コードを全て外部装置から入力し
たがあらかじめプログラムされた機能コードをROMに
持ちプリンタの電源投入時にRAMの機能テーブルに転
送し変更したい機能コードのみ外部装置から入力する方
式としても良い。又RAMをバ、テリバックア、プにし
た9不揮発性のRAM(NOVRAM ) ヤ電気的消
去可能なROM (EEFROM’)を使用することに
よシ一度設定した機能コードを保持し電源断接のたびに
愼能コードを再入力しなくとも済む方式としても良い。In the first embodiment, all the function codes are input from the external device, but a method in which the pre-programmed function codes are stored in the ROM and transferred to the function table in the RAM when the printer is turned on, and only the function code to be changed is input from the external device. Also good. In addition, by using non-volatile RAM (NOVRAM) and electrically erasable ROM (EEFROM'), the function code once set is retained and the function code is saved every time the power is disconnected. It is also possible to use a method that eliminates the need to re-enter the Shinneng code.
さらに第1の実施例では単一の機能コードにっいて説明
しだが2バイト以上で構成される機能コードについても
拡張できるのはいうまでもない。Further, in the first embodiment, a single function code is explained, but it goes without saying that the invention can be extended to function codes composed of two or more bytes.
第4図に2バイトで構成した機能コードの例を第2の実
施例として示す。第2の実施例は改行ピッチを指定する
機能コードの例であり6行/インチの指定をESC6,
8行/インチの指定をESC8とした場合である。FIG. 4 shows an example of a function code composed of 2 bytes as a second embodiment. The second example is an example of a function code that specifies the line feed pitch. 6 lines/inch is specified by ESC6,
This is a case where 8 lines/inch is specified as ESC8.
第4図(a)の電文のうちESCBが2バイトで構成さ
れる機能コードを機能テーブルに格納する命令であり、
続< (1o )H、(12)Hは機能テーブルの格納
先頭アドレス、続く木はセパレータ、続(ESC6、E
SC8は2バイト構成の機能コードを指定する機能キャ
ラクタ、続く:はエンドコードである。機能コードが2
バイト構成の場合も機能コードがRAM内の機能テーブ
ルの連続するアドレスに2バイト格納されることを除き
第1の実施例と同様の動作を行なうが第1の実測例よシ
さらに多くの機能を設定できる利点がある。In the message of FIG. 4(a), ESCB is an instruction to store a function code consisting of 2 bytes in a function table,
Continuation < (1o)H, (12)H is the storage start address of the function table, the following tree is the separator, continuation (ESC6, E
SC8 is a function character that specifies a 2-byte function code, and the following: is an end code. Function code is 2
In the case of byte configuration, the operation is similar to that of the first embodiment except that the function code is stored in 2 bytes of consecutive addresses of the function table in RAM, but it has more functions than the first measurement example. It has the advantage of being configurable.
次に機能テーブルの内容を削除したい場合には第5図(
、)の如き電文を外部装置からプリンタに転送する。第
5図(a)の電文でESCAは前記の如く機能テーブル
への書込み命令であシ、続く(XX)Hは機能テーブル
の書込みアドレス、続く木はセパレータ、続< NUL
はとの)・表能が無効である(すなわち本装置ではこの
機能を使用しない)ことを示す機能キャラクタでありコ
ードは00”である。Next, if you want to delete the contents of the function table, see Figure 5 (
, ) is transferred from an external device to the printer. In the message of FIG. 5(a), ESCA is a write command to the function table as described above, the following (XX)H is the write address of the function table, the following tree is a separator, and the following < NUL
This is a function character indicating that the function is disabled (that is, this function is not used in this device), and its code is 00''.
続く:エンドコードである。第3図の如く本装置で使用
しない機能テーブルアドレスに機能キャラクタNULに
対応するコード” o o ”を書き込んでおくことに
よりプリンタは機能テーブルの” o o ”コードを
見つけて対応する機能が本装置では未使用であることを
知る。この様に機能テーブルの未使用機能コードを定義
しておくことによシ使用機能と未使用機能を簡単に判別
できる。伺、上記削除命令は第5図(、)の電文に限定
されるものではなく前記2バイト構成の電文としても良
いし、特別に削除命令を設けても良い。この場合の削除
命令は一例として電文の初めにESCCを用いてESC
C(××)H:とすれば良い。以上の説明においてプリ
ンタ内部で最初機能テーブル内をクリア(例えばコード
“°00”を機能テーブルの全てのアドレスに格納)し
ておき必要な機能のみを設定するようにすればより良好
な効果を得られることは言うまでもない。Continuing: This is the end code. As shown in Figure 3, by writing the code "o o" corresponding to the function character NUL in a function table address that is not used by this device, the printer will find the "o o" code in the function table and write the corresponding function to this device. I know it's unused. By defining unused function codes in the function table in this way, it is possible to easily distinguish between used functions and unused functions. However, the above deletion command is not limited to the message shown in FIG. For example, the deletion command in this case is to use ESCC at the beginning of the message.
C(xx)H: may be used. In the above explanation, better effects can be obtained by first clearing the function table inside the printer (for example, storing the code "°00" in all addresses of the function table) and then setting only the necessary functions. Needless to say, it can be done.
さらに機能テーブル内の未使用機能コードをパ00″と
したが他のコードとしても良い。Further, although the unused function code in the function table is set as Pa00'', other codes may be used.
(発明の効果)
以上詳細に説明したように本発明によればプリンタ内に
プリンタが有す機能分の機能コードを格納できる機能テ
ーブルを備え、外部装置からの指定により該機能テーブ
ル内の内容を書き替えることにより1つのプリンタのプ
ログラムで機能コードの異なる各種の外部装置に接続で
きる利点がある。(Effects of the Invention) As described in detail above, according to the present invention, the printer is provided with a function table that can store function codes for the functions of the printer, and the contents of the function table can be read by designation from an external device. By rewriting one printer program, there is an advantage that it can be connected to various external devices with different function codes.
第1図は文字コード表を示す図、第2図はプリンタ制御
回路の構成図、第3図(、)は外部装置から転送される
電文を示す図、第3図(b)は第3図(a)の電文を1
6進数で表示した図、第3図(c)は機能テーブルを説
明する図、第4図(、)は第2実施例による電文を示す
図、第4図(b)は第4図(、)の電文を16進数で表
示した図、第4図(c)は第2実施例による機能テーブ
ルを説明する図、第5図(a)は機能テーブルの内容を
削除するだめの電文を示す図、第5図(b)は第5図(
a)の電文を16進数で表示した図、第5図(c)は機
能テーブルの削除を説明する図である。
7 ・・・ CPU、 8 ・・・ ROJ 9 ・・
・ RノヘJν1 、 ノ 0 ・・・ I10ポート
、lノ・・・データバス、12・・・アドレスバス。
特許量□願人 沖電気工業株式会社
第3図
第4図
第5図
=
(bl慧T;ご=g臣
史Figure 1 is a diagram showing a character code table, Figure 2 is a configuration diagram of the printer control circuit, Figure 3 (,) is a diagram showing a message transferred from an external device, and Figure 3 (b) is a diagram showing a message transferred from an external device. 1 message of (a)
FIG. 3(c) is a diagram showing the function table, FIG. 4(,) is a diagram showing the message according to the second embodiment, and FIG. ) is a hexadecimal representation of the message, FIG. 4(c) is a diagram explaining the function table according to the second embodiment, and FIG. 5(a) is a diagram showing the message for deleting the contents of the function table. , Figure 5(b) is Figure 5(b)
A diagram showing the message in a) in hexadecimal notation, and FIG. 5(c) are diagrams for explaining deletion of the function table. 7... CPU, 8... ROJ 9...
- R No. Jν1, no 0...I10 port, l...data bus, 12...address bus. Patent amount □ Applicant Oki Electric Industry Co., Ltd. Figure 3 Figure 4 Figure 5
Claims (1)
行するフ0リンタの制御方式において、プリンタ内部に
上記機能コード格納用の機能テーブルを備え、該テーブ
ルの予め機能毎に割シ当てられたアドレスに外部装置に
決められた該機能に対する機能コード及び未使用機能を
示す特定コードを予め外部装置から転送し格納しておき
、以降外部装置から転送される機能コードよシ上記機能
テーブル内を調べて該コードに対する機能を知ることを
特徴とするプリンタの制御方式。In a printer control system that executes a function using a function code transferred from an external device, a function table for storing the above function code is provided inside the printer, and an address assigned to each function in advance in the printer is stored. The function code for the determined function and a specific code indicating an unused function are transferred and stored in advance from the external device to the external device, and thereafter the function code transferred from the external device is checked in the above function table and the function code is checked. A printer control method characterized by knowing functions for codes.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP58135141A JPS6027936A (en) | 1983-07-26 | 1983-07-26 | Control system of printer |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP58135141A JPS6027936A (en) | 1983-07-26 | 1983-07-26 | Control system of printer |
Publications (1)
Publication Number | Publication Date |
---|---|
JPS6027936A true JPS6027936A (en) | 1985-02-13 |
Family
ID=15144760
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP58135141A Pending JPS6027936A (en) | 1983-07-26 | 1983-07-26 | Control system of printer |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPS6027936A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS6116321A (en) * | 1984-07-03 | 1986-01-24 | Hitachi Ltd | Printer function designating method of printer device control system |
US4768053A (en) * | 1985-12-25 | 1988-08-30 | Minolta Camera Kabushiki Kaisha | Distance measuring apparatus |
-
1983
- 1983-07-26 JP JP58135141A patent/JPS6027936A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS6116321A (en) * | 1984-07-03 | 1986-01-24 | Hitachi Ltd | Printer function designating method of printer device control system |
US4768053A (en) * | 1985-12-25 | 1988-08-30 | Minolta Camera Kabushiki Kaisha | Distance measuring apparatus |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP0156392B1 (en) | Printing apparatus | |
JP2615137B2 (en) | Printing device | |
JPS6027936A (en) | Control system of printer | |
JPS6141432B2 (en) | ||
JPH0210974B2 (en) | ||
JPS6214689A (en) | Character output controller | |
JPS60232974A (en) | Printer | |
JPH0552278B2 (en) | ||
JPS59167745A (en) | Printer | |
US11531853B2 (en) | Printing device and control method for printing device | |
US4941109A (en) | Method of effectively performing a feed operation and printing apparatus for realizing the method | |
JPS6113993B2 (en) | ||
JPS6239738B2 (en) | ||
JPH01150568A (en) | Printer device | |
JPS61143172A (en) | Printer | |
JPS60107374A (en) | Printer | |
JP3537475B2 (en) | Character display device | |
JPH09205467A (en) | Application program execution system in data communication terminal equipment | |
JPH0592649A (en) | Label printer | |
JPS61208151A (en) | Device for deciding capacity of data storage device | |
JPS6061830A (en) | Printer control system | |
JPH0193857A (en) | Document printer | |
JPS63261388A (en) | Character data outputting system for data processor | |
JPH06312544A (en) | Printer | |
JPS61239951A (en) | Composite printer |