allow setting of explicit barcode type

fixes #7