Skip to content

Latest commit

 

History

History
179 lines (121 loc) · 6.1 KB

imcontrol-setups.rst

File metadata and controls

179 lines (121 loc) · 6.1 KB

Hardware control configurations

ImSwitch's hardware control module is designed to be flexible and be usable in a wide variety of microscopy setups. In order to provide this flexibility, hardware configurations are defined in .json files that are loaded when the hardware control module starts.

Hardware configuration files are loaded from the imcontrol_setups directory, which is automatically created inside your user directory for ImSwitch the first time the hardware control module starts. It contains some pre-made configuration files by default. The user directory is located at %USERPROFILE%\Documents\ImSwitch on Windows and ~/ImSwitch on macOS/Linux.

The first time you start the hardware control module, you will be prompted to select a setup file to load. If you want to switch to another hardware configuration later, select "Tools" -> "Pick hardware setup…" in the hardware control module's menu bar.

How configurations are defined

Hardware configurations are defined in JSON format. Behind the scenes, they are automatically translated to Python class instances when loaded into the software.

A central concept in ImSwitch is that of device managers. Device managers define what kind of device you have, and how ImSwitch communicates with it. For example, if you have a Hamamatsu camera that you would like to control, you would define a detector that uses the HamamatsuManager in the hardware setup file and set its appropriate properties. The list of available managers and their properties can be found here <Available managers>. Each device must have a unique name, which is represented by its object key in the JSON.

Signal designers, which are relevant for users who use the scan functionality, are similar. Microscopy scans can be set up in different ways; in a point-scanning setup, for instance, you might want to set your scan settings to use the PointScanTTLCycleDesigner to generate the appropriate TTL signals. They are documented here <Available signal designers>.

As a very simple example, a hardware configuration file that allows you to control a single Cobolt 06-01 (non-DPL) laser connected to COM port 11 can look like this:

{
    "lasers": {
        "Cobolt405nm": {
            "managerName": "Cobolt0601LaserManager",
            "managerProperties": {
                "digitalPorts": ["COM11"]
            },
            "valueRangeMin": 0,
            "valueRangeMax": 200,
            "wavelength": 405
        }
    },
    "availableWidgets": [
        "Laser"
    ]
}

Note that the digitalPorts property is specific to Cobolt0601LaserManager.

Configuration file specification

imswitch.imcontrol.view.guitools.ViewSetupInfo.ViewSetupInfo

Item types that may be included

imswitch.imcontrol.model.SetupInfo.DetectorInfo

imswitch.imcontrol.model.SetupInfo.LaserInfo

imswitch.imcontrol.model.SetupInfo.PositionerInfo

imswitch.imcontrol.model.SetupInfo.RS232Info

imswitch.imcontrol.model.SetupInfo.SLMInfo

imswitch.imcontrol.model.SetupInfo.FocusLockInfo

imswitch.imcontrol.model.SetupInfo.ScanInfo

imswitch.imcontrol.model.SetupInfo.NidaqInfo

imswitch.imcontrol.view.guitools.ViewSetupInfo.ROIInfo

imswitch.imcontrol.view.guitools.ViewSetupInfo.LaserPresetInfo

imswitch.imcontrol.model.SetupInfo.EtSTEDInfo

Available managers

Detector managers

imswitch.imcontrol.model.managers.detectors.APDManager.APDManager

imswitch.imcontrol.model.managers.detectors.HamamatsuManager.HamamatsuManager

imswitch.imcontrol.model.managers.detectors.PhotometricsManager.PhotometricsManager

imswitch.imcontrol.model.managers.detectors.TISManager.TISManager

Laser managers

imswitch.imcontrol.model.managers.lasers.AAAOTFLaserManager.AAAOTFLaserManager

imswitch.imcontrol.model.managers.lasers.Cobolt0601LaserManager.Cobolt0601LaserManager

imswitch.imcontrol.model.managers.lasers.CoolLEDLaserManager.CoolLEDLaserManager

imswitch.imcontrol.model.managers.lasers.NidaqLaserManager.NidaqLaserManager

Positioner managers

imswitch.imcontrol.model.managers.positioners.MHXYStageManager.MHXYStageManager

imswitch.imcontrol.model.managers.positioners.NidaqPositionerManager.NidaqPositionerManager

imswitch.imcontrol.model.managers.positioners.PiezoconceptZManager.PiezoconceptZManager

RS232 managers

imswitch.imcontrol.model.managers.rs232.RS232Manager.RS232Manager

Available signal designers

Scan designers

imswitch.imcontrol.model.signaldesigners.BetaScanDesigner.BetaScanDesigner

imswitch.imcontrol.model.signaldesigners.GalvoScanDesigner.GalvoScanDesigner

TTL cycle designers

imswitch.imcontrol.model.signaldesigners.BetaTTLCycleDesigner.BetaTTLCycleDesigner

imswitch.imcontrol.model.signaldesigners.PointScanTTLCycleDesigner.PointScanTTLCycleDesigner