Hey,
is it possible to terminate a run, if it was started with artiq_run?
Terminate run when using artiq_run
Hit Ctrl-C?
For a simple script like
from artiq.experiment import *
class RunCancel(EnvExperiment):
def build(self):
self.setattr_device("core")
self.setattr_device("ttl4")
@kernel
def run(self):
self.core.reset()
delay(10*ms)
self.core.break_realtime()
delay(10*ms)
for i in range(10):
self.ttl4.on()
delay(0.5*s)
self.ttl4.off()
delay(0.5*s)
artiq_run returns before the run is over, so I cant press ctrl-c .
That's due to seamless handover. Make it wait for RTIO with core.wait_until_mu(now_mu())
at the end, or, to interrupt, run another core.reset()
in a new kernel.