Problem with publishing a global path on topic /move_base/TrajectoryPlannerROS/global_plan

asked 2014-01-24 07:04:40 -0500

Anis gravatar image

updated 2014-01-24 20:27:59 -0500

Hi

I made a small program that publishes a plan on the topic
/move_base/TrajectoryPlannerROS/global_plan

Here goes the idea

for (int i=0; i<10; i++){
geometry_msgs::PoseStamped new_goal ;
tf::Quaternion goal_quat = tf::createQuaternionFromYaw(1.54);

new_goal.header.frame_id="/map";

 new_goal.pose.position.x = GPAS.InitialPoseMessage.pose.pose.position.x+(0.1*i);
 new_goal.pose.position.y = GPAS.InitialPoseMessage.pose.pose.position.x+(0.1*i);

 new_goal.pose.orientation.x = 0;
 new_goal.pose.orientation.y = 0;
 new_goal.pose.orientation.z = 0;
 new_goal.pose.orientation.w = 1;

 plan.poses.push_back(new_goal);
 }

 plan.header.frame_id="/map";

 GPAS.GlobalPlanPublisher.publish(plan); // topic /move_base/TrajectoryPlannerROS/global_plan
 GPAS.NavfnROSPublisher.publish(plan);

When I do rostopic echo /move_base/TrajectoryPlannerROS/global_plan

I can see well the published plan correctly. However, the turtlebot robot does not move and does not follow the plan, although the plan is correctly shown in rviz. I already run amcl and move base launch files and the robot moves if I send a goal from rviz.

i wanted to test of the robot moves if I send a plan instead of a goal.

Do you have an idea what could be the issue? Is it sufficient to make the robot moving by sending a plan in topic /move_base/TrajectoryPlannerROS/global_plan or some configuration need to be made?

Thank you
Anis

edit retag flag offensive close merge delete