AndBondStyle / niimprint

Python library for Niimbot label printers. Supports D11/B21/B1 via bluetooth or USB.
MIT License
202 stars 29 forks source link

Daemon mode and keepalive #9

Open AndBondStyle opened 8 months ago

AndBondStyle commented 8 months ago

I would like to have my printer in always-on mode to allow printing at any time (e.g. connected to a raspberry pi server).First we need to add a background thread that continuously sends keepalive messages to prevent the printer from turning off. Then maybe add a new CLI command that runs as a daemon and allows to run print command without specifying any connection params (or even via HTTP API). However, maybe this is out of the scope of this library and it's better to keep things simple.