sample code for barcodes