labscript_utils.camera_server.CameraServer¶
- class labscript_utils.camera_server.CameraServer(port)[source]¶
Bases:
zprocess.clientserver.ZMQServer
Methods
__init__
(port)abort
()To be overridden by subclasses.
handler
(request_data)To be overridden by subclasses.
mainloop
()setup_auth
(context)Deprecated.
shutdown
()shutdown_on_interrupt
()timeout
()A function to call every self.timeout_interval seconds in the same thread as the handler.
transition_to_buffered
(h5_filepath)To be overridden by subclasses.
transition_to_static
(h5_filepath)To be overridden by subclasses.
- abort()[source]¶
To be overridden by subclasses. Return cameras and any other state to one in which transition_to_buffered() can be called again. abort() will be called if there was an exception in either transition_to_buffered() or transtition_to_static(), and so should ideally be written to return things to a sensible state even if those methods did not complete. Like any cleanup function, abort() should proceed to further cleanups even if earlier cleanups fail. As such it should make liberal use of try: except: blocks, so that an exception in performing one cleanup operation does not stop it from proceeding to subsequent cleanup operations