Module actuators: device adapters for motion devices

hal.Actuators device adapters shipped with MicroscoPy:

  • Newport ESP (based on the driver newportESP)
  • MCCDAQ USB2600 analog output (driver usb2600.usb2600)
  • Time: no motion, just a time sequence
  • Piezo: smooth voltage trajectory to drive a piezo with minimum ringing
  • Zaber ASR microscope stage (driver zaber)

class microscopy.device_adapters.actuators.ESP(axis, name='ESP', dir=1)[source]

Device adapter for Newport ESP newportESP.Axis objects.

approach(start, step)[source]

move 50um before the start position before scanning to avoid hysteresis.

class microscopy.device_adapters.actuators.Piezo(daq, output=2, name='PZ', wait=0.0, dt=0.05, rate=2000.0, tf=0.1)[source]

This voltage Actuator moves between points along a smooth sine trajectory to drive a piezo with minimum ringing.

When calling move_to() or move_by() with wait=False, the analog output scan will be delegated to a background thread.

Parameters:
  • daq – USB2600 instance (or anything with a compatible ScanAO method)
  • output – integer: the voltage output to use
  • name (string) – a short, meaningfull name for the axis
  • dt (float) – duration of the voltage ramp
  • rate (float) – sampling rate for the voltage ramp
  • tf – scaling factor for the USB refresh rate (see drivers.mccdaq.usb2600)
class microscopy.device_adapters.actuators.VoltOut(ao, name='V', wait=0.02)[source]

Analog output device adapter.

Parameters:
  • ao – the analog output (any callable object that, when called with a float as argument, set the voltage to that value; when called with no argument, return the current voltage).
  • name (str) – a short name
  • wait (float) – waiting time after setting the voltage
class microscopy.device_adapters.actuators.Time(dt)[source]

A special Actuator that performs a scan in time.

Note

The scan_range=(start, length, step) arguments of microscope.Scan1D are in units of dt. Set start=0 to start scan immediately upon calling run(), or to a positive number for a delayed start.

Parameters:dt – time between points, in seconds.
class microscopy.device_adapters.actuators.ZaberAxis(axis, name='zaber', use_mm=True)[source]

Device adapter for zaber.serial.AsciiAxis objects.

Parameters:
  • axis – a zaber.serial.AsciiAxis instance
  • name (string) – a meaningful name (eg. “X”)
  • use_mm (bool) – if True, considers that all inputs are in mm. if False, use microsteps units.
usteps(mm)[source]

Convert milimeters to microsteps.

mm(usteps)[source]

Convert usteps to milimeters.