artiq-zynq/examples/blink_forever.py

15 lines
301 B
Python
Raw Permalink Normal View History

2020-04-12 09:45:52 +08:00
from artiq.experiment import *
class BlinkForever(EnvExperiment):
def build(self):
self.setattr_device("core")
self.setattr_device("led0")
@kernel
def run(self):
self.core.reset()
while True:
self.led0.pulse(100*ms)
delay(100*ms)