labscript-suite-oldfinal1 / labscript

The labscript Python library provides a translation from simple Python code to complex hardware instructions. The library is used to construct a "connection table" containing information about what hardware is being used and how it is interconnected. Devices described in this connection table can then have their outputs set by using a range of functions, including arbitrary ramps.
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

labscript should reject commands after a wait if they have a time before the last wait #4

Open philipstarkey opened 10 years ago

philipstarkey commented 10 years ago

Original report (archived issue) by Philip Starkey (Bitbucket: pstarkey, GitHub: philipstarkey).


To avoid confusion, once you call

#!python

wait(t)

you should not be able to issue subsequent commands with a time before 't'.

For example, you might call:

#!python

t+=wait(t)
# science!

# image
camera.expose(t-70e-3)

Depending on the length of science, your exposure may start before or after the wait. Labscript cannot do anything to fix the sequence of events, but it can refuse to trigger the camera before the wait if it implements the above suggestion.