我有TVS Dotmtrix打印机9针,用于(纸卷)上的收据打印。用Python 我希望打印机垂直向上移动4行并在将打印文件发送到打印机时开始打印
我使用了一些转义代码,例如“ \ x1b \ x28 \ x76 \ 2 \ 0 \ 2 \ 4” 和“ \ x1b \ x65 \ 4”
BUT都在打印机打开时第一次工作,然后开始普通打印(不向上移动或不向下拉纸张)。
请提出一些可行的解决方案。 我是Python新手,编程
答案 0 :(得分: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.