Understanding the barcode scanner