简体   繁体   中英

What does "ESC/Print initializing command" means?

I have qot android app for printing the cp1250 chars to ESC/POS BT printer.
I initialize the printer with header

byte header[] = null;
header = new byte[] { 0x1b, 0x40, 0x1c, 0x26, 0x1b, 0x39, 0x01 };
os.write(header);
  • 0x1b, 0x40 - initialize printer
  • 0x1c, 0x26 - Kanji character mode
  • 0x1b, 0x39, 0x01 - what does it mean ?

Would it be possible to explain what is Kanji character mode ? If i print with whole header { 0x1b, 0x40, 0x1c, 0x26, 0x1b, 0x39, 0x01 } my printing cp1250 characters is right. If I use only { 0x1b, 0x40 } printing cp1250 chars is wrong

The specification of the command supported by the printer is included in the device driver which can be downloaded from this page.
Rongta Tech - Thermal Receipt Printer Driver, Mobile Printer Driver
Portable Printer 58mm CD (For RPP200/02/02N/210/210A/02A/02B)

However, the commands corresponding to 0x1B, 0x39, 0x01 did not seem to exist.

The command of 0x1C, 0x26 is described and has the following contents.
This is the same as EPSON's ESC/POS.
FS &

 FS & [Name] Select Kanji character mode [Format] ASCII FS & Hex 1C 26 Decimal 28 38 [Description] Selects Kanji character mode. [Notes] For Kanji model: - When the Kanji character mode is selected, the printer processes all Kanji code as two bytes each. - Kanji codes are processed in the order of the first byte and second byte. - Kanji character mode is not selected when the power is turned on. [Reference] FS .

The command to switch to code page 1250 is 0x1B, 0x74, 0x1E.

 ESC tn [Name] Select character code table [Format] ASCII ESC tn Hex 1B 74 n Decimal 27 116 n [Range] 0 ≤ n ≤ 5, 16 ≤ n ≤ 19, n = 255 [Description] Selects page n from the character code table. 30 WCP1250[Central Europe]

Kanji character mode is a mode to print Japanese character set.


In Addition:

Looking at the details, code page 1250 is not supported in the specification.
n parameter 30 was not in the supported range.

 [Range] 0 ≤ n ≤ 5, 16 ≤ n ≤ 19, n = 255

If your control code allows the code page 1250 to print, it's either private or hasn't been documented yet.

{ 0x1b, 0x40, 0x1c, 0x26, 0x1b, 0x39, 0x01 }

Please ask your vendor's support desk.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM