Files
escwebprint/README.md
2026-03-27 11:25:00 +01:00

812 B

escwebprint

Print any webpage on a ESCPOS compatible thermal printer

Usage

Create a virtual environment and install requirements.

python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt

Install headless firefox

playwright install firefox

Print your page

./escwebprint.py https://distorsion.interhacker.space/ /dev/usb/lp0 --profile TM-T20II

Printer profile

In order to correctly configure your printer, you should select its model in supported profiles of python-escpos. Check the page python-escpos.readthedocs.io/en/latest/printer_profiles/available-profiles.html for a list of available profiles.

If not defined, creenshot will be only 300 pixels wide.