forked from M-Labs/artiq
1
0
Fork 0

examples: with sequential -> with parallel

This commit is contained in:
Robert Jördens 2016-02-23 18:39:02 +01:00
parent 53ca3a8be8
commit 969f282de9
5 changed files with 7 additions and 7 deletions

View File

@ -28,7 +28,7 @@ class PhotonHistogram(EnvExperiment):
@kernel @kernel
def cool_detect(self): def cool_detect(self):
with interleave: with parallel:
self.bd_sw.pulse(1*ms) self.bd_sw.pulse(1*ms)
self.bdd_sw.pulse(1*ms) self.bdd_sw.pulse(1*ms)
@ -36,7 +36,7 @@ class PhotonHistogram(EnvExperiment):
self.bd_sw.pulse(100*us) self.bd_sw.pulse(100*us)
self.bd_dds.set(self.detect_f) self.bd_dds.set(self.detect_f)
with interleave: with parallel:
self.bd_sw.pulse(self.detect_t) self.bd_sw.pulse(self.detect_t)
self.pmt.gate_rising(self.detect_t) self.pmt.gate_rising(self.detect_t)

View File

@ -27,7 +27,7 @@ class DDSTest(EnvExperiment):
self.led.on() self.led.on()
else: else:
self.led.off() self.led.off()
with interleave: with parallel:
with sequential: with sequential:
self.dds0.set(100*MHz + 4*i*kHz) self.dds0.set(100*MHz + 4*i*kHz)
self.ttl0.pulse(500*us) self.ttl0.pulse(500*us)

View File

@ -62,7 +62,7 @@ class TDR(EnvExperiment):
@kernel @kernel
def one(self, t, p): def one(self, t, p):
t0 = now_mu() t0 = now_mu()
with interleave: with parallel:
self.pmt0.gate_both_mu(2*p) self.pmt0.gate_both_mu(2*p)
self.ttl2.pulse_mu(p) self.ttl2.pulse_mu(p)
for i in range(len(t)): for i in range(len(t)):

View File

@ -24,7 +24,7 @@ class AluminumSpectroscopy(EnvExperiment):
delay(10*us) delay(10*us)
self.laser_cooling.pulse(100*MHz, 100*us) self.laser_cooling.pulse(100*MHz, 100*us)
delay(5*us) delay(5*us)
with interleave: with parallel:
self.spectroscopy.pulse(self.spectroscopy_freq, 100*us) self.spectroscopy.pulse(self.spectroscopy_freq, 100*us)
with sequential: with sequential:
delay(50*us) delay(50*us)
@ -32,7 +32,7 @@ class AluminumSpectroscopy(EnvExperiment):
delay(5*us) delay(5*us)
while True: while True:
delay(5*us) delay(5*us)
with interleave: with parallel:
self.state_detection.pulse(100*MHz, 10*us) self.state_detection.pulse(100*MHz, 10*us)
photon_count = self.pmt.count_gate(10*us) photon_count = self.pmt.count_gate(10*us)
if (photon_count < self.photon_limit_low if (photon_count < self.photon_limit_low

View File

@ -11,7 +11,7 @@ class SimpleSimulation(EnvExperiment):
@kernel @kernel
def run(self): def run(self):
with interleave: with parallel:
with sequential: with sequential:
self.a.pulse(100*MHz, 20*us) self.a.pulse(100*MHz, 20*us)
self.b.pulse(200*MHz, 20*us) self.b.pulse(200*MHz, 20*us)