Thorlabs/Motion_Control_Examples

Cannot create KCubeObject

Closed this issue · 1 comments

Anytime I try to create a KCube object I get that the object refrence does not exist. This occurs even when running the example "Python/KCube/KIM101/kim101_pythonnet.py"

The line that is failing

"device = KCubeInertialMotor.CreateKCubeInertialMotor(serial_no)"

Object reference not set to an instance of an object.
at Thorlabs.MotionControl.PrivateInternal.Settings.DeviceConfigurationBase.VerifyDeviceSettingsName(Boolean replace)
at Thorlabs.MotionControl.PrivateInternal.Settings.DeviceConfigurationBase.ReadConfiguration(DeviceConfigurationNode node, GeneralSettings generalSettings)
at Thorlabs.MotionControl.PrivateInternal.Settings.DeviceConfigurationBase.LoadConfiguration(String serialNo, GeneralSettings generalSettings)
at Thorlabs.MotionControl.KCube.InertialMotorCLI.KCubeInertialMotor.InitializeDevice(String serialNumber)
at Thorlabs.MotionControl.KCube.InertialMotorCLI.KCubeInertialMotor._CreateKCubeInertialMotor(String serialNumber)
at Thorlabs.MotionControl.KCube.InertialMotorCLI.KCubeInertialMotor.CreateKCubeInertialMotor(String serialNumber)

Bad connection between controller and computer. Switched to cable delivered with device and the code ran just fine.