1.1.0 • Published 8 years ago
node128 v1.1.0
node128
a simple Code 128 encoder (optimizing).
install
npm install -g node128
use the cli
encode128 yourText
outputs the encoded string.
use in your own Projects
When you pass a string to its encode function, it adds the start and stop codes to the string and calculates the checksum. It is supposed to work with a code 128 font
var encoder= new Encoder()
console.log(encoder.encode("Test"))
prints: ÑTestWÓ
- Ñ is the Start Code B (ascii 209)
- Ó is the Stop Code (ascii 211)
- W is the Checksum (ascii 87)
print this string with a Code 128 Font.