https://github.com/joonas-fi/bro
Print text and barcodes from command line to Brother P-Touch printers.
https://github.com/joonas-fi/bro
Last synced: about 1 month ago
JSON representation
Print text and barcodes from command line to Brother P-Touch printers.
- Host: GitHub
- URL: https://github.com/joonas-fi/bro
- Owner: joonas-fi
- Created: 2023-03-12T14:14:31.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-03-25T16:22:58.000Z (about 2 years ago)
- Last Synced: 2025-02-01T19:44:34.664Z (3 months ago)
- Size: 104 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
⬆️ For table of contents, click the above icon
Print text and barcodes from command line to Brother P-Touch printers.
TODO: a web service.
WARNING
-------Currently it's shit code.
Tested hardware
---------------Brother P-Touch Cube PT-P300BT

Other models may work, but are not guaranteed to do so.
12 mm tape
Quickstart
----------Overall flow:
1. Download this software from GitHub releases page
1. Make printer available as a serial port (has to be done only once)
* Run `$ sudo bluetoothctl`
* Type `scan on`
* Find device with name beginning with `PT-P...` (the name is the Brother printer model name)
* Type `pair ` (where the address is something like `EC:79:49:...`)
* Then `$ sudo rfcomm bind 0 `
* This should make `/dev/rfcomm0` appear
1. Print to it
* `$ ./bro datamatrix helloworld hello.png`
* `$ ./bro print hello.png`Architecture
------------```mermaid
flowchart TD
makePrintJobs --> looper[loop over print jobs]
looper --> looper
looper --> rasterizer
rasterizer --> rasterizeBarcode[rasterize barcode]
rasterizer --> rasterizeText[rasterize text]
looper --> D[send raster to printer]```
Thanks
------- https://github.com/robby-cornelissen/pt-p710bt-label-maker
* Got me started on reverse-engineering this and serves as the base for the initial port