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

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

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-01-22 00:21:43 -0500

ryleymcc gravatar image

I would like to know how to do this to pre-record a global path for my local_planner to follow.

edit flag offensive delete link more

Comments

Please delete your answer and post it as a comment.

skpro19 gravatar image skpro19  ( 2021-06-10 14:00:01 -0500 )edit

Question Tools

2 followers

Stats

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

Seen: 1,653 times

Last updated: Jan 22 '21