Page 2
“GS I (n = 250, 251)”were deleted 1.02 2005/04/25 Change of code pages 1.03 2006/10/26 Add 4.5 Black Mark Layout and Operating Condition CITIZEN is a registered trade mark of CITIZEN WATCH CO., LTD., Japan. CITIZEN es una marca registrada de CITIZEN WATCH CO., LTD., Japón.
TABLE OF CONTENTS 1. OUTLINE ......................6 1.1 Operation Mode .......................6 1.2 Character Set......................6 1.3 Control Commands ....................6 1.3.1 Control Command Details ..................6 1.3.2 How to Send Control Commands ................6 2. CONTROL COMMANDS ..................7 2.1 ESC/POS Command List ..................7 2.1.1 Description of Items .....................11 2.2 Command Details ....................12 2.2.1 Print Control Commands..................12...
Page 4
GS $ nL nH.......................... 42 GS L nL nH.......................... 43 GS T n ..........................44 GS W nL nH ........................45 GS \ nL nH ........................47 2.2.4 Line Feed Span Commands ...................48 ESC 2 ..........................48 ESC 3 n ..........................49 2.2.5 Bit Image Commands....................50 ESC * m n1 n2 [d]k ......................
Page 5
2.2.12 Commands for Non-volatile Memory ..............82 GS ( C pL pH m fn b [c1 c2] [d1...dk] ................. 82 fn = 0, 48: Function 0 Erasing Specified Record...............83 fn = 1, 49: Function 1 Storing Data to Specified Record ............83 fn = 2, 50: Function 2 Sending Data Stored in Specified Record ..........84 fn = 3, 51: Function 3 Sending Use Amount ................85 fn = 4, 52: Function 4 Sending Remaining Capacity ..............85...
Page 6
2.2.14 Special Commands ....................120 ESC n n ..........................120 ESC Y n1 n2 ........................120 GS R 0..........................121 GS R 1 n..........................121 GS S ..........................122 FS ( L pL pH fn m......................123 fn = 48: Function 48 Sending Position Information..............124 fn = 66: Function 66 Executing Paper Feeding to Cut Position..........
Page 7
3. CHARACTER CODE TABLE ................147 3.1 Code Page ......................147 3.1.1 Code page 00H to 7FH & PC437 (USA、Europe Standard)........147 3.1.2 Code page 00H to 7FH & Katakana ..............148 3.1.3 Code page 00H to 7FH & PC850 (Multilingual) ...........149 3.1.4 Code page 00H to 7FH & PC860 (Portuguese)............150 3.1.5 Code page 00H to 7FH &...
Some methods are available for sending Control Commands from the host computer to the printer. Here, a method of sending by BASIC programming is explained. Example 1 Let’s print a character string “CITIZEN” in enlarged (double-height, double-width) and in normal format. Program coding The Control Command shows that the command name for setting the size of a character is GS !.
2. CONTROL COMMANDS 2.1 ESC/POS Command List ○Print Control Commands Command Function MODE GS P Page S・P Printing and paper feed Back to printing S・P (1) Printing in PAGE MODE and returning to STANDARD MODE (at the selection of PAGE MODE) (2) Printing of Black mark and paper feeding to the top of the print position (with Black mark paper...
○Print Position Commands Command Function MODE GS P Page Horizontal tab S・P S・P ESC $ Specifying the absolute positions ○ S・P ESC D Setting horizontal tab position Selecting the character printing direction in PAGE ESC T MODE ESC W Defining the print area in PAGE MODE ○...
○Cutter Commands Command Function MODE GS P Page ESC i Full cutting of paper ESC m Full cutting of paper S・P Cutting the paper ○ ○Bar Code Commands Command Function MODE GS P Page S・P Selecting of printing position of HRI characters S・P Selecting the font of HRI characters Specifying the height of the bar code...
○Other Commands Command Function MODE GS P Page DLE ENQ Real-time request to printer S・P S・P DLE DC4 Buffer clear S・P ESC = Data input control ESC @ Initializing the printer S・P ESC L Selecting PAGE MODE ESC S Selecting STANDARD MODE S・P ESC RS Sound buzzer...
2.1.1 Description of Items XXXX [Function] The name of a command. [Code] The string of codes comprising the command is represented by < >H for hexadecimal numbers, < >B for binary numbers, and < > for decimal numbers, [ ] k denotes the number of repetition of “k”...
2.2 Command Details 2.2.1 Print Control Commands [Function] Printing and paper feed [Code] <0A>H [Outline] Prints data inside the print buffer and feeds paper based on the line feed amount having been set. [Caution] After this command is executed, the beginning of the line is taken as the start position for the next point.
Page 15
[Function] (1) Printing in PAGE MODE and returning to STANDARD MODE (at the selection of PAGE MODE) (2) Printing of Black mark and paper feeding to the top of the print position (with Black mark paper selected) [Code] <0C>H (1) At selection of PAGE MODE [Outline] Executes a batch printout of the data mapped in the entire print area, and then returns to STANDARD MODE.
ESC FF [Function] Printing data in PAGE MODE [Code] <1B>H<0C>H [Outline] Executes a batch printout of the data mapped in the entire print area in PAGE MODE. [Caution] • This command is only effective when PAGE MODE is selected. • Mapped data, as well as the ESC T and ESC W settings, and the character mapping position are held even after printing.
ESC J n [Function] Printing and feeding paper in minimum pitch [Code] <1B>H<4A>H<n> [Range] 0≦n≦255 [Outline] Prints the data held in the print buffer and feeds paper by [n b asic calculation pitch] ・ inches. [Caution] • After this command is executed, the beginning of the line is taken as the start position for the next print.
ESC d n [Function] Printing and feeding the paper by “n” lines [Code] <1B>H<64>H<n> [Range] 0≦n≦255 [Outline] Prints data in the print buffer and feeds paper by “n” lines. Specified lines do not remain. [Caution] • After this command is executed, the beginning of the line is taken as the start position for the next print.
2.2.2 Print Character Commands [Function] Canceling print data in PAGE MODE [Code] <18>H [Outline] Erases all data contained in the currently effective print area in PAGE MODE. [Caution] • This command is only effective when PAGE MODE is selected. • If the previously established print area overlaps the currently effective print area, the overlapped data in the previously established area will be erased.
ESC SP n [Function] Setting the right spacing of the character [Code] <1B>H<20>H<n> [Range] 0≦n≦255 [Outline] Sets the right spacing of character to [n×basic calculation pitch] inches. [Caution] • If the horizontal magnification of character is 2 or more, the right spacing increases with the magnification.
ESC ! n [Function] Collectively specifying the printing mode [Code] <1B>H<21>H<n> [Range] 0≦n≦255 [Outline] Printing mode is assigned. Value Function Character Font Font A (12×24) Font B(9×17) Undefined ―― ―― Undefined ―― ―― Emphasis Canceled Specified Double height Canceled Specified Double width Canceled Specified...
Page 22
[Sample Program] LPRINT CHR$(&H1B);"!";CHR$(&H00);"H"; LPRINT CHR$(&H1B);"!";CHR$(&H01);"H"; LPRINT CHR$(&H1B);"!";CHR$(&H08);"H"; LPRINT CHR$(&H1B);"!";CHR$(&H10);"H"; LPRINT CHR$(&H1B);"!";CHR$(&H20);"H"; LPRINT CHR$(&H1B);"!";CHR$(&H80);"H"; LPRINT CHR$(&H1B);"!";CHR$(&HB9);"H"; LPRINT CHR$(&HA); [Print Results] Font B + Emphasis + Quadruple + Underline Font A + Underline Font A + Double width Font A + Double height Font A + Emphasis Font B Font A...
ESC % n [Function] Specifying/canceling download character set [Code] <1B>H<25>H<n> [Range] 0≦n≦255 [Outline] Specifying/canceling download characters. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Function Canceling download character set Specifying download character set [Default] n = 0...
ESC & s n m [a [p] s×a] m-n+1 [Function] Defining the download characters [Code] <1B>H<26>H<s>H<n>H<m>H[<a>H<p1>H<p2>…<ps×a>]m-n+1 [Range] s=3(FontA, B) s=2(FontC) 32≦n≦m≦126 0≦a≦12(FontA)、0≦a≦9 (FontB)、0≦a≦8 (FontC) 0≦p1…ps×a≦255 [Outline] Defines the font of download characters of alphanumeric characters. • “s” indicates the number of bytes in vertical direction. “n” indicates the start character code and “m”...
ESC – n [Function] Specifying/canceling underline [Code] <1B>H<2D>H<n> [Range] 0≦n≦2、48≦n≦50 [Outline] Specifying/canceling an underline. Function 0,48 Canceling underline 1,49 Setting 1-dot width underline 2,50 Setting 2-dot width underline [Caution] • An underline is attached to the full character width. It is, however, not attached to the part having been skipped by horizontal tab (HT) command.
ESC ? n [Function] Deleting download characters [Code] <1B>H<3F>H<n> [Range] 32≦n≦126 [Outline] Deletes the downloaded characters of specified code. [Caution] • The character “n” indicates the character code used to delete the defined pattern. After the deletion, characters are printed in the same pattern as the internal characters.
ESC E n [Function] Specifying/canceling emphasis printing [Code] <1B>H<45>H<n> [Range] 0≦n≦255 [Outline] Specifying/canceling the emphasized characters. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Function Canceling emphasis printing Specifying emphasis printing [Caution] •...
ESC G n [Function] Specifying/canceling double strike printing [Code] <1B>H<47>H<n> [Range] 0≦n≦255 [Outline] Specifying/canceling the double strike printing. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Function Canceling double strike printing Specifying double strike printing [Caution]...
ESC M n [Function] Selection of character fonts [Code] <1B>H<4D>H<n> [Range] 0≦n≦2、48≦n≦50 [Outline] Selects character fonts. Function Selection of font A(12×24) 0,48 Selection of font B(9×24) 1,49 Selection of font C(8×16) 2,50 [Caution] ESC ! can also select fonts, but the setting made by the command that has last been processed becomes valid.
ESC V n [Function] Specifying/canceling 90°-right-turned characters [Code] <1B>H<56>H<n> [Range] 0≦n≦2、48≦n≦50 [Outline] Specifying/canceling 90°-right-turned characters. Function 0,48 Canceling 90°-right-turned characters 1,49 Specifying 90°-right-turned characters 2,50 [Caution] • No underlines are attached to 90°-right-turned characters. • This command does not affect PAGE MODE but setting is maintained. [Default] n=0 [Sample Program]...
ESC t n [Function] Selecting the character code table [Code] <1B>H<74>H<n> [Range] 0≦n≦9、16≦n≦19、n=26、40、255 [Outline] Selecting the character code table. The character code table is selected based on the value of “n”. Character Code Table Character Code Table Code page PC437 7,17 Code page PC866 Katakana...
ESC { n [Function] Specifying/canceling the inverted characters [Code] <1B>H<7B>H<n> [Range] 0≦n≦255 [Outline] Specifying/canceling inverted characters. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Condition Canceling inverted characters. Specifying inverted characters.
GS ! n [Function] Specifying the character size [Code] <1D>H<21>H<n> [Range] 0≦n≦255 where: 1≦vertical magnification≦8、1≦horizontal magnification≦8 [Outline] Specifies the character size (Vertical and horizontal magnification). Value Function Hex. Number Decimal Number Vertical magnification Refer to Table 2, specification “Vertical Magnification”. Horizontal magnification Refer to Table 1, specification...
GS B n [Function] Specifying/canceling the black/white inverted printing [Code] <1D>H<42>H<n> [Range] 0≦n≦255 [Outline] This command specifies or cancels the black/white inverted printing. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Function The black/white inverted printing is canceled.
GS b n [Function] Specifying/canceling the smoothing [Code] <1D>H<62>H<n> [Range] 0≦n≦255 [Outline] This command specifies or cancels the smoothing. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Function The smoothing is canceled.
2.2.3 Print Position Commands [Function] Horizontal tab [Code] <09>H [Outline] Shifts the printing position to the next horizontal tab position. • Ignored when the next horizontal tab position has not been set. [Caution] The horizontal tab position is set by ESC D. [Default] At the selection of font A, tabs are set every 8 characters (at 9th, 17th, 25th, ...) with right space amount of a character set at 0 and horizontal enlargement rate of a...
ESC $ n1 n2 [Function] Specifying the absolute positions [Code] <1B>H<24>H<n1><n2> [Range] 0≦n1≦255 0≦n2≦255 [Outline] The printing start position is specified by the absolute position from the left margin with the number of dots divided by 256 and quatient specified as “n2” and remainder as “n1”.
ESC D [n]k NULL [Function] Setting horizontal tab position [Code] <1B>H<44>H [<n>] k <00>H [Range] 1≦n≦255 0≦k≦32 [Outline] Specifying a horizontal tab position. • “n” indicates the number of columns from the beginning to the horizontal tab position. Note, however, that “n = set position – 1”. For example, to set the position at 9th column, n = 8 is to be specified.
ESC T n [Function] Selecting the character printing direction in PAGE MODE [Code] <1B>H<54>H<n> [Range] 0≦n≦3、48≦n≦51 Printing Start Point Direction Top left 0,48 Left to right (“A” in the figure) Bottom left 1,49 Bottom to top (“B” in the figure) Bottom right 2,50 Right to left...
ESC W xL xH yL yH dxL dxH dyL dyH [Function] Defining the print area in PAGE MODE [Code] <1B>H<57>H<xL><xH><yL><yH><dxL><dxH><dyL><dyH> [Range] 0≦xL, xH, yL, yH, dxL, dxH, dyL, dyH ≦255 except for dxL=dxH=0 or dyL=dyH=0 [Outline] Defines the location and size of the print area. •...
Page 41
Paper (X, Y) Dx Print Area Dy (X+Dx-1, Y+Dy-1) The printable area for this printer is approximately 80.078 mm (640/203 inches) horizontally and 117 mm (938/203 inches) vertically. [Default] xL=xH=yL=yH=0、dxL=64、dxH=2、dyL=126、dyH=6 [See Also] Appendix 4.1 “Explanation on PAGE MODE” CAN, GS P - 39 -...
ESC \ nL nH [Function] Specifying the relative position [Code] <1B>H<5C>H<nL><nH> [Range] 0≦nL≦255 0≦nH≦255 [Outline] This command specifies the next print start position in a relative position with respect to the current position. The next print start position will be at a point of [(nL+nH×256) ×basic calculation pitch] inches away from the current position.
ESC a n [Function] Aligning the characters [Code] <1B>H<61>H<n> [Range] 0≦n≦2、48≦n≦50 [Outline] All the printed data within one line are aligned in the specified position. Depending on the value “n”, positional alignment is carried out as shown in the table below: Position 0,48...
GS $ nL nH [Function] Specifying the absolute vertical position of characters in PAGE MODE [Code] <1D>H<24>H<nL><nH> [Range] 0≦nL≦255、0≦nH≦255 [Outline] Specifies the vertical position of character at the start point of data development in PAGE MODE using absolute position based on the start position. The position of vertical direction of character at the start position of next data development is the position [(nL + nH×256)×basic calculation pitch] from the start position.
GS L nL nH [Function] Setting the left margin [Code] <1D>H<4C>H<nL><nH> [Range] 0≦nL≦255、0≦nH≦255 [Outline] This command sets the left margin specified by nL and nH. The value of the left margin is [(nL+nH×256)×basic calculation pitch] inches. Printable area Left margin Print area width [Caution] •...
GS T n [Function] Moving print position to top of the line [Code] <1D>H<54>H<n> [Range] n=0, 1, 48, 49 [Outline] Moves print position to top of the line. • “n” specifies data processing in print buffer at the execution of this command. Function n...
GS W nL nH [Function] Setting the print area width [Code] <1D>H<57>H<nL><nH> [Range] 0≦nL≦255 0≦nH≦255 [Outline] Sets the print area width specified by nL and nH. • The print area width will be [(nL+nH×256)×basic calculation pitch] inches. Printable area Left margin Print area width [Caution] •...
Page 48
(2) If a sufficient area cannot be provided as a result of step (1), the print area is extended toward the left (so, the left margin is decreased). Printable area A (1) Extended Left margin toward the right (2) The left margin is trimmed Print area width (3) If a sufficient area cannot be provided as a result of step (2), the right spacing is trimmed.
GS \ nL nH [Function] Specifying the relative vertical position of a character in PAGE MODE [Code] <1D>H<5C>H<nL><nH> [Range] 0≦nL≦255、0≦nH≦255 [Outline] This command is used in PAGE MODE to specify the vertical position of a character in the data mapping start position, in a relative position with respect to the current position.
2.2.4 Line Feed Span Commands ESC 2 [Function] Specifying 1/6-inch line feed rate [Code] <1B>H<32>H [Outline] The line feed rate per line is specified by 1/6 inch. [Caution] Line feed rate can be specified respectively for both STANDARD MODE and PAGE MODE. [Sample Program] [Print Results] LPRINT "AAAAA";CHR$(&HA);...
ESC 3 n [Function] Setting line feed rate of minimum pitch [Code] <1B>H<33>H<n> [Range] 0≦n≦255 [Outline] Sets the line feed width per line to [n b asic calculation pitch] inches. ・ [Caution] • The line feed width can be set separately for the STANDARD and PAGE MODES. •...
2.2.5 Bit Image Commands ESC * m n1 n2 [d]k [Function] Specifying the bit image mode [Code] <1B>H<2A>H<m>H<n1><n2>[<d>] k [Range] m=0, 1, 32, 33 0≦n1≦255 0≦n2≦2 0≦d≦255 k=n1+256×n2(m=0, 1) k=(n1+256×n2)×3(m=32, 33) [Outline] • According to the number of dots specified in “n1”, “n2”, specify the bit image of mode “m”.
GS * n1 n2 [d] n1×n2×8 [Function] Defining the download bit image [Code] <1D>H<2A>H<n1><n2>[<d>] n1×n2×8 [Range] 1≦n1≦255 1≦n2≦48 n1×n2≦1536 [Outline] • Defines download bit images of the number of dots specified by “n1” and “n2”. • The numbers of dots are “n1×8” in horizontal direction and “n2 8 ” in vertical ・...
[Sample Program] [Print Results] GOSUB IMG LPRINT CHR$(&H1D);"/"; CHR$(0); LPRINT CHR$(&H1D);"/"; CHR$(1); LPRINT CHR$(&H1D);"/"; CHR$(2); LPRINT CHR$(&H1D);"/"; CHR$(3); IMG: n1=10:n2=5 LPRINT CHR$(&H1D);"*"; LPRINT CHR$(n1); CHR$(n2); FOR J=1 TO n1*8 FOR I=1 TO n2 LPRINT CHR$(J); NEXT I NEXT J RETURN GS / m [Function] Printing the downloaded bit image...
GS v 0 m xL xH yL yH d1...dk [Function] Printing of raster bit image [Code] <1D>H<76>H<30>H<m><xL><xH><yL><yH> [<d>] k [Range] 0≦m≦3、48≦m≦51、0≦xL≦255、0≦xH≦255、0≦yL≦255、0≦yH≦8、0≦d≦255、 k=(xL+xH×256)×(yL+yH×256) however, k≠0 [Outline] Prints raster bit images in mode “m”. • xL, xH specify the number of data in horizontal direction of the bit image to (xL+xH×256) bytes.
2.2.6 Status Commands DLE EOT n [Function] Sending status in real-time [Code] <10>H<04>H<n> [Range] 1≦n≦6 [Outline] Sends in real-time the status specified by “n”. Status Printer status Status caused by an offline condition Status caused by an error Continuous paper sensor Error details 1 Error details 2 [Caution]...
Page 59
(1) Printer status (When n = 1 is specified) Status Hex. Decimal Fixed Fixed Fixed Online status Offline status Fixed Not waiting online recovery Waiting online recovery FEED switch is not pressed FEED switch is pressed Fixed (2) Status caused by an offline condition (When n = 2 is specified) Status Hex.
Page 60
(4) Continuous paper sensor (When n = 4 is specified) Status Hex. Decimal Fixed Fixed Paper found by Paper Near-end 1 Sensor Paper not found by Paper Near-end 1 Sensor Paper found by Paper Near-end 2 Sensor Paper not found by Paper Near-end 2 Sensor Fixed Paper found by Paper-end Sensor Paper not found by Paper-end Sensor...
ESC v (At Serial I/F Selection) [Function] Sending printer status [Code] <1B>H<76>H [Outline] Sends the current status of the printer. [Caution] • The status to be sent is one byte and the content is shown in the following table. • With DTR/DSR control, after confirming that the host is ready for reception (DSR signal is space), only one byte is transmitted.
GS a n [Function] Enabling/disabling ASB (Automatic Status Back) [Code] <1D>H<61>H<n> [Range] 0≦n≦255 [Outline] This command selects the status item to be addressed by ASB (Automatic Status Back.) Status Item Addressed by ASB Hex. Decimal Undefined - - Online/offline status = Disabled Online/offline status = Enabled Error status = Disabled Error status = Enabled...
Page 63
(1) 1st byte (Printer information) Status Hex. Decimal Unused Unused Unused Online status Offline status Unused Cover closed Cover open Not in paper feed state triggered by FEED switch In paper feed state triggered by FEED switch Unused (2) 2nd byte (Error occurrence information) Status Hex.
Page 64
(4) 4th byte (Paper Sensor information) Status Hex. Decimal Reserved Reserved Reserved Reserved Fixed Reserved Reserved Fixed [Default] When memory switch 1-3 is OFF: n = 0 When memory switch 1-3 is ON: n = 2 [See Also] EOT, GS r - 62 -...
GS r n [Function] Sending status [Code] <1D>H<72>H<n> [Range] n=1, 49 [Outline] Sends the specified status to the host. Function 1,49 Sends the Paper Sensor status. [Caution] • When the serial interface is used: For DTR/DSR control: The printer sends the status after verifying that the host is ready to receive. If the host is not ready to receive, the printer waits for the host to become ready to receive.
2.2.7 Paper Detecting Commands ESC c 3 n [Function] Selecting the Paper Sensor valid for a Paper-end signal output [Code] <1B>H<63>H<33>H<n> [Range] 0≦n≦255 [Outline] This command selects by which Paper Sensor a Paper-end signal should be output. Each bit for “n” has the following meaning: Value Position Paper Near-end 1...
ESC c 4 n [Function] Selecting the Paper Near-end Sensor valid for print stop [Code] <1B>H<63>H<34>H<n> [Range] 0≦n≦255 [Outline] This command selects the Paper Near-end Sensor which helps to stop printing when the paper supply almost runs out. Each bit for “n” has the following meaning: Value Position Paper Near-end 1...
2.2.8 Panel Switch Commands ESC c 5 n [Function] Enabling/disabling the panel switches [Code] <1B>H<63>H<35>H<n> [Range] 0≦n≦255 [Outline] Enabling/disabling the FEED switch. • “n” is valid only for the lowest bit (n0). • Control by the lowest bit (n0) is shown as follows: Condition FEED switch valid FEED switch invalid...
2.2.9 Macro Commands GS : [Function] Starting/ending macro definition [Code] <1D>H<3A>H [Outline] Specifying starting/ending macro definition. Reception of this command during macro definition signifies ending the macro definition. [Caution] • Maximum content available for macro definition is 2048 bytes. A portion exceeding 2048 bytes is not defined.
GS ^ n1 n2 n3 [Function] Executing the macro [Code] <1D>H<5E>H<n1><n2><n3> [Range] 0≦n1≦255 0≦n2≦255 0≦n3≦1 [Outline] Executing contents defined in macro. n1 : The number of times of macro execution n2 : Waiting time on macro execution. Waiting time of n2×100 msec is given for every execution.
2.2.10 Cutter Commands ESC i [Function] Full cutting of paper [Code] <1B>H<69>H [Outline] Executes full cutting of paper. [Caution] • This command only works it is entered at the beginning of a line. • Before cutting paper, feed the paper more than the cutting position of paper from the print position.
ESC m [Function] Full cutting of paper [Code] <1B>H<6D>H [Outline] Executes full cutting of paper. [Caution] • This command only works it is entered at the beginning of a line. • Before cutting paper, feed the paper more than the cutting position of paper from the print position.
GS V m … (1) GS V m n … (2) [Function] Cutting the paper [Code] (1)<1D>H<56>H<m> (2)<1D>H<56>H<m><n> [Range] (1)0≦m≦1、48≦m≦49 (2)65≦m≦66 [Outline] Performs the specified paper cutting. Function 0,48 Full cut 1,49 Full cut Paper feed by “cut position + basic calculation pitch” and full cut Paper feed by “cut position + basic calculation pitch”...
2.2.11 Bar Code Commands GS H n [Function] Selecting of printing position of HRI characters [Code] <1D>H<48>H<n> [Range] 0≦n≦3、48≦n≦51 [Outline] Selecting printing position of HRI characters in printing bar codes. “n” means the followings. Printing Position n 0,48 No printing 1,49 Above the bar code 2,50...
GS f n [Function] Selecting the font of HRI characters [Code] <1D>H<66>H<n> [Range] 0≦n≦2、48≦n≦50 [Outline] Selecting the font of HRI characters in printing bar code. The type of font can be selected with “n” as follows: Font n 0,48 FontA(12×24) 1,49 FontB(9×24) 2,50...
GS h n [Function] Specifying the height of the bar code [Code] <1D>H<68>H<n> [Range] 1≦n≦255 [Outline] Selecting bar code height. “n” denotes the number of dots in the vertical direction. [Default] n=162 [See Also] GS w [Sample Program] Refer to Sample Program and Print Results for GS w. - 74 -...
GS k m [d1...dk] NULL … (1) GS k m n [d1...dn] … (2) [Function] Printing the bar code [Code] (1)<1D>H<6B>H<m>[d1...dk] NULL (2)<1D>H<6B>H<m><n>[d1...dn] [Range] (1)0≦m≦6 The definitions of “k” and “d” vary with the bar code system. (2)65≦m≦73 The definitions of “n” and “d” vary with the bar code system. [Outline] Selects a bar code system and prints the bar code.
Page 78
[Caution] For (1): • This command ends with a NULL code. • For UPC-A or UPC-E, the bar code is printed when 12 bytes of bar code data have been entered, and the subsequent data is handled as normal data. •...
Page 79
[Description of Bar Codes] UPC-A This bar code, consisting of numerals only, has a fixed length of 12 columns; a 11- column number entered from the host or application software plus a check digit (12th column) automatically calculated inside the printer. If the 12th-column numeral is sent from the host, the entire bar code will be printed as it is.
Page 80
Control Character Control Character HRI Character HRI Character ASCII Hex. ASCII Hex. NULL ■U ■P ■A ■Q ■B ■R ■C ■S ■D ■T ■E ■U ■F ■V ■G ■W ■H ■X ■I ■Y ■J ■Z ■K ■A ■L ■B ■M ■C ■N ■D...
Page 81
Special characters Hex. ASCII Code Set A Code Set B Code Set C 7B53 SHIFT SHIFT -N/A 7B41 -N/A CODE A CODE A 7B42 CODE B -N/A CODE B 7B43 CODE C CODE C -N/A 7B31 FNC1 FNC1 FNC1 7B32 FNC2 FNC2 -N/A...
Page 82
[Bar Code Print Example] UPC-A, UPC-E, JAN-13 (EAN), JAN-8 (EAN), CODE 39, ITF, CODABAR, CODE 93, CODE 128 Type Print Sample Outline of Symbol 12-column fixed-length bar code UPC-A consisting of numerals only. 8-column fixed-length bar code UPC-E consisting of numerals only. Abbreviated version of UPC-A.
2.2.12 Commands for Non-volatile Memory GS ( C pL pH m fn b [c1 c2] [d1...dk] [Function] Editing user NV memory [Outline] • Erases/stores/sends data of user NV memory area and sends the use amount/remaining capacity. • Executes edit processing of user NV memory specified by function code (fn). Code Function.
fn = 0, 48: Function 0 Erasing Specified Record GS ( C pL pH m fn b c1 c2 [Code] <1D>H<28>H<43>H<pL><pH><m><fn><b>[c1 c2] [Range] (pL+pH×256)=5(pL=5, pH=0) m=0 fn=0,48 32≦c1≦126 32≦c2≦126 [Outline] Erases the record specified by c1, c2 stored in user NV memory. fn = 1, 49: Function 1 Storing Data to Specified Record GS ( C pL pH m fn b c1 c2 d1...dk [Code]...
fn = 2, 50: Function 2 Sending Data Stored in Specified Record GS ( C pL pH m fn b c1 c2 [Code] <1D>H<28>H<43>H<pL><pH><m><fn><b>[c1 c2] [Range] (pL+pH×256)=5(pL=5, pH=0) m=0 fn=2, 50 b=0 32≦c1≦126 32≦c2≦126 [Outline] Sends data stored in the record specified by c1, c2 in user NV memory. Hex.
fn = 3, 51: Function 3 Sending Use Amount GS ( C pL pH m fn b [Code] <1D>H<28>H<43>H<pL><pH><m><fn><b> [Range] (pL+pH×256)=3(pL=3, pH=0) m=0 fn=3, 51 b=0 [Outline] Sends the use amount of user NV memory (number of bytes of used area). Hex.
fn = 5, 53: Function 5 Sending Key Code List of Stored Record GS ( C pL pH m fn b [Code] <1D>H<28>H<43>H<pL><pH><m><fn><b> [Range] (pL+pH×256)=3(pL=3, pH=0) m=0 fn=5, 53 b=0 [Outline] Sends key code list of record existing in user NV memory. Hex.
fn = 6, 54: Function 6 Erasing All User NV Memory Area in a Lump GS ( C pL pH m fn b [d1 d2 d3] [Code] <1D>H<28>H<43>H<pL><pH><m><fn><b>[d1 d2 d3] [Range] (pL+pH×256)=6 (pL=6, pH=0) m=0 fn=6, 54 b=0 d1=67 d2=76 d3=82 [Outline] Erases all areas of user NV memory in a lump.
FS p n m [Function] Printing the download NV bit images [Code] <1C>H<70>H<n><m> [Range] 1≦n≦255、0≦m≦3、48≦m≦51 [Outline] This command prints the download NV bit images (n) using a specified mode (m). Dot Density in Dot Density in Mode Name Vertical Direction Horizontal Direction 0,48 NORMAL MODE...
FS q n [xL xH yL yH d1…dk]1 … [xL xH yL yH d1…dk]n [Function] Defining the download NV bit image [Code] <1C>H<71>H<n>[<xL><xH><yL><yH><d1...dk>]1 ... [<xL><xH><yL><yH><d1...dk>]n [Range] 1≦n≦255 0≦xL≦255 0≦xH≦3 but, 1≦(xL+xH×256)≦1023 0≦yL≦255 0≦yH≦1 but, 1≦(yL+yH×256)≦288 0≦d≦255 k=(xL+xH×256)×(yL+yH×256)×8 Total definition area = 2M bits (256K bytes) [Outline] This command defines the specified NV bit image.
Page 92
• The definition will start from NV bit image number 01H and n-number bit images will be defined in ascending order. Therefore, the first data group [xL xH yL yH d1…dk] becomes NV bit image number 01H, and the last data group [xL xH yL yH d1…dk] becomes NV bit image number 0nH.
2.2.13 Printer Function Setting Commands GS ( E pL pH fn […] [Function] Printer function setting command [Outline] Printer function setting command is a command to change the function of the printer stored on the non-volatile memory and executes the function set by the value of “fn”. Function No.
fn = 1: Function 1 Transferring to Printer Function Setting Mode GS ( E pL pH fn d1 d2 [Code] <1D>H<28>H<45>H<pL><pH><fn><d1><d2> [Range] (pL+pH×256)=3 (pL=3, pH=0) fn=1 d1=73(“I”) d2=78(“N”) [Outline] Transfers to printer function setting mode and sends the report of mode transfer. Hex.
fn = 3: Function 3 Setting Memory Switch Value GS ( E pL pH fn [a1 b18...b11] ... [ak bk8...bk1] [Code] <1D>H<28>H<45>H<pL><pH><fn>[a1 b18...b11] ... [ak bk8...bk1] [Range] 10≦(pL+pH×256)≦65535 fn=3 a=1、2、3、4 b=48、49、50 [Outline] • Changes the memory switch set in “a” to the value set in “b”. Function Sets corresponding bit to OFF.
Page 97
• Setting memory switch 2 (a = 2) b (Set Value) Function 49 (Default) Reserved Disables auto cutter. 49 (Default) Enables auto cutter. Enables stored printing. 49 (Default) Disables stored printing. Sets printing at full columns to be the same as CBM1000. 49 (Default) Sets printing at full columns to be the same as EPSON.
• Setting memory switch 4 (a = 4) b (Set Value) Function 48 (Default) Undefined 48 (Default) Undefined 48 (Default) Executes initialization at power on. Does not execute initialization at power on. 48 (Default) Does not perform collecting operation. Performs collecting operation. 48 (Default) Backward collection Forward eject...
fn = 5: Function 5 Setting Customized Value GS ( E pL pH fn [a1 n1L n1H] ... [ak nkL nkH] [Code] <1D>H<28>H<45>H<pL><pH><fn>[a1 n1L n1H] ... [ak nkL nkH] [Range] 4≦(pL+pH×256)≦65535 fn=5 a=1、2、5、6、97、116、117 1≦(nL+nH×256)≦65535 [Outline] • Sets the customized value set in “a” to (nL+nH×256). Function Specifies user NV memory capacity.
Page 100
• a = 5: Sets printing density to the level specified by (nL+nH×256). (nL+nHx256) Printing Density 65530 65531 65532 65533 65534 65535 0 (Default) 100% 105% 110% 115% 120% 125% 130% 135% 140% • a = 6: Sets printing speed to the value specified by (nL+nH×256). (nL+nHx256) Printing Speed Printing speed level 1 (84%)
Page 101
[Caution] • This function operates only in printer function setting mode. • The value changed by this command is enabled by the following. • Execution of function 2 (fn = 2: End of printer function setting mode) (Recommended) • Reentering power supply. •...
fn = 6: Function 6 Sending the Set Customized Value GS ( E pL pH fn a [Code] <1D>H<28>H<45>H<pL><pH><fn>[a] [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=6 a=1、2、5、6、97、116、117 [Outline] • Sends the set value of customized value set by “a”. Hex. No. of Data Header Customized value No.
Page 103
• a = 2: When NV graphics memory capacity is specified* Setting Status Sending Data Stored Memory 1st Byte 2nd Byte 3rd Byte 4th Byte 5th Byte Value Capacity None 49(“1”) ― ― ― ― 64K bytes 50(“2”) ― ― ―...
Page 104
• a = 97: When number of divisions for head conducting is specified Setting Status Sending Data Stored No. of 1st Byte 2nd Byte 3rd Byte 4th Byte 5th Byte Value Divisions 2 division 50(“2”) ― ― ― ― conducting 4 division 52(“4”) ―...
fn = 7: Function 7 Copying User-defined Page GS ( E pL pH fn a d1 d2 [Code] <1D>H<28>H<45>H<pL><pH><fn><a>[d1 d2] [Range] (pL+pH×256)=4 (pL=4、pH=0) fn=7 a=10、12、17 [Outline] • Copies the data of user-defined code page in the font specified by “a”. Font Type Font A: 12 (horizontal)×24 (vertical) Font B: 9 (horizontal)×17 (vertical)
fn = 8: Function 8 Defining Data by the Column Format to Character Code Page of Work Area GS ( E pL pH fn y c1 c2 [x d1...d(y×x)] k [Code] <1D>H<28>H<45>H<pL><pH><fn><y><c1><c2>[x d1... d(y×x)]k [Range] 5≦(pL+pH×256)≦65535 fn=8 y=2 (At selection of font C) y=3 (At selection of other than font C) 128≦c1≦c2≦255 0≦x≦12 (At selection of font A)
fn = 9: Function 9 Defining Data in the Raster Format to the Character Code Page of Work Area GS ( E pL pH fn x c1 c2 [y d1...d(y×x)] k [Code] <1D>H<28>H<45>H<pL><pH><fn><x><c1><c2>[y d1 ... d(y×x)]k [Range] 5≦(pL+pH×256)≦65535 fn=9 y=1 (At selection of font C) y=2 (At selection of other than font C) 128≦c1≦c2≦255 0≦y≦24 (At selection of font A)
fn = 10: Function 10 Erasing Data of Character Code Page Data in Work Area GS ( E pL pH fn c1 c2 [Code] <1D>H<28>H<45>H<pL><pH><fn><c1><c2> [Range] (pL+pH×256)=3 fn=10 128≦c1≦c2≦255 [Outline] • Erases (set to space) data in units of character on the character code page in work area.
fn = 11: Function 11 Setting Communication Conditions of Serial Interface GS ( E pL pH fn a d1 ... dk [Code] <1D>H<28>H<45>H<pL><pH><fn><a>[d] k [Range] 3≦(pL+pH×256)≦65535 (0≦pL≦255、0≦pH≦255) fn=11 1≦a≦4 (Not changed in other than specified range) 48≦d≦57 (Not changed in other than specified range) 1≦k≦6 [Outline] Sets the communication conditions of serial interface specified by “a”.
fn = 12: Function 12 Sending the Set Communication Conditions of Serial Interface GS ( E pL pH fn a [Code] <1D>H<28>H<45>H<pL><pH><fn><a> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=12 1≦a≦4 (Does not send in other than specified range) [Outline] Sends communication conditions of serial interface specified by “a”. Hex.
fn = 48: Function 48 Erasing Paper Layout GS ( E pL pH fn d1 d2 d3 [Code] <1D>H<28>H<45>H<pL><pH><fn><d1><d2><d3> [Range] (pL+pH×256)=4 (pL=4、pH=0) fn=48 d1=67(“C”) d2=76(“L”) d3=82(“R”) [Outline] • Defines all set values of paper layout as “State of no setting”. •...
fn = 50: Function 50 Sending Paper Layout Information GS ( E pL pH fn n [Code] <1D>H<28>H<45>H<pL><pH><fn><n> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=50 n=64、80 [Outline] Sends paper layout information specified by “n”. Type of Paper Layout Information Set value of paper layout (Unit: 0.1 mm) Effective value of paper layout (Unit: dot) Sending data is as follows: Hex.
• Configuration of “Layout information” Transmission Data 1st Byte 2nd Byte 3rd Byte 4th Byte 5th Byte 54(“6”) 52(“4”) ― ― ― 56(“8”) 48(“0”) ― ― ― • Configuration of “Layout information type” • Converts the information on each layout into character code expressed in decimal notation and sends it from the higher digit.
GS ( K pL pH fn m [Function] Selecting print control method [Outline] Executes the setting related to the print control specified by the value of “fn”. Function No. (fn) Function Function 48 Sets print control mode. Function 49 Sets printing density. Function 50 Sets printing speed.
fn = 50: Function 50 Setting Printing Speed GS ( K pL pH fn m [Code] <1D>H<28>H<4B>H<pL><pH><fn><m> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=50 0≦m≦9、48≦m≦57 [Outline] Sets printing speed. Printing Speed 0,48 Selects print control mode at power on. 1,49 Selects printing speed level 1. 2,50 Selects printing speed level 2.
Page 118
GS ( M pL pH fn m [Function] Customizing the printer [Outline] Executes processing related to escape/recovery of the value set in the work area or the data defined by various kinds of command. Function (fn) Function Function 1 Copies the set value stored in work area to the storage area. Function 2 Copies the set value stored in storage area to the work area.
fn = 1, 49: Function 1 Copies the set value stored in work area to the storage area GS ( M pL pH fn m [Code] <1D>H<28>H<4D>H<pL><pH><fn><m> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=1、49 m=1、49 [Outline] Copies the set value stored in work area to the storage area. [Caution] •...
Page 120
fn = 3, 51: Function 3 Specifies the auto loading function of the set value at initialization to be valid or invalid GS ( M pL pH fn m [Code] <1D>H<28>H<4D>H<pL><pH><fn><m> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=3、51 m=0、1、48、49 [Outline] Determines the setting of storage area at initialization to the work area by the value of “m”.
GS ( N pL pH fn m [Function] Designating font attribute [Outline] Executes processing of font attribute by the specified “fn” value. Function No. (fn) Function Selects character color. fn = 48: Function 48 Selects character color GS ( N pL pH fn m [Code] <1D>H<28>H<4E>H<pL><pH><fn><m>...
2.2.14 Special Commands ESC n n [Function] Setting the remaining amount of printout [Code] <1B>H<6E>H<n> [Range] 0≦n≦255 (“n” in the 3rd byte denotes this command.) [Outline] • This command sets the remaining amount of printout after detecting paper near-end1. • “n” is set in cm. [Caution] •...
GS R 0 [Function] Collect the receipt [Code] <1D>H<52>H<30>H [Outline] • This command have the presenter collect receipt to the direction set by MSW4-5. • When printer receives this command, if presenter sensor detects paper presence, motor is activated till sensor detects no paper. •...
GS S [Function] Detecting a black mark [Code] <1D>H<53>H [Outline] This commands detects a black mark when black mark paper is set. [Caution] • When memory switch 3-4 is OFF, this command is ignored. • When this command is received during detection of a black mark, the next black mark is detected and the print paper is cut and then ejected.
Page 125
FS ( L pL pH fn m [Function] Controlling black mark paper [Outline] Executes various kinds of control for black mark paper. • Executes the function specified by the function code (fn). Function No. Function Function 48 Sends position information. Function 66 Executes paper feeding to the cut position.
fn = 48: Function 48 Sending Position Information FS ( L pL pH fn m [Code] <1C>H<28>H<4C>H<pL><pH><fn><m> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=48 m=48 [Outline] Sends the position information of black mark paper. Transmission Data Hex. Decimal Data Size Header 1 byte Identifier 1 byte Position information A...
fn = 66: Function 66 Executing Paper Feeding to Cut Position FS ( L pL pH fn m [Code] <1C>H<28>H<4C>H<pL><pH><fn><m> [Range] (pL+pH×256)=2 (pL=2、pH=0) fn=66 m=48、49 [Outline] Executing paper feeding to the cut position. Operation Executes paper feeding to the next cut position. When, however, the printer has already been standby at the cut position, no operation is executed.
2.2.15 Other Commands DLE ENQ n [Function] Real-time request to printer [Code] <10>H<05>H<n> [Range] 0≦n≦2 [Outline] The printer responds in real-time to the request that the host specifies with number “n”. Function At the setting of execution of GS ^ by the FEED switch, the same processing as that pressing the FEED switch once is carried out.
DLE DC4 fn m t (Specification of fn = 8) [Function] Buffer clear [Code] <10>H<14>H<fn><d1>...<d7> [Range] fn=8、d1=1、d2=3、d3=20、d4=1、d5=6、d6=2、d7=8 [Outline] • Erases all data in receiving buffer or print buffer. • Sends the following 3-byte data group. Hex. Decimal No. of Data Header 1 byte Identifier...
ESC = n [Function] Data input control [Code] <1B>H<3D>H<n> [Range] 0≦n≦255 [Outline] • Selecting equipment for which data input from the host is valid. • Each bit of “n” indicates as follows. • When the printer has not been selected, this printer abandons all the received data until it is selected by this command.
ESC @ [Function] Initializing the printer [Code] <1B>H<40>H [Outline] Clears data stored in the print buffer and brings various settings to the initial state (Default state). [Caution] • The settings of DIP switches are not read again. • Data inside the internal input buffer is not cleared. •...
ESC L [Function] Selecting PAGE MODE [Code] <1B>H<4C>H [Outline] Switches from STANDARD MODE to PAGE MODE. [Caution] • This command is only effective if it entered at the beginning of a line. • This command is not effective if it is entered when in PAGE MODE. •...
ESC S [Function] Selecting STANDARD MODE [Code] <1B>H<53>H [Outline] Switches from PAGE MODE to STANDARD MODE. [Caution] • This command is only effective if it is entered when in PAGE MODE. • Any data mapped in PAGE MODE is erased. •...
Page 134
GS ( A pL pH n m [Function] Execution of test printing [Range] (pL+(pH×256))=2 (pL=2、pH=0) 0≦n≦2、48≦n≦50 1≦m≦7、49≦m≦55 [Outline] Specified test printing will be executed. • pL, pH will specify the number of subsequent parameters by (pL + (pH×256))bytes. • “n” will specify the paper for test printing in the following table. Paper Type 0,48 Basic paper (Paper rolls)
GS I n [Function] Sending the printer ID [Code] <1D>H<49>H<n> [Range] 1≦n≦4、49≦n≦52、65≦n≦69 [Outline] Sends the specified printer ID. Type of Printer ID Specification Value (Hex.) PPU-700 1,49 Model ID 2,50 Type ID Refer to table “Type ID” below 3,51 ROM version ID Subject to ROM version 4,52 Black mark length...
Page 136
n = 4, 52 specified (only for B.M specs) The Black mark length and mark interval currently used are returned in 4-byte code. All fractional parts in millimeters are rounded off. Byte 1 + Byte 2×256 = Black mark interval Byte 3 + Byte 4×256 = Black mark length Black mark paper [Caution]...
GS P x y [Function] Specifying the basic calculation pitch [Code] <1D>H<50>H<x><y> [Range] 0≦x≦255、0≦y≦255 [Outline] • This command sets the horizontal basic calculation pitch to approx. 25.4/x mm (1/x inches), and the vertical basic calculation pitch to approx. 25.4/y mm (1/y inches). •...
GS ( L pL pH m fn [parameter] GS 8 L p1 p2 p3 p4 m fn [parameter] [Function] Specifying graphics data [Code] <1D>H<28>H<4C>H<pL><pH><m><fn> <1D>H<38>H<4C>H<p1><p2><p3><p4><m><fn> * In the explanation of function, the code of GS ( L is used. • GS ( L and GS 8 L ) are the same function. •...
fn = 0, 48: Function 48 Sending NV Graphics Memory Capacity GS ( L pL pH m fn [Code] <1D>H<28>H<4C>H<pL><pH><m><fn> [Range] (pL+pH×256)=2 (pL=2、pH=0) m=48 fn=0、48 [Outline] Sends all capacity of NV graphics area in the number of bytes. Hex. Decimal Data Size Header 1 byte...
fn = 3, 51: Function 51 Sending the Remaining Amount of NV Graphics Memory GS ( L pL pH m fn [Code] <1D>H<28>H<4C>H<pL><pH><m><fn> [Range] (pL+pH×256)=2 (pL=2、pH=0) m=48 fn=3、51 [Outline] Sends the remaining amount of NV graphics area (number of bytes of unused area). Hex.
fn = 64: Function 64 Sending Key Code List of Defined NV Graphics GS ( L pL pH m fn d1 d2 [Code] <1D>H<28>H<4C>H<pL><pH><m><fn><d1><d2> [Range] (pL+pH×256)=4 (pL=4、pH=0) m=48 fn=64 d1=75(“K”) d2=67(“C”) [Outline] Sends the key code list of defined NV graphics. •...
fn = 65: Function 65 Erasing All Data of NV Graphics in a Lump GS ( L pL pH m fn d1 d2 d3 [Code] <1D>H<28>H<4C>H<pL><pH><m><fn><d1><d2><d3> [Range] (pL+pH×256)=5 (pL=5、pH=0) m=48 fn=65 d1=67(“C”) d2=76(“L”) d3=82(“R”) [Outline] Erases all defined data of NV graphics in a lump. fn = 66: Function 66 Erasing Specified NV Graphics Data GS ( L pL pH m fn kc1 kc2 [Code]...
fn = 67: Function 67 Defining Raster Type Graphics Data to NV Memory GS ( L pL pH m fn a kc1 kc2 b xL xH yL yH [c d1...dk]1 ... [c d1...dk]b [Code] <1D>H<28>H<4C>H<pL><pH><m><fn><a><kc1><kc2> <b><xL><xH><yL><yH[c d1...dk]1...[c d1...dk]b [Range] Parameter of GS ( L 12≦(pL+pH×256)≦65535 (0≦pL≦255、0≦pH≦255)...
fn = 69: Function 69 Printing Specified Graphics GS ( L pL pH m fn kc1 kc2 x y [Code] <1D>H<28>H<4C>H<pL><pH><m><fn><kc1><kc2><x><y> [Range] (pL+pH×256)=6 (pL=6、pH=0) m=48 fn=69 32≦kc1≦126 32≦kc2≦126 x=1、2 y=1、2 [Outline] Prints the NV graphics data defined by key code (kc1, kc2) as large as x times horizontally/y times vertically.
fn = 112: Function 112 Storing Raster Type Graphics Data to Print Buffer GS ( L pL pH m fn a bx by c xL xH yL yH d1...dk [Code] <1D>H<28>H<4C>H<pL><pH><m><fn><a><bx><by><c><xL><xH><yL><yH>[d1...dk] [Range] Parameter of GS ( L 11≦(pL+pH×256)≦65536 (0≦pL≦255、0≦pH≦255) Parameter of GS 8 L 11≦(p1+p2×256)+p3×65536+p4×16777216≦4294967295 (0≦p1≦255、0≦p2≦255、0≦p3≦255、0≦p4≦255)...
GS C 0 n m [Function] Setting counter print mode [Code] <1D>H<43>H<30>H<n><m> [Range] 0≦n≦5 0≦m≦2、48≦m≦50 [Outline] “n” sets the number of print columns for serial counter. • n = 0 sets the actual counter to the number of print columns. •...
GS C 1 aL aH bL bH n r [Function] Setting counter mode (A) [Code] <1D>H<43>H<31>H<aL><aH><bL><bH><n><r> [Range] 0≦(aL+aH×256)≦65535 (0≦aL≦255、0≦aH≦255) 0≦(bL+bH×256)≦65535 (0≦bL≦255、0≦bH≦255) 0≦n≦255 0≦r≦255 [Outline] Sets the count mode of serial counter in number. • aL, aH, bL, bH specifies the counting range of serial counter. •...
GS C ; sa ; sb ; sn ; sr ; sc ; [Function] Setting count mode (B) [Code] <1D>H<43>H<3B>H<sa><3B>H<sb><3B>H<sn><3B>H<sr><3B>H<sc><3B>H [Range] 0≦sa≦655535、0≦sb≦65535 0≦sn≦255、0≦sr≦255 0≦sc≦65535 [Outline] Sets the count mode and counter value of serial counter in character row. • “sa”, “sb” specifies the counting range of serial counter. •...
4. APPENDIX 4.1 Explanation on PAGE MODE 4.1.1 Overview The printer has two print modes: STANDARD and PAGE. In STANDARD MODE, the printer prints or feeds paper each time it receives a print or paper feed command. In PAGE MODE, when the printer receives print commands and/or form feed commands, it simply forwards them to the specified print area of memory.
4.1.3 Mapping of Print Data in the Print Area Print data is mapped in the print area as follows: (1) The print area is set by ESC W. When the printer has finished all of the print and paper feed actions specified before receiving an ESC W, the ESC W sets the right end (as viewed facing the printer) as the start point (x0, y0) of the print area.
Page 163
Mapping direction x0,y0 24-3 Baseline Point A dx,dy Print area Figure 4-1 Mapping Position for Character Data Bar code GS k m = nH*256+n 24-3 Bit image GS * x y ESC * m nL nH Baseline (HRI Characters) Point B Point B Point B Point B...
4.1.4 Example of Using PAGE MODE The following explains specific uses of PAGE MODE. When in PAGE MODE, the commands are typically sent from the host to the printer in the following sequence: (1) An ESC L puts the printer in PAGE MODE. (2) An ESC W specifies the print area.
Page 165
In Figure 4-3, a line feed occurs between “lesson” and “Test 1” because the space “ “ next to “lesson” does not fit in the horizontal range of the 200×400-pitch print area. The line feed width conforms to the value specified by a command such as ESC 3. It is possible to set as many print areas as desired before executing FF.
Page 166
Before an FF is sent (170th line), the following program code can be added to remove part of the data. < Example 3 > 180 PRINT♯1, CHR$(&H1B);"W"; CHR$(72); CHR$(0); CHR$(120); CHR$(0); 190 PRINT♯1, CHR$(36); CHR$(0); CHR$(48); CHR$(0); 200 PRINT♯1, CHR$(&H18); As a result of the additional program code, a print-out is executed as shown in Figure 4-5 “Print Result of Adding a Program of Example 3 to Example 2”, where the string “GHI”...
4.2 Bidirectional Parallel Interface Overview The interface of the printer is a Level-1 compatible device according to IEEE-P1284. It supports the communication modes described in 4.2.1 below. 4.2.1 Parallel Interface Communication Mode The parallel interface of the printer provides three communication modes as outlined below. When the printer is turned on or reset, it defaults to Compatibility mode.
4.2.2 Interfacing Phases Interfacing in each communication mode is divided into several phases. In addition, there is a phase for mode initialization, as well as a phase for mode switching. Interface signals may differ in name and function for different modes and different phases. Aborted Termination from Transfer...
4.2.3 Negotiation Overview Usually, the printer is started in Compatibility mode, which corresponds to the Centronics interface phase. When the host intends to switch to the Nibble or Byte mode, it sends a request and negotiates with the printer. A general flow of negotiations is given below. (1) The host sets the IEEE 1284 Active signal to High.
Page 170
Precautions (1) The Negotiation phase is triggered when the IEEE 1284 Active signal sent by the host becomes High. (2) In Compatibility mode, the time when the negotiation process begins is, as a general rule, after the host sets nStrobe to High and then the printer outputs an nAck pulse. Once the nStrobe signal is set to High, however, the printer immediately moves into the Negotiation phase when the high state of IEEE 1284 Active is detected, even if the nAck pulse has yet to be output or is being output.
Page 171
Data Communication from Printer to Host Nibble Mode In this mode, data is transferred between the printer and the host through the procedure described below. The steps beginning from (1) are applicable when the Negotiation phase has switched to the Host Busy Data Available phase.
Page 172
(12) If the host selected the Reverse Idle phase and new data becomes available to be sent from the printer, the printer sets PtrClk to Low to request the host for an interrupt. (Event 18) (13) The printer sets PtrClk back to High. (Event 19) (14) Upon receiving a request for interrupt from the printer, the host responds by setting HostBusy (nAutoFd) to High.
Page 173
Byte Mode In this mode, data is transferred between the printer and the host through the procedure described below. The steps beginning from (1) are applicable when the Negotiation phase has switched to the Host Busy Data Available phase. If the Negotiation phase has switched to the Host Busy Data Not Available phase, the procedure starts at step (9).
Page 174
Device ID The device ID is a character string that provides the ID, the type, and other information regarding the printer connected to the interface. When the printer receives a request for a device ID from the host, it replies with the following device ID: <00>H<2E>H MFG:CBM;...
Page 175
Termination Termination is the process of returning to Compatibility mode from the Nibble or Byte modes. When performing Termination, the host sets the signals as follows: • IEEE 1284 Active (nSelectln): Low • HostBusy (nAutoFd): High (Event 22) There are two methods of Termination: (1) Termination through a handshake between the host and the printer (2) Immediate termination (1) Termination through a handshake between the host and the printer:...
4.3 Identification of Send Status Because the status sent from the printer has certain fixed bits, it is possible to identify to which command the status belongs. When using ASB (Automatic Status Back), however, the first byte of ASB should be checked, and then the three consecutive bytes except for XOFF should be treated as ASB data.
4.4 Memory Switch Memory switch has a function to store various settings selected by the user alternatively in nonvolatile memory. Memory switch setting is retained unless the memory switch is changed. Memory switch setting can be changed by the manual setting in memory switch change mode or by a command.
4.4.2 Details of Memory Switches Functions of memory switches, operations at ON (1) setting, and operation at OFF (0) setting are described below. Memory switches without function setting are not explained but default must not be changed. When setting memory switches manually, ON setting allows POWER LED to light and OFF setting allows it to go off.
Page 179
• MSW 1-3: BUSY Condition Function: Selects the condition for the printer to become BUSY state. Auto status sending function is also activated. OFF (0) ON (1) Busy Condition Full/Err Full Operation at ON (1): When receive buffer is full, the printer is in the BUSY state. Auto status sending (ASB) function is valid.
Page 180
• MSW 1-5: CR Code Processing Function: Selects whether the printer operates in the same manner as LF (<0A>H) when it receives the CR(<0D>H) code. OFF (0) ON (1)) CR mode Ignored Operation at ON (1): Operates in the same manner as LF when receiving CR code. Prints data in the print buffer and performs line feed in accordance with the amount of preset line feed.
Page 181
(2) MSW2 • MSW 2-1: Omitted for reservation. • MSW 2-2: Omitted for reservation. • MSW 2-3: Valid/Invalid of buffered printing Function: Selects Valid/Invalid of buffered printing. OFF(0) ON(1) Spool print Invalid Valid Operation at ON (1): Enables buffered printing. Stores a certain amount of print buffer in the internal RAM and prints it at a time.
Page 182
• MSW 2-5: Processing after Cover Close and PE Clear Function: Selects the processing to be carried out when resuming printing after the printer cover is opened or paper empty (PE) is detected during printing. OFF(0) ON(1) Resume aft PE Next Operation at ON (1): Resumes printing at the top of remaining data in printer.
Page 183
(3) MSW3 • MSW 3-1: Recovery from Cutter Lock Error Function: Selects the method of recovery from Cutter Lock error. OFF(0) ON(1) Resum Cttr Err Valid Invalid Operation at ON (1): Recovers by a command. After removing the cause of the error, returns by a command <DLE+ENQ+n>. Operation at OFF (0): Recovers by FEED SW.
Page 184
• MSW 3-4: Selecting paper Function: Selects either thermal paper or black mark paper. OFF(0) ON(1) Paper Select Thermal Black MK Operation at ON (1): Sets black mark paper. Operation at OFF (0): Sets thermal paper. • MSW 3-5: Omitted for reservation. •...
Page 185
(4) MSW4 • MSW 4-1: Omitted for reservation. • MSW 4-2: Omitted for reservation. • MSW 4-3: Valid/Invalid of demo operation at power ON Function: Selects Valid/Invalid of demo operation at power ON. OFF(0) ON(1) Paper Top Feed Valid Invalid Operation at ON (1): Disables demo operation at power ON.
Page 186
• MSW 4-5: Selecting Paper Collecting Direction Function: Selects the paper collecting direction when collecting paper is set to be Valid. Valid only when MSW 4-4 is ON. OFF(0) ON(1) Collect Direction Rear Front Operation at ON (1): Ejects paper forward. Ejects paper forward after the time set for command <GS+R+1+n>...
Page 187
• MSW 4-7: Valid/Invalid of Continuous Operation of Paper Ejection Function: Selects Valid/Invalid of paper eject operation of next paper while presenter sensor is detecting paper. OFF(0) ON(1) Print Continue Invalid Valid Operation at ON (1): Enables Continuous operation. Enables the paper eject operation of next paper even if the presenter sensor is detecting paper.
4.5 Black Mark Layout and Operating Condition Cut position when 12.4mm black mark is detected. 32.5mm M2 (Back) Print Surface M1 (Back) M3 (Front) Paper Feed Direction Cut position when 12.4mm black mark is detected. 32.5mm Symbol Item BM Paper 5~10mm Black mark length Black mark width...
Need help?
Do you have a question about the PPU-700 and is the answer not in the manual?
Questions and answers