Skip to content

Latest commit

 

History

27 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

ros2_mir_nav2_pick_place

A comprehensive ROS 2 workspace for simulating, controlling, and navigating a MiR 100 mobile robot in Gazebo Harmonic. This repository includes complete packages for differential drive control, SLAM, Nav2 integration, and a custom orchestrator for pick-and-place missions. It features an interactive RViz GUI for dispatching missions and selecting pick/place poses directly from the map.

Note: The foundational URDF model for the MiR 100 used in this project was sourced and adapted from the URDF dataset GitHub repository.

System Requirements

  • OS: Ubuntu 24.04 (Noble)
  • ROS 2 Version: Jazzy Jalisco
  • Simulation: Gazebo Harmonic

Key Dependencies

Install the required ROS 2 packages before building the workspace:

sudo apt update
sudo apt install -y ros-jazzy-ros2-control ros-jazzy-ros2-controllers \
                    ros-jazzy-gz-ros2-control ros-jazzy-ros-gz-sim \
                    ros-jazzy-ros-gz-bridge ros-jazzy-ros-gz-interfaces \
                    ros-jazzy-navigation2 ros-jazzy-nav2-bringup \
                    ros-jazzy-slam-toolbox ros-jazzy-robot-state-publisher \
                    ros-jazzy-xacro ros-jazzy-rviz2

Repository Structure

The workspace is divided into modular packages:

  • mir_description: Xacro/URDF robot modeling, including definitions for differential drive chassis, Sick LiDAR, Realsense D435 RGB-D camera, and IMU.
  • mir_control: Controllers configuration and launch files for ros2_control and diff-drive kinematics.
  • mir_gazebo: Simulation environments, including a custom maze world designed for Gazebo Harmonic.
  • mir_navigation: Navigation stack configurations, including Nav2 parameter files, SLAM Toolbox launch files, behavior trees, custom map files, and RViz2 profiles.
  • pick_place_interfaces: Custom ROS 2 action (PickPlaceMission) and service (SpawnObject, ExecuteMission) definitions used by the orchestrator.
  • pick_place_orchestrator: Python-based nodes including an Object Manager for Gazebo entity manipulation and an Orchestrator state machine that interfaces with Nav2 for autonomous task sequencing.

Building the Workspace

Clone the repository into your workspace's src directory, then build using colcon:

# Navigate to the root of your workspace
cd ~/projects/Mobile_Robot

# Build the packages
colcon build --symlink-install

# Source the overlay
source install/setup.bash

Launch Files Reference

The project provides several launch files, ranging from standalone component tests to full end-to-end simulations.

pick_place_orchestrator

  • pick_place_sim.launch.py: The primary full-system simulation. Launches the Gazebo maze, Nav2 stack with a static map, robot description, controllers, and the pick-and-place orchestrator nodes for an end-to-end mission.

    Pick and Place Demo
    ros2 launch pick_place_orchestrator pick_place_sim.launch.py headless:=false use_rviz:=true
  • pick_place.launch.py: Starts the standalone pick-and-place nodes (Object Manager and Orchestrator) without launching Gazebo or the navigation stack.

    ros2 launch pick_place_orchestrator pick_place.launch.py

mir_navigation

  • navigation_sim.launch.py: Launches the Gazebo simulation and Nav2 stack with AMCL and a static map for autonomous navigation testing, without the orchestrator.

    Navigation Demo
    ros2 launch mir_navigation navigation_sim.launch.py
  • slam.launch.py: Launches the Gazebo simulation with slam_toolbox in asynchronous mode, allowing the robot to map the maze environment dynamically.

    ros2 launch mir_navigation slam.launch.py
  • navigation.launch.py: Launches the core Nav2 stack nodes (AMCL, Planner, Controller, Recoveries) using predefined parameters. Usually called by other wrapper launch files.

    ros2 launch mir_navigation navigation.launch.py
  • rviz.launch.py: Standalone launch file for RViz configured with the navigation.rviz display settings.

    ros2 launch mir_navigation rviz.launch.py

mir_gazebo

  • spawn_maze.launch.py: Launches the Gazebo Harmonic maze world, spawns the MiR robot model, and starts the ROS-Gazebo bridge for topics and TF.
    ros2 launch mir_gazebo spawn_maze.launch.py

mir_control

  • mir_control.launch.py: Loads and starts the diff_drive_controller and joint_state_broadcaster via ros2_control.
    ros2 launch mir_control mir_control.launch.py

mir_description

  • display.launch.py: Launches RViz with a joint_state_publisher_gui to visualize the MiR robot's URDF/Xacro standalone.
    ros2 launch mir_description display.launch.py

License

This project is licensed under the MIT License.

About

A complete ROS 2 Jazzy workspace for simulating, controlling, and navigating a MiR 100 mobile robot in Gazebo Harmonic, featuring Nav2 integration and an autonomous pick-and-place orchestrator.

Topics

Resources

Stars

14 stars

Watchers

1 watching

Forks

Contributors

Languages