Confidential BTP-R880NP Programming Manual REVISION HISTORY Date Version Description Drafted by Ding Jinfeng, Cao 2010-11-12 V100 Primary version Yongkang - 1 -...
Page 3
Confidential BTP-R880NP Programming Manual Declaration Information in this document is subject to change without notice. SHANDONG NEW BEIYANG INFORMATION TECHNOLOGY CO., LTD. (hereinafter referred to as “SNBC”) reserves the right to improve products as new technology, components, software, and firmware become available. If users need further data about this products or have any doubt about safety issues that might arise from using it, please feel free to contact SNBC or your local distributor.
1 Overview This manual classifies the printer commands into several kinds based on its functions, and also describes the applications of relative commands in detail depending on its sorts. We hope that it is helpful for programmers to get known of those commands. 1.1 Commands classification This receipt printer commands are classified as below: Print commands: used for printing and feeding paper;...
Confidential BTP-R880NP Programming Manual 1.3 Command format [Function] The name and function summary of commands; [Format] The format of command data, such as ASCII, Hex and Decimal; [Range] The value range of parameter in the command; [Note] Explain the main features and application notices of commands;...
Confidential BTP-R880NP Programming Manual 2 Command Description 2.1 Print command [Function] Print and line feed [Format] ASCII Decimal [Note] This command sets the print position to the beginning of the line. [Reference] ESC 2, ESC 3 [Function] Print all data in the print buffers and return to the standard mode.
Confidential BTP-R880NP Programming Manual [Relative] FF, ESC L, ESC S ESC J n [Function] Print and feed paper [Format] ASCII Decimal [Range] 0 ≤n ≤ 255 [Notes] After printing is completed, this command sets the print starting position to the beginning of the line.
Confidential BTP-R880NP Programming Manual Decimal [Range] 0 ≤n ≤ 255 [Notes] · This command sets the print starting position to the beginning of the line. · This command does not affect the line spacing set by ESC 2 or ESC 3.
Confidential BTP-R880NP Programming Manual 1B 44 08 10 1C 00(set the horizontal tab position) 09(move the print position to the next tab) 33 33 33 33 09(the same as above) 33 33 33 33 09(the same as above) 33 33 33 33 0A(print)...
Confidential BTP-R880NP Programming Manual 44 n1...nk 00 Decimal 68 n1...nk 0 [Range] 1 ≤ n ≤ 255 0 ≤ k ≤ 32 [Notes] · The horizontal tab position is stored as a value of [character width × n] measured from the beginning of the line.
Page 14
Confidential BTP-R880NP Programming Manual · This command sets the position where data is buffered within the printing area. Parameters for horizontal or vertical motion units (x or y) differ as follows, depending on the starting position of the printing area:...
Confidential BTP-R880NP Programming Manual ·When pitch N is specified to the right: nL+ nH × 256 = N ·When pitch N is specified to the left (the negative direction), use the complement of 65536. ·When pitch N is specified to the left: nL+ nH × 256 = 65536 - N ·The print starting position moves from the current position to [N ×...
Confidential BTP-R880NP Programming Manual · If this command is input in page mode, it is disabled. · This command does not affect printing in page mode. · If the setting exceeds the printable area, the maximum value of the printable area is used.
Confidential BTP-R880NP Programming Manual Commands using x: ESC SP, ESC $, ESC W, ESC \, FS S Commands using y: ESC 3, ESC J, ESC W, GS $, GS \, GS V 2) When the print starting position is set to the upper right(Printing direction from top to...
Confidential BTP-R880NP Programming Manual 0 ≤ nH ≤ 255 [Notes] · This command sets the distance from the current position to [( nL + nH × 256) × vertical or horizontal motion unit] inches. · This command is ignored unless page mode is selected.
Confidential BTP-R880NP Programming Manual ESC ! n [Function] Select print mode(s) [Format] ASCII Decimal [Range] 0 ≤ n ≤ 255 [Notes] · Select print mode(s) according to n as follow Decimal Function Standard ASCII Font (12 × 24) Compressd ASCII Font (9 × 17)
Page 25
Confidential BTP-R880NP Programming Manual × 0 ≤ x ≤ 9 Compressed ASCII font (9 × 0 ≤ d1 ... d(y xk) ≤ 255 · y specifies the number of bytes in the vertical direction. · c1 specifies the beginning character code for the definition, and c2 specifies the final code.
Page 26
Confidential BTP-R880NP Programming Manual ESC – n [Function] Turn underline mode on/off [Format] ASCII 2D n Decimal 45 n [Range] 0 ≤ n ≤2, 48 ≤n ≤ 50 [Notes] Turn underline mode on or off, based on the following values of n:...
Confidential BTP-R880NP Programming Manual · Underline mode can also be turned on or off by using ESC !. Note, however, that the last received command is effective. [Default] n = 0 [Reference] ESC ! [Example] 1B 40 1B 2D 02(2-dot thick underline)...
Confidential BTP-R880NP Programming Manual 42 42 42 42 42 0A Results: ESC G n [Function] Turn on/off double-strike mode [Format] ASCII 47 n Decimal 71 n [Range] 0 ≤ n ≤ 255 [Notes] · When the LSB of n is 0, double-strike mode is turned off.
Confidential BTP-R880NP Programming Manual Decimal [Range] 0 ≤ n ≤ 13 [Notes] Select an international character set n from the following table: Character set U.S.A France Germany Denmark I Sweden Italy Spain I Japan Norway Denmark II Spain II Latin America...
Confidential BTP-R880NP Programming Manual GS ! n [Function] Select character size [Format] ASCII Decimal [Range] 0 ≤ n ≤ 255 (1 ≤ vertical number of times ≤ 6, 1 ≤ horizontal number of times ≤ 6) [Notes] Select the character height using bits 0 to 3 and select the character width using bits 4 to...
Confidential BTP-R880NP Programming Manual · When the LSB of n is 1, white/black reverse mode is turned on. [Notes] · Only the lowest bit of n is valid. ·This command is effective to all characters except for HRI characters.. · When white/black reverse printing mode is on, it also applies to character spacing set by ESC SP.
Confidential BTP-R880NP Programming Manual · It is possible to turn underline mode on or off with FS -, and the setting of the last received command is effective. [Default] n = 0 [Reference] FS-, FS W, GS ! [Example] Refers to ESC ! FS &...
Confidential BTP-R880NP Programming Manual FS . [Function] Cancel Chinese character mode [Format] ASCII Decimal [Notes] · When the Chinese character mode is not selected, all character codes are processed one byte at a time as ASCII code. · Chinese character mode is selected when the power is turned on.
Confidential BTP-R880NP Programming Manual [Range] 0 ≤ n ≤ 1, 48 ≤ n ≤ 49 [Notes] Select Japanese character mode according to the values of n: Code mode 0,48 JIS code 1,49 SHIFT JIS code · This commmand is enabled only in Japanese character mode.
Confidential BTP-R880NP Programming Manual [Example] Refer to ESC SP FS W n [Function] Turn quadruple-size mode on/off for Chinese characters [Format] ASCII Decimal [Range] 0 ≤ n ≤ 255 [Description] · When the LSB of n is 0, quadruple-size mode for Chinese characters is turned off.
Page 38
Confidential BTP-R880NP Programming Manual ·If the value of m is out of the specified range, nL and the following data are processed as normal data. · The nL and nH indicate the number of dots of the bitmap in the horizontal direction. The number of dots is calculated by nL + nH ×...
Confidential BTP-R880NP Programming Manual ESC # n [Function] Specify a number for the bit-image to be downloaded. This number is to be used when downloading and printing this bit-image. [Format] ASCII 23 n Decimal 33 n [Range] 0 ≤ n ≤ 7...
Confidential BTP-R880NP Programming Manual GS / m [Function] Print downloaded bitmap [Format] ASCII Decimal [Range] 0 ≤ m ≤ 3, 48 ≤ m ≤ 51 [Description] Print a downloaded bitmap with the print mode specified by m. m selects a mode from the table below:...
Confidential BTP-R880NP Programming Manual bitmap. · In standard mode, this command is effective only when there is no data in the print buffer. · This command has no effect in all print modes (character size enlargement, emphasized, double-strike, underline, white/black reverse printing, etc.) for raster bitmap.
Confidential BTP-R880NP Programming Manual not printed. · After printing the bitmap, this command sets the print position to the beginning of the line and processes the data that follows as normal data. [Relatives] ESC *, FS q, GS /, GS v 0 FS q n [xL xH yL yH d1...dk]1...[xL xH yL yH d1...dk]n...
Page 43
Confidential BTP-R880NP Programming Manual defined are disabled (undefined), but any NV bitmaps before that are enabled. · The d indicates the definition data. In data (d) a 1 bit specifies a dot to be printed and a 0 bit specifies a dot not to be printed.
Confidential BTP-R880NP Programming Manual 2.5 Status command DLE EOT n [Function] Real-time status transmission [Format] ASCII Decimal [Range] 1 ≤ n ≤ 4 · n = 1: Transmit printer status · n = 2: Transmit off-line status · n = 3: Transmit error status ·...
Page 45
Confidential BTP-R880NP Programming Manual n = 2: Off-line status Decimal Function Fixed to 0 Fixed to 1 Cover is closed. Cover is open FEED button is not been pushed FEED button is been pushed Fixed to 1 Paper is not end Paper is end No error.
Confidential BTP-R880NP Programming Manual GS a n [Function] Enable/Disable Automatic Status Back (ASB) [Format] ASCII Decimal 29 [Range] 0 ≤ n ≤ 255 [Notes] Decide the content of ASB. The meanings of parameter n are as follows: · When n is not equal to 0, the printer automatically transmits the status whenever the enabled status item changes.
Confidential BTP-R880NP Programming Manual Bit 5: Errors like paper jam are recoverable errors.These errors can be eliminated and the printer can return to normal state by using DLE ENQ n (1 ≤ n ≤ 2). Errors like control board damage are irrecoverable errors.
Confidential BTP-R880NP Programming Manual Drawer kick-out connector status ( n = 2, 50): Decimal Status for ASB Drawer kick-out is open Drawer kick-out is closed 1- 3 Undefined Not used. Fixed to 0 5, 6 Undefined Not used. Fixed to0.
Confidential BTP-R880NP Programming Manual GS h n [Function] Select barcode height [Format] ASCII Decimal [Range] 1 ≤ n ≤ 255 [Notes] The height of the barcode is n dots. [Default] n = 162 [Reference] GS k GS k m d1...dk NUL GS k m n d1...dn ①...
Page 50
Confidential BTP-R880NP Programming Manual Bar Code type Number of Characters UPC-A 11 ≤ k ≤ 12 48 ≤ d ≤ 57 ① UPC-E 11 ≤ k ≤ 12 48 ≤ d ≤ 57,d1=48 JAN13 (EAN13) 12 ≤ k ≤ 13 48 ≤...
Page 51
Confidential BTP-R880NP Programming Manual bb: The total number of the symbols; input 2 bytes decimal data cc: The even and odd data; input 2bytes hexadecimal data ,,: are fixed separator symbol (2) E: Error correction grade Range: L,M,Q,H. The correction grade is increasing from L to (3) M: Mask image reference.
Page 52
Confidential BTP-R880NP Programming Manual Legal length of the bar: The ratio of the bar is not changeable. Example: 1D 6B 0C 33 32 37 38 39 35 35 35 35 38 34 30 36 36 36 54 48 49 53 20 50 41...
Page 53
Confidential BTP-R880NP Programming Manual 2) Special characters are defined by combining two characters "{" and one character. The ASCII character "{" is defined by transmitting "{" twice consecutively. Specific character Transmit data ASCII Decimal SHIFT 7B, 53 123,83 CODE A...
Confidential BTP-R880NP Programming Manual 1D 6B 02 30 31 32 33 34 35 36 37 38 39 30 35 39 00 0A 1D 48 03(Set the width of the barcode unit 3) 1D 66 00(HRI characters use standard character) 1D 77 03(HRI characters print both above and under the barcode)...
Page 55
Confidential BTP-R880NP Programming Manual Parameter Barcode type Character set Data length Coding range 14bits, GS1DataBar 0000000000000 ~ Number 0-9 13numbers+1bits of Omnidirectional 9999999999999 check characters 14bits, GS1DataBar 0000000000000 ~ Number 0-9 13numbers+1bits of Truncated 9999999999999 check characters 14bits, GS1 DataBar...
Confidential BTP-R880NP Programming Manual · n7 indicates the content of the note character Parameter Note character DataBar and 2D in composite barcode DataBar only in separate barcode Print DataBar in composite or separate barcode Print 2D in composite barcode, no print in separate barcode No note character ·...
Confidential BTP-R880NP Programming Manual GS q n [Function] Set correction grade of barcode PDF417 [Format] ASCII Decimal [Range] 0≤ n ≤8 [Notes] Set correction grade of PDF417 code, the higher the correction grade is, the bigger the capacity of the barcode is.
Page 59
Confidential BTP-R880NP Programming Manual upside-down printing command can print the note upside down, while ESC { n can only print the character line upside down. ·This command is used at the beginning of the upsode-down page. The part behind the command is to be printed.
Confidential BTP-R880NP Programming Manual · This command performs only definition of a NV bitmap and does not perform printing. Printing of the NV bitmap is performed by the FS p command Format of the greyscale bitmap: every dot line of greyscale image is indicated by four dot lines of data.
Confidential BTP-R880NP Programming Manual Real greyscale Data of the first Data of the Data of the third Data of the fourth rank dot line second dot line dot line dot line ESC c 7 n RAM [Function] Print downloaded RAM greyscale bitmap and set print mode.
Confidential BTP-R880NP Programming Manual 2.11 Other commands ESC c : n choose paper-saving mode and reduce ticket width [Function] ASCII [Format] Decimal 0 ≤ n ≤ 4 [Range] Paper-saving function refers to vertical compression according to a proportionality factor [Notes] set by user to reach the goal of saving paper.
Confidential BTP-R880NP Programming Manual ·Do not insert the command into the data sequence of 2 or more bytes. [Reference] DLE EOT DLE DC4 n m t [Function] Generate pulse at real-time to open cash drawer [Format] ASCII Decimal [Range] n = 1 m = 0, 1 1 ≤...
Confidential BTP-R880NP Programming Manual ·The horizontal and vertical motion units are specified by GS P. Changing the horizontal or vertical motion unit does not affect the current line spacing. · In standard mode, the vertical motion unit (y) is used.
Confidential BTP-R880NP Programming Manual ESC L [Function] Transform from standard mode to page mode [Format] ASCII Decimal [Notes] ·This command is enabled only when processed at the beginning of a line in standard mode. ·This command has no effect in page mode.
Confidential BTP-R880NP Programming Manual · The following commands are enabled only to set in standard mode. 1) Set printing area in page mode: ESC W 2) Select print direction in page mode: ESC T · The following commands are ignored in standard mode: 1) Set absolute vertical print position in page mode: GS $...
Confidential BTP-R880NP Programming Manual · It is possible to select two sensors to output signals. Then, if any of the sensors detects paper end, the paper end signal can output. · The command is available only with a parallel interface and is ignored with a serial interface.
Confidential BTP-R880NP Programming Manual [Function] Start/end macro definition. [Format] ASCII Decimal [Notes] · The printer starts macro definition after receiving this command in normal mode. It ends macro definition after receiving this command in macro definition mode. · If the printer receives GS ^ in macro definition mode, the printer will end macro defihntion and clear it.
Page 73
Confidential BTP-R880NP Programming Manual [Range] 0 ≤ r ≤ 255 0 ≤ t ≤ 255 0 ≤ m ≤ 1, [Notes] · r specifies times of macro definition. · t specifies waiting time of macro execution. · m specifies the mode of macro execution.
Confidential BTP-R880NP Programming Manual 3 Programming Process Guide Because the different printing status and error can be transmitted by Auto Status Back (ASB) command, it is recommended that you can use ASB command to inquiry status. ASB command is effective when the printer is powered on and can be directly sent to inquiry the status.
Confidential BTP-R880NP Programming Manual Appendix Appendix A: Code128 Bar Code A.1 Description of the CODE128 Bar Code In CODE128 bar code system, it is possible to represent 128 ASCII characters, the one hundred numbers from 00 to 99 and some special characters with three code sets: A, B and C. Each code set is used for representing the following characters: ·...
Page 76
Confidential BTP-R880NP Programming Manual A.2 Code Tables Printable characters in code set A Transmit Data Transmit Data Transmit Data Character Character Character Decimal Decimal Decimal NULL FNC1 7B,31 123,49 FNC2 7B,32 123,50 FNC3 7B,33 123,51 FNC4 7B,34 123,52 < SHIFT...
Page 77
Confidential BTP-R880NP Programming Manual Printable characters in code set B Transmit Data Transmit Data Transmit Data Character Character Character Decimal Decimal Decimal " & 7B,7B 123,123 — FNC1 7B,31 123,49 FNC2 7B,32 123,50 FNC3 7B,33 123,51 FNC4 7B,34 123,52 SHIFT...
Page 78
Confidential BTP-R880NP Programming Manual Printable characters in code set C Transmit Data Transmit Data Transmit Data Character Character Character Decimal Decimal Decimal FNC1 7B,31 123,49 CODEA 7B,41 123,65 CODEB 7B,42 123,66 - 72 -...
Confidential BTP-R880NP Programming Manual Appendix B: Print mode and its change B.1 General Description The printer operates in two print modes: standard mode and page mode. In standard mode, the printer prints and feeds paper each time it receives print data or paper feed commands. In page mode, all the received print data and paper feed commands are processed in the specified memory, and the printer executes no operation.
Page 80
Confidential BTP-R880NP Programming Manual printable area. The print position, therefore, moves to the beginning of the next line. The line feed amount depends on the values set by commands (such as ESC 2 and ESC 3). 4) The default value of the line spacing is set to 1/6 inch and corresponds to 31 dots in the vertical direction.
Page 81
Confidential BTP-R880NP Programming Manual Print Data Developing Position Downloaded Bit Image Developing Position - 75 -...
Confidential BTP-R880NP Programming Manual Appendix C: Control Sequences Code Function Horizontal tab Print and line feed Print and paper feed Print and carriage return Cancel print data in page mode DLE EOT Real-time status transmission DLE ENQ Real-time request to printer...
Page 83
Confidential BTP-R880NP Programming Manual GS ! Select character size GS $ Set absolute vertical print position in page mode GS * Define downloaded bit image GS / Print downloaded bit image GS : Start/end macro definition GS B Turn white/black reverse printing mode on/off...
Need help?
Do you have a question about the BTP-R880NP and is the answer not in the manual?
Questions and answers