The th_apt module

Module for Thorlabs APT motion controllers.

API

cmd_th_apt.init_th_apt(th_apt_id, conf_string)[source]

Initialize TH_APT motion controller chanel.

conf_string must contain the parameters:

  • bus: a conf_string for cmd_serial or cmd_tcp
  • chan: channel where the motor to control is attached
cmd_th_apt.deinit_th_apt(th_apt_id)[source]

Deinitialize th_apt_id motion controller channel.

cmd_th_apt.config_th_apt(th_apt_id, pos_max, pos_min)[source]

Configure th_apt_id motion controller channel.

cmd_th_apt.inval_th_apt(th_apt_id)[source]

Invalidate th_apt_id motion controller channel.

cmd_th_apt.home_th_apt(th_apt_id, direction='r', velocity='1')[source]

Home th_apt_id channel by moving the motor to its home position. Do it in the reverse (r) or forward (r) direction with velocity.

cmd_th_apt.is_homed_th_apt(th_apt_id)[source]

Check if channel been homed.

cmd_th_apt.move_th_apt(th_apt_id, displacement, velocity, acceleration)[source]

Move channel by displacement mm with the specified velocity. A ramp up from zero with acceleration is used to get to velocity. Units are mm, mm/s and mm/s**2.

cmd_th_apt.get_pos_th_apt(th_apt_id)[source]

Get position of channel. Result is returned in mm.

cmd_th_apt.go_min_th_apt(th_apt_id, velocity, acceleration)[source]

Go to the minimum position defined during the configuration of the channel

cmd_th_apt.go_max_th_apt(th_apt_id, velocity, acceleration)[source]

Go to the maximum position defined during the configuration of the channel