Skip to content

crdx/label

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

label

label prints text labels on the Brother PT-P710BT over USB or Bluetooth.

Installation

go install crdx.org/label/cmd/label@latest

Usage

Usage:
    label [options] print <text>
    label [options] status

The printer is auto-detected: USB is tried first, then Bluetooth. Note that Bluetooth is only supported on Linux.

The default font is Spleen for its aesthetics when printed on the PT-P710BT, but this is subject to change.

USB permissions

Raw USB access requires permission to open the device node. Either run it as root, or add a udev rule:

echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="04f9", ATTRS{idProduct}=="20af", TAG+="uaccess"' \
    | sudo tee /etc/udev/rules.d/70-ptouch.rules
sudo udevadm control --reload

Then disconnect and reconnect the printer.

Bluetooth

Bluetooth uses Linux RFCOMM sockets and BlueZ, so it is only supported on Linux.

Pair the printer once with bluetoothctl (use PIN 0000 if prompted):

[bluetooth]# scan on
[bluetooth]# pair A4:C1:38:AB:CD:EF
[bluetooth]# trust A4:C1:38:AB:CD:EF

Credits

Contributions

Open an issue or send a pull request.

Licence

MIT.

About

a label printer and design language

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors