EAN-13 Barcode Reader implementation in JavaScript