forked from M-Labs/artiq
compiler_test: better RPC example
This commit is contained in:
parent
79f20ebfcf
commit
8cb3d33c67
|
@ -9,14 +9,15 @@ class CompilerTest(Experiment):
|
||||||
def print_done(self):
|
def print_done(self):
|
||||||
print("Done!")
|
print("Done!")
|
||||||
|
|
||||||
def print_iter(self, n):
|
def set_some_slowdev(self, n):
|
||||||
print("Iteration: {}".format(n))
|
print("Slow device setting: {}".format(n))
|
||||||
|
|
||||||
@kernel
|
@kernel
|
||||||
def run(self, n, t2):
|
def run(self, n, t2):
|
||||||
t2 += 1*us
|
t2 += 1*us
|
||||||
for i in my_range(n):
|
for i in my_range(n):
|
||||||
self.print_iter(i)
|
self.set_some_slowdev(i)
|
||||||
|
delay(100*ms)
|
||||||
with parallel:
|
with parallel:
|
||||||
with sequential:
|
with sequential:
|
||||||
self.a.pulse(100*MHz, 20*us)
|
self.a.pulse(100*MHz, 20*us)
|
||||||
|
|
Loading…
Reference in New Issue