kasli_tester: bail out when run from ARTIQ master

This commit is contained in:
Sebastien Bourdeauducq 2018-05-18 23:30:52 +08:00
parent 3cbcb3bff6
commit f457b59985
1 changed files with 5 additions and 0 deletions

View File

@ -25,6 +25,11 @@ def is_enter_pressed() -> TBool:
class KasliTester(EnvExperiment):
def build(self):
# hack to detect artiq_run
if self.get_device("scheduler").__class__.__name__ != "DummyScheduler":
raise NotImplementedError(
"must be run with artiq_run to support keyboard interaction")
self.setattr_device("core")
self.leds = dict()