diff --git a/link_test/link_tester.py b/link_test/link_tester.py index 990e89eb..15171f31 100644 --- a/link_test/link_tester.py +++ b/link_test/link_tester.py @@ -52,6 +52,6 @@ def run(n_chips=None): if __name__ == "__main__": n_chips = None - if len(sys.argv) > 0: - n_chips = int(sys.argv[0]) + if len(sys.argv) > 1: + n_chips = int(sys.argv[1]) run(n_chips) diff --git a/link_test/run_link_test.py b/link_test/run_link_test.py index 8917da90..547f5325 100644 --- a/link_test/run_link_test.py +++ b/link_test/run_link_test.py @@ -97,7 +97,7 @@ def test_run(x, y): if __name__ == "__main__": n_chips = None - if len(sys.argv) > 0: - n_chips = int(sys.argv[0]) + if len(sys.argv) > 1: + n_chips = int(sys.argv[1]) link_test = LinkTest() link_test.do_run(n_chips)