AlexShkarin / pyLabLib

Python package for device control and experiment automation
http://pylablib.readthedocs.io
GNU General Public License v3.0
142 stars 34 forks source link

Kinesis BBD302 x-stage moving but y-stage is not homing #80

Open nusratc2 opened 7 months ago

nusratc2 commented 7 months ago

from pylablib.devices import Thorlabs

Home channel 1

with Thorlabs.KinesisMotor("103387864", is_rack_system=True) as stage: print("Stage:", stage.get_stage()) stage.set_supported_channels(channels=1) # Focus on channel 1 if not stage.is_homed(1): print("Homing Channel 1...") stage.home(sync=True, channel=1) stage.wait_for_home(channel=1, timeout=120) print("Channel 1 homed.")

Home channel 2

with Thorlabs.KinesisMotor("103387864", is_rack_system=True) as stage: stage.set_supported_channels(channels=2) # Focus on channel 2 if not stage.is_homed(2): print("Homing Channel 2...") stage.home(sync=True, channel=2) stage.wait_for_home(channel=2, timeout=120) print("Channel 2 homed.")

Stage: step Channel 1 Numeric Status: 2415993088 Channel 1 Verbose Status: ['connected', 'settled', 'interlock', 'power_ok', 'enabled'] Homing Channel 1... Channel 1 homed. Channel 2 Numeric Status: 2417041664 Channel 2 Verbose Status: ['connected', 'settled', 'interlock', 'digio1', 'power_ok', 'enabled'] Homing Channel 2... The channel 2 shows digio1, and it doesn;t move/ home. Can you please help me, as everytime I need to disconnect the device from pc and restart it to use it again. Because it is getting stuck at homing channel 2 everytime. The channel 1 is working fine, I don't know that is wrong with the channel 2