When I try to run the PR2 navigation stack it in Gazebo the local cost map doesn’t update. All the values in /move_base_node/local_costmap/cost_map remain zero. As a result, the PR2 will collide with objects that are not part of the map. There are no warnings or error messages. Also, the global planner seems to work fine.
Here is what I did to test the nav stack:
sudo apt-get install ros-indigo-pr2-navigation*
I created a clean catkin workspace and downloaded the navigation packages from the hydro-devel branch:
These compiled fine. I launched a Gazebo world with the PR2. First I built a map:
roslaunch pr2_2dnav_slam pr2_2dnav.launch
roslaunch pr2_navigation_slam rviz_move_base_slam.launch
rosrun map_server map_saver -f map_name
and then tried to navigate the map:
roslaunch pr2_2dnav pr2_2dnav.launch
roslaunch pr2_navigation_global rviz_move_base.launch
rosrun map_server map_server map_name.yaml
1. add package information to .rosinstall
$ cd /path/to/your/catkin_ws
$ wstool set pr2_navigation --git https://github.com/pr2/pr2_navigation -v 0.1.27 -t src
$ wstool up pr2_navigation -t src
2. build packages
$ catkin build pr2_2dnav # or catkin_make
3. launch again
$ source devel/setup.bash
$ roslaunch pr2_2dnav pr2_2dnav.launch