0

我有 TVS Dotmtrix 打印机 9 针,用于(纸卷)上的收据打印。使用 Python 我希望打印机垂直向上移动 4 行并在打印文件发送到打印机时开始打印

我使用了一些转义码,例如 "\x1b\x28\x76\2\0\2\4" 和 "\x1b\x65\4"

但两者都在打印机打开时第一次工作,然后开始普通打印(不向上移动或不向下拉纸)。

请提出一些可行的解决方案。我是 Python 新手,编程

4

1 回答 1

0
To pull page roll downward (reverse print)

This code working well for me both in TVS as well as Epson Dot Matrix Printer


'\x1Bj2'


some useful codes are given
<a href="http://stanislavs.org/helppc/epson_printer_codes.html" target="_blank">here</a>


I put '\x1Bj2' code at the top of my printing file and then write other texts. 


So, when printer start print it first pull paper downward(reverse) one line and then start printing.
于 2018-12-19T14:09:25.983 回答