Questions about costmap_2D
Hi, I've been reading up on the costmap_2D package and I just can't seem to wrap my head about it. Here are a couple questions that hopefully someone on here can help me understand.
1) What is the difference between the OccupancyGrid
published on /map
by the Gmapping package and the OccupancyGrid
published on /grid
by the costmap_2D package? My understanding is that costmap_2D provides a way to update a map at real-time, but when I run the gmapping_demo.launch
file in turtlebot_navigation, the map is also updated at real-time. So why is costmap_2D needed if the Gmapping package can build and update a map at real-time?
2) Where is the costmap_2D package actually run? The wiki makes me think that it is run in one of the navigation launch files, and that it is needed by the move_base node. However, when I run the amcl_demo.launch
file, I do not see costmap_2D in the results of rosnode list
. When I run rqt_graph
with the amcl demo running, the only topics I see relevant to costmaps are published by move_base
(they are /move_base/global_costmap/costmap
, /move_base/global_costmap/costmap_updates
, /move_base/local_costmap/costmap
, and /move_base/local_costmap/costmap_updates
), but they have no subscribers.
If anyone can help me understand, I would be very grateful.