Skip to main content

Part 3: Simulation Environments

Welcome to Part 3! With ROS 2 mastery from Part 2, you're ready to build and simulate complete robot systems. Simulation is where you'll test algorithms, validate designs, and iterate rapidly—all without expensive hardware or safety risks.

Why Simulation Matters for Physical AI

The Reality: Physical robots are expensive, fragile, and dangerous during development. A single mistake can destroy hardware or injure people. Testing on real robots is:

  • Slow (setup, reset, repair cycles)
  • Expensive ($10K-$500K+ per robot)
  • Risky (hardware damage, safety hazards)
  • Limited (can't easily test edge cases or dangerous scenarios)

The Solution: High-fidelity simulation lets you:

  • Iterate algorithms 100x faster than hardware
  • Test dangerous scenarios safely (falling, collisions)
  • Train reinforcement learning policies (millions of episodes)
  • Validate designs before building physical systems
  • Parallelize testing across multiple scenarios simultaneously

Part 3 teaches you to master the simulation environments used by leading robotics companies and research labs.

What You'll Learn in Part 3

Chapter 7: Gazebo Classic & Garden (4 lessons)

Master the most widely-used open-source robot simulator. Learn Gazebo's architecture, create world models in SDF, implement sensor and actuator plugins, and integrate seamlessly with ROS 2.

Key Topics:

  • Gazebo Classic vs Garden (Ignition) architecture differences
  • SDF world modeling (physics, lighting, materials)
  • Sensor simulation (cameras, lidar, IMU, contact sensors)
  • Plugin development for custom robot behaviors
  • ROS 2 integration via ros_gz_bridge

Real-World Use: NASA (Mars rovers), Toyota (autonomous vehicles), Clearpath (mobile robots)

Chapter 8: Unity Robotics Hub (4 lessons)

Leverage Unity's photorealistic rendering and physics for advanced robot simulation. Learn articulation bodies, perception sensors, and bidirectional ROS 2 communication.

Key Topics:

  • Unity Robotics Hub setup and ROS-TCP-Connector
  • Articulation bodies for multi-DOF robot simulation
  • High-fidelity perception (depth, segmentation, camera arrays)
  • Real-time ROS 2 topics and services in Unity
  • Synthetic data generation for ML training

Real-World Use: Amazon Robotics (warehouse training), NVIDIA (Isaac Sim uses Unity core), research labs for photorealistic datasets

Chapter 9: URDF and Robot Modeling (4 lessons)

Learn the Universal Robot Description Format—the standard for describing robot kinematics, dynamics, and visual appearance. Master Xacro for parametric robot models and integrate with ROS 2 Control.

Key Topics:

  • URDF basics (links, joints, coordinate frames)
  • Xacro macros for reusable, parametric models
  • Collision vs visual geometries (safety vs aesthetics)
  • Mesh imports (STL, DAE, OBJ)
  • ROS 2 Control hardware interfaces
  • robot_state_publisher and joint_state_publisher

Real-World Use: Universal standard—every ROS 2 robot uses URDF/Xacro

Learning Approach

Part 3 combines modeling skills with simulation workflows. You'll:

  • Build 3D robot models from scratch and from CAD imports
  • Configure physics engines (PhysX, ODE, Bullet)
  • Implement sensor pipelines (camera → perception algorithms)
  • Test motion controllers in simulation before hardware
  • Generate synthetic datasets for ML training

Prerequisites

Before starting Part 3:

  • ✅ Complete Part 2 (ROS 2 proficiency)
  • ✅ Gazebo Classic or Garden installed
  • ✅ Unity Hub + Unity 2022 LTS (for Chapter 8)
  • ✅ Basic 3D geometry understanding (coordinate frames, rotations)
  • ✅ Comfortable with XML/YAML configuration files

Development Environment

You'll need:

  • Gazebo Garden (latest) or Gazebo Classic 11 (legacy support)
  • Unity 2022 LTS with Robotics Hub packages
  • MeshLab or Blender (for mesh visualization/editing)
  • RViz2 (for URDF visualization)
  • Xacro (installed with ROS 2)

Estimated Time

⏱️ Total Time for Part 3: 18-24 hours

  • Core lessons: 12-15 hours (12 lessons × 1-1.25 hours each)
  • Hands-on modeling: 4-6 hours (building robot models)
  • Simulation testing: 2-3 hours (running experiments)

Recommended Pace: 2 lessons per week over 6 weeks

Part Structure

Chapter 7: Gazebo Classic & Garden (4 lessons)

  1. Gazebo Architecture (Classic vs Garden)
  2. World Models and SDF
  3. Sensors and Plugins
  4. ROS 2 Gazebo Integration

Chapter 8: Unity Robotics Hub (4 lessons)

  1. Unity ROS 2 Setup
  2. Articulation Bodies
  3. Perception in Unity
  4. ROS-Unity Communication

Chapter 9: URDF and Robot Modeling (4 lessons)

  1. URDF Basics
  2. Xacro Macros
  3. Collision and Visual Meshes
  4. ROS 2 Control Integration

Connection to Other Parts

Building on Part 2:

  • ROS 2 topics/services → Used to control simulated robots
  • TF2 transforms → Essential for URDF coordinate frames
  • Lifecycle nodes → Simulate robot startup/shutdown

Preparing for Part 4:

  • URDF skills → Required for Isaac Sim robot imports
  • Gazebo experience → Complements Isaac Sim workflows
  • Sensor simulation → Foundation for Isaac ROS perception

Enabling Parts 5-7:

  • Robot models → Used for humanoid kinematics and control
  • Simulation environments → Test locomotion and manipulation safely
  • Synthetic data → Train vision-language models for conversational robotics

Simulation-to-Reality Gap

The Challenge: Simulations are never perfect. Physics engines approximate, sensors have idealized noise models, and materials behave differently than reality.

Part 3 Prepares You:

  • Understand what simulations get right (kinematics, rough dynamics)
  • Identify what they miss (friction variability, material compliance, sensor artifacts)
  • Use domain randomization (vary parameters to improve real-world transfer)
  • Design algorithms robust to sim-to-real differences

Industry Approach:

  • Simulate to validate concepts quickly (10x-100x faster)
  • Test edge cases that are dangerous on hardware
  • Transfer policies to real robots with fine-tuning
  • Use hybrid approaches (sim for training, real data for adaptation)

Real-World Context

Companies Using Simulation:

  • OpenAI: Trained Rubik's Cube solver with 13,000 years of simulated practice
  • Boston Dynamics: Test Atlas locomotion in simulation before hardware trials
  • Tesla: Simulate autopilot scenarios (millions of miles virtually)
  • NVIDIA: Isaac Sim for warehouse robot training at scale
  • Agility Robotics: Digit humanoid trained partially in simulation

Research Impact:

  • Most robotics papers include simulation validation
  • Sim-to-real transfer is a major research area
  • Competitions (DARPA, RoboCup) increasingly use simulation phases

Success Criteria

By the end of Part 3, you will be able to:

✅ Build detailed robot models in URDF and Xacro ✅ Create custom Gazebo worlds with realistic physics ✅ Implement sensor plugins for cameras, lidar, and IMUs ✅ Integrate Gazebo simulations with ROS 2 control systems ✅ Set up Unity Robotics Hub for photorealistic rendering ✅ Generate synthetic datasets for ML training ✅ Design simulation experiments to validate algorithms ✅ Understand sim-to-real transfer challenges and mitigations ✅ Choose appropriate simulation tools for specific robotics tasks

What Comes Next

After completing Part 3, you'll move to Part 4: NVIDIA Isaac Platform, where you'll:

  • Master Isaac Sim for GPU-accelerated simulation
  • Use Isaac ROS for hardware-accelerated perception
  • Implement manipulation with Lula and cuRobo
  • Scale to multi-robot systems
  • Leverage RTX ray tracing and PhysX 5

Simulation skills from Part 3 directly transfer to Isaac's more advanced capabilities.


Ready to build and simulate? Begin with Chapter 7: Gazebo Classic & Garden


Part 3 is Weeks 5-7 of the 13-week curriculum.