xiufu
This commit is contained in:
@@ -75,7 +75,7 @@ class RealmanMotorsBus(MotorsBus):
|
||||
if mock:
|
||||
self.rmarm = RoboticArmMock()
|
||||
else:
|
||||
self.rmarm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
|
||||
self.rmarm = RoboticArm(rm_thread_mode_e.RM_DUAL_MODE_E)
|
||||
address = port.split(':')
|
||||
self.ip = address[0]
|
||||
self.port = int(address[1])
|
||||
@@ -103,6 +103,9 @@ class RealmanMotorsBus(MotorsBus):
|
||||
'''
|
||||
使能机械臂并检测使能状态,尝试5s,如果使能超时则退出程序
|
||||
'''
|
||||
|
||||
self.handle = self.rmarm.rm_create_robot_arm(self.ip, self.port)
|
||||
self.rmarm.rm_set_arm_run_mode(0)
|
||||
enable_flag = False
|
||||
loop_flag = False
|
||||
# 设置超时时间(秒)
|
||||
@@ -140,7 +143,6 @@ class RealmanMotorsBus(MotorsBus):
|
||||
break
|
||||
time.sleep(1)
|
||||
|
||||
self.handle = self.rmarm.rm_create_robot_arm(self.ip, self.port)
|
||||
self.rmarm.rm_movej(self.init_joint_position[:-1], 5, 0, 0, 1)
|
||||
time.sleep(3)
|
||||
ret = self.rmarm.rm_get_current_arm_state()
|
||||
|
||||
@@ -68,7 +68,7 @@ class RealmanRobot(Robot):
|
||||
"Mismatch between calibration values in the motor and the calibration file or no calibration file found"
|
||||
)
|
||||
self.calibrate()
|
||||
self.configure()
|
||||
# self.configure()
|
||||
logger.info(f"{self} connected.")
|
||||
|
||||
@property
|
||||
|
||||
Reference in New Issue
Block a user