Startup
This commit is contained in:
20
script/tutorial/02_ScanCallbacks.py
Normal file
20
script/tutorial/02_ScanCallbacks.py
Normal file
@@ -0,0 +1,20 @@
|
||||
"""
|
||||
Demonstrate use of scan callbacks to trigger a detector at falling edge.
|
||||
"""
|
||||
|
||||
def BeforeReadout():
|
||||
ao1.write(1)
|
||||
ao1.write(0)
|
||||
|
||||
#Example with an epics direct channel access
|
||||
#caput("CHANNEL_NAME", 1)
|
||||
#caput("CHANNEL_NAME", 0)
|
||||
|
||||
index=0
|
||||
|
||||
def AfterReadout():
|
||||
global index
|
||||
print "Aquired frame: " + str(index)
|
||||
index=index+1
|
||||
|
||||
a= lscan((m1,m2), (ai1, ai2), (0,0), (4,8), steps=20, latency = 0.01, before_read=BeforeReadout, after_read=AfterReadout)
|
||||
Reference in New Issue
Block a user