diff --git a/script/local.py b/script/local.py index 32b7f00..06e6ee1 100644 --- a/script/local.py +++ b/script/local.py @@ -108,6 +108,12 @@ def wait_device(dev, value, timeout=-1): dev.waitValue(value,timeout) print "Done waiting" +def wait_device_in_range(dev, value, range, timeout=-1): + timeout = int(timeout *1000) if timeout>0 else timeout + print "Waiting " + dev.getName() + " = " + str(value) + dev.waitValueInRange(value, range, timeout) + print "Done waiting" + def convert_file(input_file_name, output_file_name, pol = None): print "Converting data file: " + input_file_name + " to " + output_file_name sep = "\t"