Note: This tutorial assumes that you have completed the previous tutorials: cob_tutorials/Tutorials/Startup simulation.
(!) Please ask about problems and questions regarding this tutorial on answers.ros.org. Don't forget to include in your question the link to this page, the versions of your OS & ROS, and also add appropriate tags.

Using slam navigation (navigation with a online generated map)

Description: This tutorial shows you how to move the mobile base avoiding collisions and building up a map while moving the robot.

Tutorial Level: BEGINNER

Next Tutorial: cob_tutorials/Tutorials/Navigation (global)

Prerequisit

Startup simulation with robot.

SLAM navigation

Start cob_navigation_slam navigation

roslaunch cob_navigation_slam 2dnav_ros_dwa.launch robot:=cob4-<your robot>

Start rviz visualisation

roslaunch cob_navigation_slam rviz.launch

cob_tutorials/Tutorials/RvizSlam1.png

  • Either use a keyboard interface to move the robot and watch the map beeing build up as you explore the environment.

roslaunch cob_teleop teleop_keyboard.launch
  • Or use the "2D Nav Goal" button in rviz to specify a navigation goal and watch the robot moving and the map building up. (You will notice that you can only specify target poses which are in the range of the local costmap or in the previous explored map)

cob_tutorials/Tutorials/RvizSlam2.png

Save map

As soon as you have a map build up from the environment, you can save it with

rosrun map_server map_saver

This will save a bitmap file map.pgm and a file with meta data about the map map.yaml to your current directory. We will need this map in the next tutorial.

Wiki: cob_tutorials/Tutorials/Navigation (slam) (last edited 2019-09-24 10:06:12 by HannesBachter)