Commit d98da911 authored by Martin Drechsler's avatar Martin Drechsler

joined backend threads in one

parent b445f349
...@@ -39,30 +39,28 @@ if __name__ == "__main__": ...@@ -39,30 +39,28 @@ if __name__ == "__main__":
shutter866WM = digital_control_signal('shutter866WM', channel = 3, inverse=False) shutter866WM = digital_control_signal('shutter866WM', channel = 3, inverse=False)
controlGui = ControlGui() controlGui = ControlGui()
mcDAQthread = QtCore.QThread() backendThread = QtCore.QThread()
for ao in anal_control_signal._registry: for ao in anal_control_signal._registry:
controlGui.make_connections(ao) controlGui.make_connections(ao)
ao.make_connections(controlGui) ao.make_connections(controlGui)
ao.moveToThread(mcDAQthread) ao.moveToThread(backendThread)
ao.scanTimer.moveToThread(mcDAQthread) ao.scanTimer.moveToThread(backendThread)
ao.scanTimer.timeout.connect(ao.scan_event) ao.scanTimer.timeout.connect(ao.scan_event)
for do in digital_control_signal._registry: for do in digital_control_signal._registry:
do.make_connections(controlGui) do.make_connections(controlGui)
do.moveToThread(mcDAQthread) do.moveToThread(backendThread)
cameraMainWindow = CameraGuiMainWindow() cameraMainWindow = CameraGuiMainWindow()
cameraWorker = CameraWorker(camera) cameraWorker = CameraWorker(camera)
cameraThread = QtCore.QThread() cameraWorker.moveToThread(backendThread)
cameraWorker.moveToThread(cameraThread)
cameraWorker.make_connections(cameraMainWindow) cameraWorker.make_connections(cameraMainWindow)
myGuiMainWindow.make_connections(cameraWorker) cameraMainWindow.make_connections(cameraWorker)
cameraThread.start() backendThread.start()
mcDAQthread.start()
controlGui.toolbar.load() controlGui.toolbar.load()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment