In this tutorial, you will learn how to autonomously navigate a mobile robot in ROS1 using the `move_base` package for path planning and `amcl` for probabilistic localization on a prebuilt map. We will use a simulated robot (e.g., TurtleBot3) with a map previously generated using SLAM.
📝 Required components
ROS1 installed (e.g., Noetic on Ubuntu 20.04)
Packages: `amcl`, `move_base`, `map_server`
A static map (`.yaml` + `.pgm`) previously built using SLAM
Gazebo simulation or real robot in a controlled environment
Step 1: Launch the Navigation Stack
Launch the full navigation system with the saved map:
In RViz, click the “2D Pose Estimate” button and select the robot’s initial position and orientation on the map. This will help AMCL converge with an accurateinitial pose estimate.
Step 3: Send a Navigation Goal
Click the “2D Nav Goal” button in RViz, select a destination and final orientation. `move_base` will compute a global path and command the robot to reach the goal while avoiding obstacles.
🛠️Step 3: Troubleshooting
The robot does not move:
Check if the `move_base` node is running and all topics are correct.
Path not found:
Make sure the goal is reachable and not behind obstacles on the map.
AMCL does not converge:
Try slightly moving the robot or re-initialize pose using 2D Pose Estimate.
Want to learn more?
You can find a detailed explaination of the autonomous navigation in the "Self Driving and ROS - Learn by Doing! Odometry & Control" course