A complete autonomous navigation system built using ROS 2 Jazzy, Nav2, SLAM Toolbox, Gazebo, and Behavior Trees.
This project demonstrates:
- Robot modeling and visualization
- Gazebo simulation
- 2D SLAM mapping
- Autonomous navigation with Nav2
- Goal-based navigation
- Custom Nav2 applications
- Behavior Tree based task execution
- Groot2 integration for BT visualization
sudo apt install ros-jazzy-navigation2 ros-jazzy-nav2-bringup ros-jazzy-slam-toolbox| Package | Description |
|---|---|
rosbot_description |
ROSbot URDF, RViz visualization, and Gazebo simulation |
rosbot_nav2_bringup |
Nav2 and SLAM Toolbox configuration |
nav2_client |
Custom C++ Nav2 action client |
nav2_bt_client |
Behavior Tree based navigation application |
source /opt/ros/jazzy/setup.bash
colcon build --symlink-install
source install/setup.bashLaunch the ROSbot model in RViz.
source install/setup.bash
ros2 launch rosbot_description display.launch.pyLaunch the robot inside the Gazebo simulation environment.
source install/setup.bash
ros2 launch rosbot_description gazebo.launch.py- Simulation world loads
- ROSbot spawns in Gazebo
- Sensors and robot controllers become active
Generate a 2D occupancy grid map using SLAM Toolbox.
ros2 launch rosbot_description gazebo.launch.pyros2 launch rosbot_nav2_bringup slam_online_async.launch.pyDrive the robot around the environment to build the map.
ros2 run nav2_map_server map_saver_cli -f ~/mapPerform autonomous navigation using Nav2.
ros2 launch rosbot_description gazebo.launch.pyros2 launch rosbot_nav2_bringup nav2.launch.py- Set the robot's initial pose using 2D Pose Estimate
- Select Nav2 Goal
- Send a navigation target
Run a custom C++ Nav2 action client.
ros2 launch rosbot_description gazebo.launch.pyros2 launch rosbot_nav2_bringup nav2.launch.pyros2 run nav2_client navigation_clientThe application communicates with Nav2 using the NavigateToPose action interface.
The robot must autonomously visit multiple locations inside a hospital environment.
- Start position
- Navigate to Medicine Shop
- Collect medicine
- Navigate to Room 1
- Deliver medicine
- Return to initial position
Execute navigation tasks using a Behavior Tree based workflow.
ros2 launch rosbot_description gazebo.launch.pyros2 launch rosbot_nav2_bringup nav2.launch.pySet the robot's initial pose using 2D Pose Estimate.
ros2 launch nav2_bt_client start_bt_app.launch.pyThis launches:
- Nav2 BT Action Client
- Groot2
- Behavior Tree execution engine
- Real-time navigation monitoring
- Robot navigation inside the environment
bt_navigation.mp4
- ROS 2 Jazzy
- Navigation2 (Nav2)
- SLAM Toolbox
- Gazebo Sim
- RViz2
- BehaviorTree.CPP
- Groot2
- C++
- URDF
.
├── docs
│ ├── images
│ └── videos
├── src
│ ├── rosbot_description
│ ├── rosbot_nav2_bringup
│ ├── nav2_client
│ └── nav2_bt_client
├── README.md
└── .gitignore






