src.stages package

Submodules

src.stages.rotation_stage_cmd module

rotation_stage_cmd.py

Script containing all functions to initialize and operate the rotation stage SR2812 from Smaract

class src.stages.rotation_stage_cmd.SR2812_rotationstage(locator)

Bases: object

Class to operate the SR2812 rotation stage from Smaract.

ExitIfError(status)

MCS controller error message parser. Print an error message if applicable.

Parameters:

status – Status report of the stage.

Returns:

None

ManualMove()

Use the _GetchWindows class to manually operate the initialized stage from the command line.

__init__(locator)

Initialize and connect rotation stage, and print out some parameters for debugging

Parameters:

locator – Stage ID/address of the rotation stage, e.g. ‘usb:id:3948963354’

close()

Close the rotation stage.

getAngle()

Print current angle of rotation stage.

moveToAngle(angle)

Move rotation stage to a specific angle.

Parameters:

angle – Angle to move to.

src.stages.synthetic_rotation_stage module

Synthetic rotation_stage.py

Script containing all functions to initialize and operate a synthetic rotation stage

class src.stages.synthetic_rotation_stage.Synthetic_rotationstage(locator)

Bases: object

Class to make and operate a synthetic rotation stage.

__init__(locator)

Initialize a synthetic rotation stage.

Parameters:

locator – Stage ID/address of the synthetic rotation stage.

close()

Close synthetic rotation stage.

getAngle()

Print current angle of rotation stage.

moveToAngle(angle)

Move to specific angle with synthetic rotation stage.

Parameters:

angle – Angle to move to.

src.stages.synthetic_translation_stage module

synthetic_translation_stage.py

Script containing all functions to initialize and operate a synthetic translation stage

class src.stages.synthetic_translation_stage.Synthetic_translationstage

Bases: object

Class to operate a synthetic translation stage system with 3 axes (XYZ).

__init__()

Initialize the synthetic translation stage system (x,y,z positions) and stream events.

close()

Close synthetic translation stage.

findReference()

Reference synthetic translation stage and set values to zero.

moveToPosition(position_list)

Move synthetic translation stage to new position.

Parameters:

position_list – list of positions

streamStackAcquisition_externalTrigger_setup(no_of_frames, increment, slow_velocity, slow_acceleration)

Set up synthetic translation stage into a waiting mode where it can be triggered to move stage by increment upon receiving triggers. Total number of triggers expected is no_of_frames.

Parameters:
  • no_of_frames – How many external triggers are expected (number of images to acquire in stack acquisition).

  • increment – How big one step is.

  • slow_velocity – How fast the stage moves (slow_velocity * 10 mm/s).

  • slow_acceleration – How fast the stage is accelerated (slow_acceleration * 100 mm/s2).

streamStackAcquisition_externalTrigger_waitEnd()

Wait for stream to finish.

src.stages.translation_stage_cmd module

translation_stage_cmd.py

Script containing all functions to initialize and operate the translation stages from Smaract

class src.stages.translation_stage_cmd.SLC_translationstage(locator)

Bases: object

Class to operate the translation stage system with 3 axes (XYZ) from Smaract.

__init__(locator)

Initialize and connect translation stage from Smaract, and print out some parameters for debugging

Parameters:

locator – Stage ID/address of the rotation stage, e.g. ‘usb:sn:MCS2-00001723’

assert_lib_compatibility()

Checks that the major version numbers of the Python API and the loaded shared SmarAct library are the same to avoid errors due to incompatibilities. Raises a RuntimeError if the major version numbers are different.

close()

Close all translational stages from Smaract.

findReference()

Find the reference position for all three channels (stage axes). Move the up-down stage (channel 2) first to avoid collisions with the illumination and detection objectives. Set the positions to zero after referencing.

moveToPosition(position_list)

Move to a specific position (xyz) defined by the position_list.

Parameters:

position_list – np.array with 3 values for 3 channels/axes.

streamStackAcquisition_externalTrigger_setup(no_of_frames, increment, slow_velocity, slow_acceleration)

Set up a stack acquisition by preparing the stages to receive an external trigger signal that will move the stage by increment. no_of_frames trigger signals are expected. A waiting stream (thread) to receive voltage inputs is started.

Parameters:
  • no_of_frames – How many external triggers are expected (number of images to acquire in stack acquisition).

  • increment – How big one step is.

  • slow_velocity – How fast the stage moves (slow_velocity * 10 mm/s).

  • slow_acceleration – How fast the stage is accelerated (slow_acceleration * 100 mm/s2).

streamStackAcquisition_externalTrigger_waitEnd()

Wait for the stream started in streamStackAcquisition_externalTrigger_setup to end (i.e. when stack acquisition is complete).

Module contents