add stepper pulser

This commit is contained in:
Sebastien Bourdeauducq 2022-08-04 13:56:13 +08:00
parent bd903b530d
commit 6e95a08608
1 changed files with 46 additions and 0 deletions

46
stepper.py Normal file
View File

@ -0,0 +1,46 @@
from artiq.experiment import *
class Stepper(EnvExperiment):
def build(self):
self.setattr_device("core")
self.setattr_device("ttl0")
self.setattr_device("ttl1")
@kernel
def run(self):
self.core.reset()
while True:
delay(5*ms)
for i in range(4000):
self.ttl0.pulse(5*us)
delay(5*us)
for i in range(4000):
self.ttl0.pulse(2*us)
delay(2*us)
for i in range(100000):
self.ttl0.pulse(1*us)
delay(1*us)
for i in range(4000):
self.ttl0.pulse(2*us)
delay(2*us)
for i in range(4000):
self.ttl0.pulse(5*us)
delay(5*us)
delay(5*ms)
for i in range(4000):
self.ttl1.pulse(5*us)
delay(5*us)
for i in range(4000):
self.ttl1.pulse(2*us)
delay(2*us)
for i in range(100000):
self.ttl1.pulse(1*us)
delay(1*us)
for i in range(4000):
self.ttl1.pulse(2*us)
delay(2*us)
for i in range(4000):
self.ttl1.pulse(5*us)
delay(5*us)