2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-25 03:08:27 +08:00

add "blink forever" example

This is useful for quickly demonstrating the idle kernel.
This commit is contained in:
Sebastien Bourdeauducq 2015-10-31 23:17:29 +08:00
parent 0a36b03a12
commit 592663a649

View File

@ -0,0 +1,13 @@
from artiq import *
class BlinkForever(EnvExperiment):
def build(self):
self.setattr_device("core")
self.setattr_device("led")
@kernel
def run(self):
while True:
self.led.pulse(100*ms)
delay(100*ms)