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

what difference does it make in NavStack(move_base) with frame_id as map vs odom

asked 2021-01-11 22:20:22 -0500

darshb34 gravatar image

updated 2021-01-11 22:21:37 -0500

We set global_frame for different nodes of the NavStack. Below are the ones I am eager to know about and how they affect the system.

Costmap params:

/global_costmap/global_frame: map vs odom
/local_costmap/local_frame: map vs odom

planner params:

/DWAPlannerROS/global_frame_id: map vs odom
/GlobalPlanner/global_frame_id: map vs odom
edit retag flag offensive close merge delete

Comments

1

If you are using an external map to naviagte, then it makes sense to set the global_frame paramter in the costmap configuration file to map.

skpro19 gravatar image skpro19  ( 2021-01-14 15:03:31 -0500 )edit

Thanks for response @skpro19 . I load the map obtained from gmapping using map_server package.

  1. what do you mean by external map? Do you mean using a map different from the map being used by SLAM map?
  2. Is it fine to use map as global_frame in the costmap configuration even if I am using ONE single map for amcl in my NavStack?
darshb34 gravatar image darshb34  ( 2021-01-14 15:47:31 -0500 )edit
1

By external_map, I mean any map that is being published on the /map topic.

Whenever you are running a program (i.e. node) that publishes on the /map topic, and you want to use that /map topic to build your global_costmap, you would need to set the global_frame parameter to /map.

Sometimes, it could also happen that you don't really care about the map, and just want to operate the bot in the odom frame. In such cases, you would need to set the global_frame (for your global_costmap) to /odom. You would also need to manually set the width and height for the global_costmap.

Does that make sense?

You could also try to visualize the global_costmap on Rviz for more clarity.

skpro19 gravatar image skpro19  ( 2021-01-14 16:11:44 -0500 )edit

Hi @skpro19,

It totally makes sense now and even answers my question. So basically if we do not have a external grid_map we use odom frame.

One of the use case example of this would be when we totally rely on GPS for localization and few range sensors for obstacle avoidance via local_costmap and global_costmap.

Thank you so much for the help.

darshb34 gravatar image darshb34  ( 2021-01-14 16:23:09 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-02-23 15:45:45 -0500

darshb34 gravatar image

refer to the comments for answe.

edit flag offensive delete link more

Question Tools

3 followers

Stats

Asked: 2021-01-11 22:20:22 -0500

Seen: 168 times

Last updated: Feb 23 '21