Skip to content

Connecting to KIM101 by Thorlabs in Python

Instrument Card

This four-channel controller features four SMC outputs to drive piezo inertia devices. The channels can be controlled independently or simultaneously in pairs using the dual-axis joystick on the controller’s top panel. The controller can be configured to operate up to four PD series piezo inertia stages, up to four PIA series piezo inertia actuators, or up to two PIM series piezo inertia optic mounts; one KIM101 can only concurrently drive devices that use the same “Select Stage” configuration in the controller’s menu options

KIM101

Device Specification: here

Manufacturer card: THORLABS

THORLABS

Thorlabs, Inc. is an American privately held optical equipment company headquartered in Newton, New Jersey. The company was founded in 1989 by Alex Cable, who serves as its current president and CEO. As of 2018, Thorlabs has annual sales of approximately $500 million.

  • Headquarters: USA
  • Yearly Revenue (millions, USD): 550
  • Vendor Website: here

Demo: Send commands to a Polulu stepper motor driver

Connect to the KIM101 in Python

PROTOCOLS > SCPI

To connect to a KIM101 Positional Controller using Instrumentkit, you can use the following code:

import instrumentkit as ik
# Connect to the KIM101 controller
controller = ik.thorlabs.APTPiezoInertiaActuator.open_serial("/dev/ttyUSB0", baud=115200)
# Get the first channel of the controller
channel = controller.channel[0]
# Enable the channel
channel.enabled_single = True
# Set the drive parameters for the channel
max_volts = ik.units.Quantity(110, ik.units.V)
step_rate = ik.units.Quantity(1000, 1/ik.units.s)
acceleration = ik.units.Quantity(10000, 1/ik.units.s**2)
channel.drive_op_parameters = [max_volts, step_rate, acceleration]
# Move the channel to a specific position
channel.move_abs(1000)

This code connects to the KIM101 controller using the open_serial method from the ik.thorlabs.APTPiezoInertiaActuator class. It then enables the first channel, sets the drive parameters, and moves the channel to a specific position using the enabled_single, drive_op_parameters, and move_abs properties and methods, respectively.