Open simonkuehling opened 2 months ago
These printers have really small buffers, so they can be easily filled up if you're printing multiple large images. The network backend doesn't support bidirectional communication at the moment, so there's no way for the library to know the printer's buffer is full. The blocking
option for send()
has no effect if the network backend is used.
Hi,
sending a larger print job to the QL1110-NWB printer often runs into a timeout of the write command (which is 10s as far as I can tell from the code). The timeout looks to be tied to the amount of bytes transferred to the printer - somewhere up to 280k bytes still works, ~400k bytes trip the timeout. To reproduce this, the following
cli.py
line can be used:test.png
is a 1164x1660 px PNG image (shipping labels in my case).In a script I am using I am currently working around this by sending the instructions in blocks of 50kB like this:
I could not find out if the printer is just slow in receiving the data generally or if it pauses in between to print the first label in order to free up memory for more data to be transmitted. Which means that I am not too sure if my solution is the proper way to handle this or if it just happens to work in my setup right now...
Maybe something along these lines should be implemented in the library?