Interacting with a Brother PTouch Printer?

Brother PTouch QL Series printers have USB interfaces and are capable of printing QR codes. Here's a typical model:

http://www.ptouchdirect.com/ptouch/new_ql570.html

How can I prepare input (i.e. format) for these printers and talk to them directly from my program? I'm interested in the Windows, Mac, Linux platforms. Any language, the Python library, would be perfect.

I do not want to generate output (for example, CSV) and ask the user to download it to the application provided by Brother.

+7
source share
3 answers

I used the iText library to print QR barcodes. It can generate a barcode image and place it in a PDF file that the user can send to the printer. This is a Java library, and .NET access is also available.

+4
source

I can’t talk about Windows, but Brother traditionally has very full Linux support. Here is a list of drivers for the PTouch models . Using these drivers, you can print through CUPS (using the lp or lpr commands) using any darn file format that is suitable for you.

OS X also uses CUPS, so printing on it will be very similar to Linux ... given that you can find the right drivers.

+4
source

There is a brother package, part of pypi:

https://pypi.python.org/pypi/brotherprint/0.1.1

It is assumed that it will handle sending sockets, but I have not tried:

 import re '''Brother Python EscP Command Library Description: A collection of functions to more easily facilitate printing to the Brother QL label printers without having to memorize the ESC/P commands. Also handles sending to sockets for you. ''' class BrotherPrint: font_types = {'bitmap': 0, 'outline': 1} def __init__(self, fsocket): self.fsocket = fsocket self.fonttype = self.font_types['bitmap'] 

see https://github.com/fozzle/python-brotherprint/blob/master/brotherprint/brotherprint.py

+2
source

All Articles