ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

use moveit! computeCartesianPath to plan a circular path

asked 2020-10-22 02:11:16 -0500

xibeisiber gravatar image

updated 2020-10-22 21:26:56 -0500

Hi all,

Currently I need to plan a circular path for the robot arm so that it can turn a door handle.

I learned that we can use many points as waypoints to approximate the arc and use computeCartesianPath function to achieve that.

But if I changed the orientation of these waypoints along the arc, the fraction of computeCartesianPath is rather low. On the contrary, if I keep the orientation of these waypoints the same as the initial state, the fraction is relatively higher.

Does computeCartesianPath support the change of orientation?

a simple graphic of the scene: let the robot hand (black block) turn the door handle (dash line). The robot hand (eef joint) is free to rotate along its z axis (perpendicular to the plane). For each waypoint that has an ik solution in the left figure, the right one should also have an ik solution by adjusting this eef joint. image description

Thanks for any help!

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
2

answered 2020-10-22 21:43:50 -0500

xibeisiber gravatar image

updated 2020-10-22 21:44:13 -0500

found the problem...the failure has nothing to do with the computeCartesianPath. it is because the eef joint values of the initial state is about 3.14, when the eef moves down, the joint value becomes -3.14, leading to a large jump... I adjust the joint limit to [-6.28, 6.28], it can plan and execute arc path now..

edit flag offensive delete link more
0

answered 2020-10-22 05:43:50 -0500

aseligmann gravatar image

computeCartesianPath should support planning for changes in orientation, but the default KDL planner usually does not perform very well when using computeCartesianPath, due to the way it is implemented.

I would suggest you try out the TRAC-IK planner, which is a more or less drop-in replacement.

The official tutorial can be found here: http://docs.ros.org/en/melodic/api/mo...

edit flag offensive delete link more

Comments

thanks for your reply. I already use a robust ik solver for that. I have a thought that if I take enough waypoints on the arc path, and solve the ik for each waypoints, thus get a trajectory of joint values. Then use iterative_time_parameterization to add the timestamps. Not sure if this works, will try tomorrow.

xibeisiber gravatar image xibeisiber  ( 2020-10-22 08:53:17 -0500 )edit
1

FWIW, what you described above is basically exactly what computeCartesianPath does (see source here). With one minor addition -- there are several heuristics to determine if you've accidently found IK solutions at neighboring waypoints that have large "joint jumps" that might not be feasible in real life. You could experiment with the values used for joint jump testing. Also note, it's quite possible that even with "robust IK" there doesn't exist a solution that follows your desired arc while also changing orientation (however you've defined that), or perhaps the only solutions that do exist require large joint jumps. An obvious cause that could produce this scenario is joint limits.

jarvisschultz gravatar image jarvisschultz  ( 2020-10-22 10:36:07 -0500 )edit

thanks very much. Indeed, I tested the way mentioned, the main problem is the jumps. But I'm still a bit curious: since the last joint is free to rotate along the axis (updated in the figure), it should have an ik solution without jump on the waypoints where computeCartesianPath succeeded when I keep the orientation same with the initial one.

xibeisiber gravatar image xibeisiber  ( 2020-10-22 20:52:44 -0500 )edit

solved... the problem is that the eef joint needs to move from pi to -pi, leading to a large jump. sorry for my mistake..

xibeisiber gravatar image xibeisiber  ( 2020-10-22 22:12:04 -0500 )edit

I converted your comment to an answer and marked it as correct. That way this question shows up as properly answered. Glad you were able to figure things out!

jarvisschultz gravatar image jarvisschultz  ( 2020-10-23 14:24:38 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2020-10-22 02:11:16 -0500

Seen: 1,006 times

Last updated: Oct 22 '20