epson-tm-t88v-emulator
v0.0.2
Published
Emulator of the Epson TM-T88V thermal receipt printer
Downloads
224
Readme
Epson TM-T88V Emulator
Note: This package is not production-ready
A software implementation of a certain thermal receipt printer. Consumes raw bytes (ESC/POS) and renders to an HTML canvas.
Tests
To add a new test:
- Create a new directory in
test/data. Give the directory a name that describes the test. - Come up with some ESC/POS that demonstrates a specific feature of the receipt printer. Put that in
in.txtas hexadecimal. - This is not strictly necessary for the test to work, but in case of improvements to the text data pipeline, put the original scanned image of the receipt in the directory (e.g.
scan.jpg. - Use deskew-text to generate
ref.pngfromscan.jpg. It should have straightened and thresholded (made pure black-and-white)scan.jpg. - Now when you run
npm test, it should detect the new directory you created and generatediff.png, which you can then visually inspect for differences between the emulator output and the real-life output.
