Skip to content

Commit 4ba281f

Browse files
Merge pull request #950 from TheDeanLab/637-dichroic-control-1
637 dichroic control 1
2 parents 315f667 + 328cf91 commit 4ba281f

File tree

11 files changed

+319
-58
lines changed

11 files changed

+319
-58
lines changed
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
================
2+
Dichroic Turrets
3+
================
4+
5+
Dichroics can be used to reflect the excitation light towards the camera, while
6+
permitting the emission light that is captured by the objective to be transmitted
7+
to the camera. Alternatively, they can be placed in the detection path to separate
8+
different emission wavelengths and to direct it to the appropriate camera.
9+
10+
Currently, **navigate** incorporates a dichroic turret as a filter wheel, which enables
11+
you to add as many different dichroic turrets as you would like.
12+
13+
.. note::
14+
15+
The `name` parameter under `hardware` is optional. If not provided, the name of the
16+
device will be default to Filter 0, Filter 1, ... Filter N in the GUI. However, if
17+
is is provided, then the GUI will automatically use the name provided as a label.
18+
19+
ASI
20+
---
21+
22+
C60-CUBE-SLDR
23+
~~~~~~~~~~~~~
24+
25+
The `C60-CUBE-SLDR <https://www.asiimaging.com/illumination-control/c60-cube-sldr/>`_
26+
is a motorized dichroic slider that can be controlled by the ASI Tiger Controller.
27+
The example below shows the configuration file with one dichroic turret, and one
28+
filter wheel. The same communication instance is used for both the stage and filter
29+
wheel. It holds a maximum of 4 dichroics.
30+
31+
32+
.. collapse:: Configuration File
33+
34+
.. code-block:: yaml
35+
36+
microscopes:
37+
microscope_name:
38+
-
39+
filter_wheel:
40+
hardware:
41+
type: ASI
42+
name: Filter Wheel 1
43+
wheel_number: 1
44+
port: COM1
45+
baudrate: 115200
46+
filter_wheel_delay: 0.03
47+
available_filters:
48+
Empty-Alignment: 0
49+
GFP: 1
50+
RFP: 2
51+
Far-Red: 3
52+
-
53+
filter_wheel:
54+
hardware:
55+
type: ASICubeSlider
56+
name: Dichroic Turret 1
57+
wheel_number: 2
58+
port: COM1
59+
baudrate: 115200
60+
filter_wheel_delay: 0.25
61+
available_filters:
62+
510LP: 0
63+
560LP: 1
64+
600LP: 2
65+
660LP: 3
66+
|

docs/source/user_guide/hardware/filter_wheel.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ file as follows:
1717
-
1818
filter_wheel:
1919
hardware:
20+
name: Lower Filter Wheel
2021
type: SutterFilterWheel
2122
wheel_number: 1
2223
port: COM1
@@ -30,6 +31,7 @@ file as follows:
3031
-
3132
filter_wheel:
3233
hardware:
34+
name: Upper Filter Wheel
3335
type: SutterFilterWheel
3436
wheel_number: 2
3537
port: COM1
@@ -42,6 +44,12 @@ file as follows:
4244
Far-Red: 3
4345
|
4446
47+
.. note::
48+
49+
The `name` parameter under `hardware` is optional. If not provided, the name of the
50+
device will be default to Filter 0, Filter 1, ... Filter N in the GUI. However, if
51+
is is provided, then the GUI will automatically use the name provided as a label.
52+
4553
-----------
4654

4755
Sutter Instruments
@@ -107,7 +115,7 @@ for the stage. A single communication instance is used for both the stage and fi
107115
type: ASI
108116
wheel_number: 1
109117
port: COM1
110-
baudrate: 9600
118+
baudrate: 115200
111119
filter_wheel_delay: 0.03
112120
available_filters:
113121
Empty-Alignment: 0

docs/source/user_guide/hardware/hardware_home.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ Additional devices are available by installing the
2121
remote_focus.rst
2222
stage.rst
2323
filter_wheel.rst
24+
dichroic.rst
2425
galvo.rst
2526
laser.rst
2627
shutter.rst

docs/source/user_guide/hardware/stage.rst

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ first establish communication with the device using `ASI provided software <http
7272
stages:
7373
refmode:
7474
port: COM12
75-
baudrate: 9600
75+
baudrate: 115200
7676
timeout: 0.25
7777
joystick_axes: [x, y, z]
7878
x_min: -10000.0
@@ -233,7 +233,7 @@ the software is restarted, it should work.
233233
serial_number: 001
234234
axes: [x, y, z]
235235
axes_mapping: [x, y, z]
236-
feedback_alignment:
236+
feedback_alignment:
237237
volts_per_micron: 0.0
238238
min: 0.0
239239
max: 25000
@@ -314,16 +314,16 @@ C-884
314314
serial_number: 119060508
315315
axes: [x, y, z, theta, f]
316316
axes_mapping: [1, 2, 3, 4, 5]
317-
feedback_alignment:
317+
feedback_alignment:
318318
volts_per_micron: 0.0
319-
min:
320-
max:
319+
min:
320+
max:
321321
controllername: C-884
322322
stages: L-509.20DG10 L-509.40DG10 L-509.20DG10 M-060.DG M-406.4PD NOSTAGE
323323
refmode: FRF FRF FRF FRF FRF FRF
324-
port:
325-
baudrate:
326-
timeout:
324+
port:
325+
baudrate:
326+
timeout:
327327
joystick_axes: [x, y, z]
328328
x_min: -10000.0
329329
x_max: 10000.0
@@ -365,16 +365,16 @@ E-709
365365
serial_number: 119060508
366366
axes: [x, y, z, theta, f]
367367
axes_mapping: [1, 2, 3, 4, 5]
368-
feedback_alignment:
368+
feedback_alignment:
369369
volts_per_micron: 0.0
370-
min:
371-
max:
370+
min:
371+
max:
372372
controllername: E-709
373373
stages: L-509.20DG10 L-509.40DG10 L-509.20DG10 M-060.DG M-406.4PD NOSTAGE
374374
refmode: FRF FRF FRF FRF FRF FRF
375-
port:
376-
baudrate:
377-
timeout:
375+
port:
376+
baudrate:
377+
timeout:
378378
joystick_axes: [x, y, z]
379379
x_min: -10000.0
380380
x_max: 10000.0
@@ -424,16 +424,16 @@ positioning.
424424
serial_number: 74000375
425425
axes: [f]
426426
axes_mapping: [1]
427-
feedback_alignment:
427+
feedback_alignment:
428428
volts_per_micron: 0.0
429-
min:
430-
max:
429+
min:
430+
max:
431431
controllername:
432-
stages:
433-
refmode:
434-
port:
435-
baudrate:
436-
timeout:
432+
stages:
433+
refmode:
434+
port:
435+
baudrate:
436+
timeout:
437437
joystick_axes: [f]
438438
x_min: -10000.0
439439
x_max: 10000.0
@@ -481,11 +481,11 @@ KST101
481481
min: 0
482482
max: 25
483483
controllername:
484-
stages:
485-
refmode:
486-
port:
487-
baudrate:
488-
timeout:
484+
stages:
485+
refmode:
486+
port:
487+
baudrate:
488+
timeout:
489489
joystick_axes: [f]
490490
x_min: -10000.0
491491
x_max: 10000.0

src/navigate/config/configuration_database.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@
5757

5858
filter_wheel_device_types = {
5959
"Sutter Instruments": "SutterFilterWheel",
60-
"Applied Scientific Instrumentation": "ASI",
60+
"ASI Filter Wheel": "ASI",
61+
"ASI Dichroic Slider": "ASICubeSlider",
6162
"Ludl Electronic Products": "LUDLFilterWheel",
6263
"Analog/Digital Device": "NI",
6364
"Virtual Device": "synthetic",
@@ -85,6 +86,7 @@
8586
"hardware/wheel_number": ["Number of Wheels", "Spinbox", "int", None, "Example: 1"],
8687
"hardware/port": ["Serial Port", "Input", "string", None, "Example: COM1"],
8788
"hardware/baudrate": ["Baudrate", "Input", "int", None, "Example: 9600"],
89+
"hardware/name": ["GUI Label", "Input", "string", None, "Example: Filter Wheel 1"],
8890
"filter_wheel_delay": [
8991
"Filter Wheel Delay (s)",
9092
"Input",

src/navigate/controller/configuration_controller.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -396,6 +396,24 @@ def number_of_filter_wheels(self):
396396
return len(self.microscope_config["filter_wheel"])
397397
return 1
398398

399+
@property
400+
def filter_wheel_names(self):
401+
"""Return a list of filter wheel names
402+
403+
Returns
404+
-------
405+
filter_wheel_names : list
406+
List of filter wheel names.
407+
"""
408+
filter_wheel_names = []
409+
if self.microscope_config is not None:
410+
for i in range(self.number_of_filter_wheels):
411+
name = self.microscope_config["filter_wheel"][i]["hardware"].get(
412+
"name", f"Filter Wheel {i}"
413+
)
414+
filter_wheel_names.append(name)
415+
return filter_wheel_names
416+
399417
@property
400418
def microscope_list(self):
401419
"""Return a list of microscope names

src/navigate/controller/sub_controllers/channels_settings.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,9 @@ def __init__(self, view, parent_controller=None, configuration_controller=None):
7070
self.configuration_controller.number_of_filter_wheels
7171
)
7272
self.view.populate_frame(
73-
channels=self.num, filter_wheels=self.number_of_filter_wheels
73+
channels=self.num,
74+
filter_wheels=self.number_of_filter_wheels,
75+
filter_wheel_names=self.configuration_controller.filter_wheel_names,
7476
)
7577

7678
#: str: The mode of the channel setting controller. Either 'live' or 'stop'.

src/navigate/model/device_startup_functions.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -189,8 +189,6 @@ def load_camera_connection(configuration, camera_id=0, is_synthetic=False):
189189
camera_connection = configuration["configuration"]["hardware"]["camera"][
190190
camera_id
191191
]["camera_connection"]
192-
193-
# return camera object in the auto_redial function.
194192
return auto_redial(
195193
build_photometrics_connection, (camera_connection,), exception=Exception
196194
)
@@ -875,7 +873,7 @@ def load_filter_wheel_connection(device_info, is_synthetic=False, plugin_devices
875873
exception=Exception,
876874
)
877875

878-
elif device_type == "ASI":
876+
elif device_type == "ASI" or device_type == "ASICubeSlider":
879877
from navigate.model.devices.filter_wheel.asi import (
880878
build_filter_wheel_connection,
881879
)
@@ -969,6 +967,11 @@ def start_filter_wheel(
969967

970968
return ASIFilterWheel(device_connection, device_config)
971969

970+
elif device_type == "ASICubeSlider":
971+
from navigate.model.devices.filter_wheel.asi import ASICubeSlider
972+
973+
return ASICubeSlider(device_connection, device_config)
974+
972975
elif device_type == "NI":
973976
from navigate.model.devices.filter_wheel.ni import DAQFilterWheel
974977

@@ -1058,7 +1061,7 @@ def start_shutter(
10581061
Name of microscope in configuration
10591062
device_connection : object
10601063
Hardware device to connect to
1061-
configuration : multiprocesing.managers.DictProxy
1064+
configuration : multiprocessing.managers.DictProxy
10621065
Global configuration of the microscope
10631066
is_synthetic : bool
10641067
Run synthetic version of hardware?

0 commit comments

Comments
 (0)