How to execute the Cartesian Paths? Help!

1,532 views
Skip to first unread message

苏兴

unread,
Mar 25, 2015, 4:24:13 AM3/25/15
to moveit...@googlegroups.com
Hi all,

I'm trying to  control my robot with moveit by following this tutorial: Move Group Interface/C++ API.

At first, when I tried to Plan to a Pose goal and then execute it by uncomment below line, and real robot moves.
/* Uncomment below line when working with a real robot*/
/* group.move() */

Then I tried to execute Cartesian Paths, but this time,  the real robot run in a wrong path (very short). But before executing the group.move() ,   
the "ROS_INFO("Visualizing plan 4 (cartesian path) (%.2f%% acheived)",fraction * 100.0);" show the fraction is 100.0%, 
and rviz visualize the plan correctly.

I don't know why~

Help!

Yoan Mollard

unread,
Mar 25, 2015, 10:30:34 AM3/25/15
to 苏兴, moveit...@googlegroups.com
Hi,


I find three tracks to investigate:

It could be that your robot controller stopped the trajectory (it tries to complete the motion during a short time until the trajectory gets out of reachability or so). What's your robot? Do you know what is your controller? Do you have feedback from it? Velocities and/or efforts could be too high for it, in particular if you see jumps in IK between two points. A proper jump_threshold value should avoid that (but may imply a lower % of success).

Since the beginning of the trajectory is wrong it would suggest that you are not using the good reference frame, but since visualization in RViz is ok I would not favour this track. However it's easy to check with a setPoseReferenceFrame()

Also I'm not sure what move() and execute() do exactly, but according to the doc, move() = plan() + execute(), so I would execute() the cartesian trajectory in your case, instead of move(), since that method could replan to a goal formerly defined.

Cheers,

Yoan Mollard
Research engineer – 3rd hand project

INRIA Research center, Flowers lab


苏兴

unread,
Mar 26, 2015, 4:43:41 AM3/26/15
to moveit...@googlegroups.com, suxi...@gmail.com, yoan.m...@inria.fr
Hi Yoan,
 how to execute the  cartesian paths, there is no "plan" type data (moveit::planning_interface::MoveGroup::Plan).

how to convert trajectory to plan, or how to exectue trajectory directly

    moveit_msgs::RobotTrajectory trajectory;
    double fraction = group->computeCartesianPath(waypoints,
                                                 0.01,  // eef_step
                                                 0.0,   // jump_threshold
                                                 trajectory);


Thx!



在 2015年3月25日星期三 UTC+8下午10:30:34,Yoan Mollard写道:

Yoan Mollard

unread,
Mar 26, 2015, 6:52:10 AM3/26/15
to 苏兴, moveit...@googlegroups.com
Hi again,


This is true. A plan contains a field "trajectory", so you can construct it by hand, something like:

Plan plan;
plan.trajectory_ = trajectory;
group->execute(plan);

Not sure if the plan.start_state_ is compulsory, you'll see by executing.
Reply all
Reply to author
Forward
0 new messages