background image

PPTII-A Programming Manual

www.hprt.com

4

GS B n

............................................................................................................................................................

31

GS H n

...........................................................................................................................................................

32

GS L nL nH

.....................................................................................................................................................

32

GS W nL nH

...................................................................................................................................................

33

GS \ nL nH

.....................................................................................................................................................

33

GS f n

.............................................................................................................................................................

34

GS h n

............................................................................................................................................................

34

GS k m d1 d2

dk NUL

GS k m n d1 d2 … dn

..................................................................................

34

GS r n

............................................................................................................................................................

34

GS v 0 m xL xH yL yH d1....dk

........................................................................................................................

35

GS w n

...........................................................................................................................................................

36

3.Multi-byte code characters commands list

......................................................................................................

37

FS ! n

.............................................................................................................................................................

38

FS &

...............................................................................................................................................................

38

FS -n

..............................................................................................................................................................

38

FS .

.................................................................................................................................................................

39

FS S n1 n2

......................................................................................................................................................

39

FS W n

...........................................................................................................................................................

40

ESC m x x’ y y’ w w’ h h’

........................................................................................................................

40

ESC o x x’ y y’ r r’

..................................................................................................................................

41

GS x n

............................................................................................................................................................

42

GS i n

...........................................................................................................................................................

42

GS ( k pL pH cn fn n (cn = 49, fn = 67)

.........................................................................................................

42

GS ( k pL pH cn fn n (cn = 49, fn = 69)

.........................................................................................................

43

GS ( k pL pH cn fn m d1…dk (cn = 49, fn = 80)

............................................................................................

43

GS ( k pL pH cn fn m (cn = 49, fn = 81)

........................................................................................................

43

4.Programming Process Guide

.............................................................................................................................

44

Appendix

...............................................................................................................................................................

45

Appendix A: Code128 Bar Code

...................................................................................................................

45

A.1 Description of th e CODE128 Bar Code

.................................................................................................

46

B.1 General Description

...............................................................................................................................

48

B.2 Setting Values in Standard and Page Modes

.........................................................................................

50

B.3 Formatting of Print Data in the Printable Area

.....................................................................................

50

Summary of Contents for PPTII-A

Page 1: ...ww hprt com 1 PPTII A Programming Manual Xiamen Hanin Electronic Technology Co Ltd ADD Room 305A Angye Building Pioneering Park Torch High tech Zone Xiamen China 361009 Tel 86 0 592 5885993 Fax 86 0 5...

Page 2: ...ing Manual www hprt com 2 REVISION RECORDS Rev Date Description Drawn Checked Approved 1 0 2014 02 17 Chen Weihua Lin Yang Ren Xiaowei 1 1 2014 07 30 1 change orders ESC M n ESC t n Chen Weihua Yang K...

Page 3: ...dk 12 ESC n 14 ESC 2 14 ESC 3 n 15 ESC n 15 ESC n 15 ESC 16 ESC D n1 nk NUL 16 ESC E n 16 ESC G n 16 ESC J n 17 ESC L 17 ESC M n 17 ESC R n 18 ESC S 18 ESC T n 18 ESC V n 19 ESC W xL xH yL yH dxL dxH...

Page 4: ...39 FS S n1 n2 39 FS W n 40 ESC m x x y y w w h h 40 ESC o x x y y r r 41 GS x n 42 GS i n 42 GS k pL pH cn fn n cn 49 fn 67 42 GS k pL pH cn fn n cn 49 fn 69 43 GS k pL pH cn fn m d1 dk cn 49 fn 80 4...

Page 5: ...like LF HRI character Bar code note character Human Readable Interface NV Non volatile memory in which data stored does not loss when powered off NV Non volatile RAM Random Access Memory ASB Auto Send...

Page 6: ...ASCII LF Hex 0A Decimal 10 Dscription Prints the data in the print buffer and feeds one line based on the current line spacing Notes This command sets the print position to the beginning of the line W...

Page 7: ...I DLE EOT n Hex 10 04 n Decimal 16 4 n Range 1 n 4 Dscription The status is transmitted whenever the data sequence 10 H 04 H n 1 n 4 is received Example In ESC m nL nH d1 dk d1 10 H d2 04 H d3 01 H Do...

Page 8: ...ecimal Function 0 0 00 0 Not used Fixed to Off 1 1 02 2 Not used Fixed to On 2 0 00 0 Drawer kick out connector pin 3 is LOW 1 04 4 Drawer kick out connector pin 3 is HIGH 3 0 00 0 Reserved 1 08 8 Res...

Page 9: ...Roll paper end sensor paper not present 7 0 00 0 Not used Fixed to Off DLE ENQ n Name Real time request to print Format ASCII DLE ENQ n Hex 10 05 n Decimal 16 5 n Range 1 n 2 Dscription In response to...

Page 10: ...acter spacing to n 0 125mm n 0 0049 inch Notes When characters are enlarged the character spacing is n times normal value This command sets values independently in each mode standard and page modes De...

Page 11: ...e GS can also select character size However the setting of the last received command is effective Default n 0 ESC nL nH Name Set absolute print position Format ASCII ESC nL nH Hex 1B 24 nL nH Decimal...

Page 12: ...r of dots in the horizontal direction Notes The allowable character code range is from ASCII code 20 H to 7E H It is possible to define multiple characters for consecutive character codes If only one...

Page 13: ...1 to print a dot or set a bit to 0 to not print a dot After the bit image is sent successfully the printer will be back to the normal data processing mode If the width printing area set by GSL and GSW...

Page 14: ...erline mode on off n value as follows n Function 0 48 underline mode is turn off 1 49 underline mode one dot width is turn on 2 50 underline mode two dot width is turn on Notes 1 This command is effec...

Page 15: ...be set independently in standard mode and in page mode ESC 3 n Name Set character line spacing Format ASCII ESC 3 n Hex 18 33 n Decimal 27 51 n Range 0 n 255 Dscription Sets the line spacing to n 0 12...

Page 16: ...rinter default is continuous paper the print mode is standard mode after power on The macro definition is not cleared ESC D n1 nk NUL Name Set horizontal tab positions Format ASCII ESC D n1 nk Hex 1B...

Page 17: ...position to the beginning of the line The paper feed amount set by this command does not affect the values set by ESC 2 or ESC 3 The maximum paper feed amount is 900 mm If the paper feed amount n line...

Page 18: ...select character font n Function 0 48 Choose character font A 12 24 1 49 Choose character font B 9 17 2 50 Choose character font C 8 16 Notes 1 ESC can set character font too the command received at...

Page 19: ...line spacing ESC 2 ESC 3 ESC T n Name Select character font Format ASCII ESC T n Hex 1B 54 n Decimal 27 84 n Range 0 n 3 48 n 51 Dscription Set the print direction and starting position in page mode...

Page 20: ...Vertical starting position y0 yL yH 256 0 125mm Printing area width dx dxL dxH 256 0 125mm Printing area height dy dyL dyH 256 0 125mm Notes This command is processed in standard mode to set an activa...

Page 21: ...ement to the right nL nH 256 N Use the complement of N for setting N pitch movement to the left nL nH 256 65536 N Print starting position from the current position to N 0 125mm ESC a n Name Select jus...

Page 22: ...acing set by ESC 2 or ESC 3 The maximum paper feed amount is 900 mm If the paper feed amount n line spacing of more than 900 mm is specified the printer feeds the paper only 900 mm ESC l n X0l X0h Y0l...

Page 23: ...t n Hex 1B 74 n Decimal 27 116 n Range 0 n 47 Dscription Select character code table n Character Code table n Character Code table 0 PC437 USA Standard Europe 45 WPC1250 1 Katakana 46 WPC1251 Cyrilli...

Page 24: ...7 fonts ESC v Name Transmit printer status Format ASCII ESC v Hex 1B 76 Decimal 27 118 Dscription This command is only effective with a serial interface printer to transmit printer status to host mach...

Page 25: ...in page mode the printer performs only internal flag operations This command does not affect printing in page mode In upside down printing mode the printer rotates the line to be printed by 180 and th...

Page 26: ...in double height and quadruple modes regardless of the line spacing specified by ESC 2 or ESC 3 After printing the bit image this command sets the print position to the beginning of the line and proce...

Page 27: ...xH yL yH d1 dk is NV bit image 01H and the last data group xL xH yL yH d1 dk is NV bit image n The total agrees with the number of NV bit images specified by the command FS p The definition data for a...

Page 28: ...ecimal 29 33 n Range 0 n 255 1 vertical number of times 6 1 horizontal number of times 6 Dscription Selects the character height using bits 0 to 3 and selects the character width using bits 4 to 7 as...

Page 29: ...ertical print position in page mode Format ASCII GS nL nH Hex 1D 24 nL nH Decimal 29 36 nL nH Range 0 nL 255 0 nH 255 Dscription Set absolute vertical print position in page mode This command sets the...

Page 30: ...x y d1 d x y 8 Name Define download bit image Format ASCII GS x y d1 d x y 8 Hex 1D 2A x y d1 d x y 8 Decimal 29 42 x y d1 d x y 8 Range 1 x 255 1 y 48 0 d 255 x y 1023 Dscription It defines a downlo...

Page 31: ...pends on the differences between print area position and the starting position Starting position is top left or lower right corner this command set the absolute position at the direction parallel to t...

Page 32: ...defined bit images bar codes HRI characters and spacing skipped by HT ESC and ESC This command does not affect the space between lines White black reverse mode has a higher priority than underline mo...

Page 33: ...le area is used Default nL 0 nH 0 GS W nL nH Name Set printing area width Format ASCII GS W nL nH Hex 1D 57 nL nH Decimal 29 87 nL nH Range 0 nL 255 0 nH 255 Dscription Set printing area width using n...

Page 34: ...n Name Select font for HRI characters Format ASCII GS f n Hex 1D 66 n Decimal 29 102 n Range n 0 1 48 49 Dscription Selects a font for the HRI characters when printing a bar code n Font for the HRI ch...

Page 35: ...to print the bar code regardless of the line spacing specified by line space setting commands GS r n Name Transmit status Format ASCII GS r n Hex 1D 72 n Decimal 29 114 n Range n 1 49 Dscription This...

Page 36: ...es in horizontal direction xL xH 256 yL yH indicates the number of bit image bytes in vertical direction yL yH 256 Notes In standard mode this command is effective only when there is no data in the pr...

Page 37: ...de width as follows n Module Width mm for Multi level Bar Code Binary level Bar Code Thin Element Width mm Thick Element Width mm 2 0 250 0 250 0 625 3 0 375 0 375 1 000 4 0 500 0 500 1 250 5 0 625 0...

Page 38: ...erline all characters including right and left side character spacing but cannot underline the space set by HT and 90 clockwise rotated characters The thickness of the underline is that specified by F...

Page 39: ...nd byte Kanji character mode is not selected when the power is turned on Reference FS FS C FS n Name Turn underline mode on off for Kanji characters Format ASCII FS n Hex 1C 2D n Decimal 28 45 n Range...

Page 40: ...g to n1 and n2 respectively The left side character spacing is n1 0 125 mm and the right side character spacing is n2 0 125 mm Notes This command sets the left and right side character spacing for nor...

Page 41: ...GS can also select and cancel quadruple size mode by selecting double height and double height modes and the setting of the last received command is effective Default n 0 Reference FS GS ESC m x x y...

Page 42: ...e pay attention about the size of the canvas page mode Circle can t be drew if the size pass over canvas GS x n Name Set serial port 2 baud rate Format ASCII GS x n Hex 1D 78 n Decimal 29 120 n Dscrip...

Page 43: ...07 pL pH cn fn n Range pL pH 256 3 pL 3 pH 0 cn 49 fn 69 48 n 51 Dscription Selects the error correction level for QR Code n Function Reference Approx figure of recovery 48 Select error correction lev...

Page 44: ...n fn m Hex 1D 28 6B pL pH cn fn m Decimal 29 40 107 pL pH cn fn m Range pL pH 256 3 pL 3 pH 0 cn 49 fn 81 m 48 Dscription Encodes and prints the QR Code symbol data in the symbol storage area with GS...

Page 45: ...s Make sure that the printer status is normal before sending data to print 2 Intitialize the printer Make sure that the previous setting does not affect the current printing 3 Set the print content Se...

Page 46: ...ters 20H to 7FH Code set C 100 numerals from 00 to 99 The following special characters are also available in CODE128 SHIFT characters In code set A the character just after SHIFT is processed as a cha...

Page 47: ...PPTII A Programming Manual www hprt com 47...

Page 48: ...PPTII A Programming Manual www hprt com 48...

Page 49: ...PPTII A Programming Manual www hprt com 49...

Page 50: ...are complete before the printer receives the ESC W command the left side as you face the printer is taken as the origin x0 y0 of the printable area The printable rectangular area is defined by the le...

Page 51: ...formula number of vertical dots 8 6 number of dots for feeding at the beginning of the printable area 24 vertical motion unit 203 203 24 Therefore 24 dots are required for feeding Use the following c...

Page 52: ...PPTII A Programming Manual www hprt com 52...

Reviews: