diff options
author | Balint Seeber <balint@ettus.com> | 2014-11-03 17:35:00 -0800 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2014-11-13 01:16:18 +0100 |
commit | c626ba3541877102a5c7ff204764dd3c6c102763 (patch) | |
tree | 60da85a108fc246253045acc77dc165cebbd167f /host/utils/latency/run_tests.py | |
parent | 883dff1623045165d7279eb3907b34ed6dd5101b (diff) | |
download | uhd-c626ba3541877102a5c7ff204764dd3c6c102763.tar.gz uhd-c626ba3541877102a5c7ff204764dd3c6c102763.tar.bz2 uhd-c626ba3541877102a5c7ff204764dd3c6c102763.zip |
latency: fixed bugs in test running and grapher
Diffstat (limited to 'host/utils/latency/run_tests.py')
-rwxr-xr-x | host/utils/latency/run_tests.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/host/utils/latency/run_tests.py b/host/utils/latency/run_tests.py index f0cb31ffb..da3b702b6 100755 --- a/host/utils/latency/run_tests.py +++ b/host/utils/latency/run_tests.py @@ -22,8 +22,10 @@ from string import split import sys import os -from gnuradio.eng_option import eng_option - +try: + from gnuradio.eng_option import eng_option +except: + eng_option = None def launch_test(args="", rate=None, spb=None, spp=0, prefix="", suffix="", extra=[], verbose=False, title=None): real = os.path.realpath(__file__) @@ -78,7 +80,9 @@ class ReturnCode: def get_initialized_OptionParser(): def_rates = ".25 1 4 8 25" usage = "%prog: [options] -- [extra arguments]" - parser = OptionParser(option_class=eng_option, usage=usage) + opt_kwds = {} + if eng_option: opt_kwds['option_class'] = eng_option + parser = OptionParser(usage=usage, **opt_kwds) parser.add_option("", "--rates", type="string", help="sample rates (Msps) [default: %default]", default=def_rates) parser.add_option("", "--spbs", type="string", help="samples per block [default: %default]", |