xArm 5 move_line_tool not working

Hi all,

I am having some trouble controlling the xArm 5 in ROS using the robot mode 0.
Moving in joint space is no problem at all. But moving relative to the tool in Cartesian space, using the service /xarm/move_line_tool, returns ret: 9 and C21.
Which is a Kinematic Error in the xArm Controller saying: “Please long press the “align the hand” or long press the “zero position” button to level the end flange of the robot before moving”

Is there a way to correctly align the hand using a ROS command?

Thanks in advance!

Dear friend,

Sorry, currently there is no such API.
To level the end flange of the robot, you can get the joint angle via get_servo_angle, and then set joint4 according to the below formula.

joint4 = -( joint2+joint3) unit:degree

Best regards,

1 Like

Hello Minna, Can you please explain how we can solve the same C21 problem with Blockly? I also get the "Please long press the “align tha hand” or long press “zero position” comment. It would be great if you could show me an example as to how the Blockly program should begin so this does not happen. Thanks

Hi Felipe,

There is a structural limitation of xArm5. Do you use cartesian motion? If so, you should make sure the end flange surface and the base are completely parallel, please help to confirm.

Best regards,

Hello Minna, yes we are using Cartesian motion and the base and flange are completely parallel. Can you send an example of how our Blockly program should begins so we do not have the C21 error. Thanks for the quick reply.

Hi Sir,

You would be better to keep roll, pitch,yaw = [180,0,0 ].


Best regards,