lsongdev / lsongdev/node-escpos

printers are printing gibberish

Open
#401 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
1.6k
Forks
443
PR merge metrics
No merged PRs in 30d

Description

### Discussed in https://github.com/song940/node-escpos/discussions/400

Originally posted by **sharmamangita** August 22, 2022
Hi,
I used [escpos](https://github.com/song940/node-escpos) for printing the value for that I am using this link https://www.npmjs.com/package/escpos and my code is for the printer is that

const escpos = require('escpos'); //for printing order on epson printer
escpos.Network = require('escpos-network');

const device = new escpos.Network(ipaddress, port);
var options = { encoding: "EUC-KR"};
const printer = new escpos.Printer(device, options);

I want to print the value the in English language but sometimes it shows gibberish and it's not happening in any particular case. gibberish printer randomly. Please check the screenshot also
![185500490-1a56ac5a-b000-4958-87d6-b0591bac5437](https://user-images.githubusercontent.com/15026334/185901137-b8f82879-1c03-409f-95bf-73612cfca430.jpeg)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named. Start by reproducing the printer output with the shown escpos.Network setup and Printer options using English text, then inspect how encoding and network printing are handled. Done means the cause of the intermittent gibberish is identified and English output prints reliably.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js
Domain
embedded-iot
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.