Wiring Instructions
- Use this wiring diagram
- Second NI X Series board required for SI 4 operation. Can use second PCIe-6321.
- Frame Clock Terminal connection is required
- Self Trig Source and Self Trig Destination Line connection is required
- Shutter, Pockels, and External Start Trig connections are optional
- Line Trig Terminal connection required only if using Pockels
Software Installation
- Create a ScanImage folder at desired path location (suggestions: C:\Program Files\ScanImage or C:\My Documents\Matlab\ScanImage). Location is hereafter referred to as <ScanImage>.
- Extract ZIP file into selected folder, adjusting name as desired to fully describe version. This creates a version folder <ScanImage>\<Version Name>
- Launch Matlab and select Set Path... from the File menu
- Press the button Add with Subfolders... and, when prompted, select the directory <ScanImage>\<Version Name>. This adds the ScanImage installation contents to the top of Matlab search path.
- Start ScanImage by typing scanimage4. You will be prompted to create or identify a Machine Data File. See next section for discussion.
Machine Data File Configuration
On first startup of ScanImage 4, you will be prompted to create or select a Machine Data File (MDF). Choose to create one, selecting desired folder location, e.g. 'C:\DATA\CONFIG\SCANIMAGE'.
This will open a Matlab M file in the Matlab editor containing several assignment statements. Each of the statements includes comments which describe what needs to be set.
File is divided into sections (Matlab 'cells') delimited by comment lines with 2 percent signs, e.g. '%%ScanImage'. Each of these is described in following sections.
After done editing file, save and then restart Matlab. The MDF is read only on Matlab startup. Any subsequent changes to the MDF require a Matlab restart.
%%ScanImage Section
Sections below **OPTIONAL*** pertain to optional hardware, e.g. motor, Pockels, shutter, piezo, etc.
Key things to set:
primaryDeviceID: Set to device name for ScanImage NI board, e.g. 'Dev2'
extFrameClockTerminal: Typically leave as default, 0, signifying PFI0
trigSelfTrigSourceLineID: Typically leave as default, 0, signifying P0.0
trigSelfTrigDestinationTerminal: Typically leave as default, 2, signifying PFI2
trigSelfTrigSourceDeviceID: Typically leave as default, '', signifying to use primaryDeviceID board
%%Thorlabs Devices Section
Select the API version being used – right now valid options are: '1.1' (for 32-bit/2 channel systems) and '1.2' (for 64-bit/4 channel systems)
Other Configuration
- ScanImage 4 expects the Thorlabs LSM and PMT configured XML files to be located in the same folder as the Machine Data File.
- After selecting the Machine Data File on startup, you will be prompted for a USR ('user') file. On first startup, hit Cancel.
- After starting ScanImage successfully, you should soon thereafter arrange windows as you prefer them and then save a USR file via the File >> Save User Settings As... menu item. On subsequent ScanImage startups, select this USR file. Several ScanImage settings, in addition to the window locations, are saved with the USR file. You can always save the USR file (File >> Save User Settings...) to update it for future ScanImage startup.