pcdshub / lcls-twincat-motion

TwinCAT 3 Motion Control Utilities - PLC Motion Library for all PCDS Applications
https://pcdshub.github.io/lcls-twincat-motion
Other
35 stars 20 forks source link

Move status readback show true when no move has happened. #50

Open slacAdpai opened 4 years ago

slacAdpai commented 4 years ago
In [37]: kmono_instance.xtal_vert.move(0)
Out[37]: MoveStatus(done=True, pos=kmono_instance_xtal_vert, elapsed=8.7, success=True, settle_time=0.0)

In [38]: kmono_instance.xtal_vert.get()
Out[38]: BeckhoffAxisTuple(user_readback=0.0, user_setpoint=0.0, user_offset=0.0, user_offset_dir=0, offset_freeze_switch=0, set_use_switch=0, velocity=5.0, acceleration=0.0033333333333333335, motor_egu='mm', motor_is_moving=0, motor_done_move=1, high_limit_switch=1, low_limit_switch=0, direction_of_travel=0, motor_stop=0, home_forward=0, home_reverse=0, low_soft_limit=0.0, high_soft_limit=0.0, disabled=0, description='Main.M50 / XTAL VERT Y', plc=BeckhoffAxisPLCTuple(status='', err_code=0, cmd_err_reset=0))

In [39]: kmono_instance.xtal_vert.move(100)
Out[39]: MoveStatus(done=True, pos=kmono_instance_xtal_vert, elapsed=4.3, success=True, settle_time=0.0)

In [40]: kmono_instance.xtal_vert.get()
Out[40]: BeckhoffAxisTuple(user_readback=0.0, user_setpoint=0.0, user_offset=0.0, user_offset_dir=0, offset_freeze_switch=0, set_use_switch=0, velocity=5.0, acceleration=0.0033333333333333335, motor_egu='mm', motor_is_moving=0, motor_done_move=1, high_limit_switch=1, low_limit_switch=0, direction_of_travel=0, motor_stop=0, home_forward=0, home_reverse=0, low_soft_limit=0.0, high_soft_limit=0.0, disabled=0, description='Main.M50 / XTAL VERT Y', plc=BeckhoffAxisPLCTuple(status='Contact PCDS to add new message', err_code=16931, cmd_err_reset=0))

In [41]: kmono_instance.xtal_vert.move(10)
Out[41]: MoveStatus(done=True, pos=kmono_instance_xtal_vert, elapsed=4.3, success=True, settle_time=0.0)

In [42]: kmono_instance.xtal_vert.get()
Out[42]: BeckhoffAxisTuple(user_readback=0.0, user_setpoint=0.0, user_offset=0.0, user_offset_dir=0, offset_freeze_switch=0, set_use_switch=0, velocity=5.0, acceleration=0.0033333333333333335, motor_egu='mm', motor_is_moving=0, motor_done_move=1, high_limit_switch=1, low_limit_switch=0, direction_of_travel=0, motor_stop=0, home_forward=0, home_reverse=0, low_soft_limit=0.0, high_soft_limit=0.0, disabled=0, description='Main.M50 / XTAL VERT Y', plc=BeckhoffAxisPLCTuple(status='Contact PCDS to add new message', err_code=16931, cmd_err_reset=0))
ZLLentz commented 4 years ago

It looks like moves are being marked as success despite the error state preventing the move