用于在页面模式下打印图像数据的ESC-POS代码
问题描述:
我在页面模式下打印图像数据时遇到困难。我之所以能够在标准模式打印图像数据如下:用于在页面模式下打印图像数据的ESC-POS代码
data[] = { ESC ,
'*' ,
0 , // 8-dot single density mode
width , // nl: image width
0 } // nh: image width
for each 8 x image_width block of pixels in a monochrome image
for each 8 x 1 (vertical) strip of pixels in the block
append pixel (0 or 1) data to the array, data[]
write data to COM port
我在页面模式打印(不成功)尝试如下上面和收益的变化:
select page mode by writing the chars, ESC and 'L' to the COM port
write pixel data as described above
print by writing the characters ESC and FF
我究竟做错了什么?我是否必须指定打印区域或类似的东西?
顺便说一句,我正在编程Epson TM-T88III。
答
找到了答案。在写入每个8 x image_width像素块到COM端口后写入ESC J n
(打印和送纸)命令。
我也在android打印机上工作。你能告诉我怎样才能在android –
执行POS ESC命令我的查询是http://*.com/questions/15701465/how-to-get-the-print-from-the-thermal-printer-in -android –
@NareshSharma不幸的是,我不能帮助,因为我不熟悉你正在使用的设备。我不通过任何驱动程序打印,而是将“原始”ESC/POS命令发送给打印机。抱歉。 – Olumide