diff --git a/script/local.py b/script/local.py index fc22674..314bdbf 100644 --- a/script/local.py +++ b/script/local.py @@ -32,6 +32,23 @@ def set_led_range(room_temp = True): +################################################################################################### +# Barcode reader +################################################################################################### + +def enable_barcode_reader(): + microscan_cmd.write("") + +def disable_barcode_reader(): + microscan_cmd.write("") + +def read_barcode(timeout): + try: + return microscan.waitString(int(timeout * 1000)) + except: + return None + + ################################################################################################### # Image processing utilities ###################################################################################################