Rosanswers logo


i would like to move the robot "Franka Emika Panda" with the cartesian movement in C++. I make the configuration which is recommended on the homepage. My current result is to move the robot with joint movement with moveit. Then I trying the cartesian movement with the following link:


In this section they show how it works with the simulation, but i would like to try this one on the real robot. I hope i can get some tips to solve my problem.

EDIT: I add the source code and the launch-file which i use.


//Cartesian Path
geometry_msgs::Pose target_pose3 = move_group.getCurrentPose().pose;

std::cout<< "Anfangsposition" << std::endl;
std::cout<< target_pose3 << std::endl;

std::vector<geometry_msgs::Pose> waypoints;

target_pose3.position.z -= 0.2;
waypoints.push_back(target_pose3); //down

target_pose3.position.y -= 0.2;
waypoints.push_back(target_pose3); //right

target_pose3.position.z += 0.2;
target_pose3.position.y += 0.2;
target_pose3.position.x -= 0.2;

// Skalierungsfaktor der maximalen Geschwindigkeit jedes Gelenks

moveit_msgs::RobotTrajectory trajectory;
const double jump_threshold = 0.5;
const double eef_step = 0.01;
move_group.computeCartesianPath(waypoints, eef_step, jump_threshold, trajectory);

moveit::planning_interface::MoveGroupInterface::Plan goal_plan;
goal_plan.trajectory_ = trajectory;


<?xml version="1.0" ?>
    <arg name="robot_ip" />

    <include file="$(find franka_control)/launch/franka_control.launch">
        <arg name="robot_ip" value="" />
        <arg name="load_gripper" value="false" />
    <include file="$(find panda_moveit_config)/launch/panda_moveit.launch">
         <arg name="load_gripper" value="false" />

When i start my source code then i get some information back from the console

 INFO] [1551336690.500652276]: Received request to compute Cartesian path
[ INFO] [1551336690.501040209]: Attempting to follow 4 waypoints for link 'panda_link8' using a step of 0.010000 m and jump threshold 0.500000 (in global reference frame)
[ INFO] [1551336690.507374299]: Computed Cartesian path with 2 points (followed 2.597403% of requested trajectory)
[ INFO] [1551336690.508019615]: Execution request received
[ WARN] [1551336690.534495590]: Dropping first 1 trajectory point(s) out of 2, as they occur before the current time.
First valid point will be reached in 0.013s.
[ INFO] [1551336690.667268099]: Completed trajectory execution with status SUCCEEDED ...
[ INFO] [1551336690.667388163]: Execution completed: SUCCEEDED

Regards, Markus

Originally posted by MarkusHHN on ROS Answers with karma: 54 on 2019-02-27

Post score: 0

Original comments

Comment by mlautman on 2019-03-05:
You should always visually inspect the generated plan before executing on hardware. The computeCartesianPath functionality has a known issue that could result in joint flips.

Comment by MarkusHHN on 2019-03-06:
thank you for the information. It is possible to solve or improve this problem?


1 Answer 1


Rosanswers logo

If I understand your question correctly, you probably just need to create/update a plan using the trajectory which is I/O in computeCartesianPath, and then call MoveGroup::execute with said path.

Assuming the tutorial's notation, this should work:

my_plan.trajectory_ = trajectory;

Originally posted by aPonza with karma: 589 on 2019-02-27

This answer was ACCEPTED on the original site

Post score: 1

Original comments

Comment by MarkusHHN on 2019-02-28:
Thank you for your answer, but the robot dont moving to this position. I will add some source code and information


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.