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

How do I get the position of the Turtlebot at current time and check if that pose is exactly same to the pose in the plan provided by the planner?

asked 2016-08-18 05:02:22 -0500

Karthikeyan gravatar image

I'm using the navigation stack to generate a global plan. Once the plan is generated, I can see the Turtlebot navigating in Gazebo. I need to know how to check the Turtlebot's current position in the map and if it is following the same plan generated by the planner. How can I do this by code.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2016-08-19 11:00:36 -0500

Shay gravatar image

Generally, the navigation stack get the robot position from odometry, which comes from your robot encoders. In the simulation environments(e.g. Gazebo), the odometry is always right, and your robot position is always right, so your robot is always following the plan.

But in the real world, the odometry is only right for a short time, and then both the position and orientation will drift. So the real robot will not follow the plan generated by the planner. To know if your robot is following the plan, you need additional position methods, such as GPS and amcl, which can tell you the robot's position relative to the 'world'. With these info, you can know if the robot is following the plan.

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2016-08-18 05:02:22 -0500

Seen: 1,213 times

Last updated: Aug 19 '16