Husan

reading

writing

studio

projects

Husan

← projects
Thomas Cole — The Course of Empire: Destruction, 1836. The New-York Historical Society.

Thomas Cole — The Course of Empire: Destruction, 1836. The New-York Historical Society.

ROS2 SLAM & Autonomous Navigation

2026·ROS2 · Python · Nav2 · Gazebo · Docker

A full ROS2 mapping and navigation pipeline for TurtleBot3 in Gazebo, from SLAM map generation to autonomous multi-goal execution.

GitHub

Description

Context

Built as an intern onboarding task for the MD25010 grant project at New Uzbekistan University, this project implements a full SLAM and autonomous navigation pipeline in ROS2 using TurtleBot3 in Gazebo.

The objective was to produce a reproducible, end-to-end robotics workflow: containerized setup, map creation, autonomous mission execution, and measurable results.

System Architecture

The stack combines ROS2, Nav2, SLAM Toolbox, Gazebo, and RViz inside Docker, with browser-based VNC for launching and observing the robotics desktop environment.

ROS2 package build and runtime orchestration inside a consistent container

Gazebo simulation for robot/world dynamics

SLAM Toolbox for map generation in lifelong mapping mode

Nav2 for localization, planning, and goal-following

RViz for map and navigation state inspection

This architecture avoids local dependency drift and makes reruns predictable across machines.

Execution Flow

The workflow is intentionally divided into three stages so each milestone is independently verifiable.

Part A - Environment and Package Setup

Build and launch containerized workspace with Docker Compose

Build the ROS2 package via colcon

Configure TurtleBot3 model and runtime environment

Part B - Mapping (SLAM)

Launch Gazebo + RViz + SLAM stack

Teleoperate the robot to maximize map coverage

Export occupancy grid map artifacts for reuse

Part C - Autonomous Navigation

Switch from mapping to full navigation stack

Run scripted multi-goal execution (`send_nav_goals`) or manual goal placement

Log mission outcomes into CSV for evaluation

Results

Navigation evaluation reached 5 out of 5 goal completions with low terminal error, and every run produced auditable artifacts (saved maps, screenshots, and navigation logs).

Goal completion: 5/5 SUCCESS

Arrival error range: approximately 0.03m to 0.11m

Runtime metrics: per-goal timing stored for comparison and tuning

Engineering Decisions and Reliability Work

A key part of the project was making robotics-in-container execution reliable enough for repeated testing.

Enabled software rendering (`LIBGL_ALWAYS_SOFTWARE=1`) to stabilize Gazebo without GPU passthrough

Mounted map directories to preserve outputs between container sessions

Blocked problematic external model host lookup to prevent startup hangs

These choices improved startup stability and made the environment practical for iterative experimentation.

Deliverable Value

This repository is a reference implementation for ROS2 simulation workflows that need repeatability, observability, and measurable navigation outcomes.

It provides a clean base for future extensions such as Nav2 parameter tuning, map quality analysis, expanded waypoint missions, and benchmarking alternative planning strategies.