Kamis, 01 Oktober 2020

Python Escpos Printer Epson TM-T88 / TM-T20 (Raspberry PI)

Tutorial Python Escpos Printer Epson TM-T88 / TM-T20 Di Raspberry PI

Install PIP :

# sudo pip3 install pyusb
# sudo pip3 install pillow
# sudo pip3 install piserial
# sudo pip3 install qrcode
# sudo pip3 install python-barcode
# sudo pip3 install python-escpos
# sudo apt-get install libopenjp2-7
# sudo apt-get install libtiff5

 View USB Device :

# usb-devices

 

 

Code :

from escpos.printer import Usb
p = Usb(0x0483, 0x5743)
p.text('Hello World!\n')
p.cut()

https://github.com/python-escpos/python-escpos

https://stackoverflow.com/questions/48012582/pillow-libopenjp2-so-7-cannot-open-shared-object-file-no-such-file-or-directo 
 

Tidak ada komentar:

Posting Komentar