forked from M-Labs/artiq
examples: core device LED test
This commit is contained in:
parent
61c0b65323
commit
b152ecca1f
17
examples/coredev_test.py
Normal file
17
examples/coredev_test.py
Normal file
@ -0,0 +1,17 @@
|
||||
from artiq.language.experiment import Experiment, kernel
|
||||
from artiq.devices import corecom_serial, runtime, core, gpio_core
|
||||
|
||||
class CompilerTest(Experiment):
|
||||
channels = "core led"
|
||||
|
||||
@kernel
|
||||
def run(self):
|
||||
self.led.set(1)
|
||||
|
||||
if __name__ == "__main__":
|
||||
coredev = core.Core(runtime.Environment(), corecom_serial.CoreCom())
|
||||
exp = CompilerTest(
|
||||
core=coredev,
|
||||
led=gpio_core.GPIOOut(coredev, 0)
|
||||
)
|
||||
exp.run()
|
Loading…
Reference in New Issue
Block a user