I have a 2d barcode scanner (Honeywell Xenon 1900).
Scanning 1D barcodes is easy as the scanner emulates keyboard events and sends plain text.
But when I scan the PDF417 2D barcode format , the scanner sends binary data. How can I capture and decode this data? Some characters cannot be printed, so scanning in the form on a web page will not work.
My solution for this is to use a COM port.
, , COM-. Java-, ( RXTX). COM- , .
java, javascript. . , javascript base64. btoa() atob().
btoa()
atob()
function toBase64 () { return window.btoa(data); } function fromBase64 (strBase64){ data = window.atob(strBase64); }
, ( , , ), base64 ENCODE javascript/html/web-. , java, . , base64 -, .
base64