This provides the full ROS2 system for running the Unitree Go2 SDK.

System Overiew

The ROS2 SDK consists of three main services:
  • orchestrator: Manages SLAM, navigation, and map storage. Provides REST API endpoints for control and integration.
  • om1_sensor: Handles all low-level sensor drivers (Intel RealSense D435, RPLidar) and publishes ROS2 topics for localization and mapping.
  • watchdog: Monitors sensor and topic health, automatically restarting om1_sensor if issues are detected.
Service Interaction:
  1. om1_sensor collects and publishes sensor data.
  2. orchestrator consumes this data for SLAM and navigation.
  3. watchdog ensures continuous operation by monitoring data streams.

Starting the System

  1. Open a terminal in the unitree_go2_ros2_sdk directory.
  2. Run the following commands to start all services:
docker-compose up orchestrator -d --no-build
docker-compose up om1_sensor -d --no-build
docker-compose up watchdog -d --no-build
After initial setup, the system will auto-start when the robot boots.

Components Overview

1. watchdog

  • If any topics or sensors stop publishing data, the watchdog automatically restarts om1_sensor.
  • Ensures system stability during long-running sessions.

2. om1_sensor

The om1_sensor container manages all low-level sensor drivers:
  • Intel RealSense D435 (depth camera)
  • RPLidar (LiDAR scanning)
It publishes ROS2 topics consumed by the rest of the system:
  • /om/paths — Processed path and localization data
  • /scan — Raw LiDAR scan data

3. orchestrator

The orchestrator service provides an API endpoint and cloud service integration. It manages:
  • SLAM (Simultaneous Localization and Mapping)
  • Navigation (Nav2)
  • Map storage and loading
You can interact with it via REST APIs:

API Usage

Start SLAM

curl --location 'http://localhost:5000/start/slam' \
     --header 'Content-Type: application/json' \
     --data '{}'

Stop SLAM

curl --location 'http://localhost:5000/stop/slam' \
     --header 'Content-Type: application/json' \
     --data '{}'

Save a Map

curl --location 'http://localhost:5000/maps/save' \
     --header 'Content-Type: application/json' \
     --data '{"map_name": "office"}'

Start Navigation (Nav2)

curl --location 'http://localhost:5000/start/nav2' \
     --header 'Content-Type: application/json' \
     --data '{"map_name": "maps/office/office.yaml"}'

Stop Navigation (Nav2)

curl --location 'http://localhost:5000/stop/nav2' \
     --header 'Content-Type: application/json' \
     --data '{}'

Development Guidance

  • This section provides guidance for developers working on the new OM backpack system.
  • You can connect your Linux machine to one of the Ethernet ports of the OM backpack.
  • Open the network settings and find the network interface that the robot is connected to. In IPv4 settings, change the IPv4 mode to manual, set the address to 192.168.123.100, and set the mask to 255.255.255.0. After completion, click apply and wait for the network to reconnect.
  • Then you can subscribe to the topics published by the Orin AGX and the Unitree Go2 robot.

Troubleshooting

RPLiDAR Connection Issues

  1. Check USB connection:
ls -la /dev/ttyUSB*
  1. Verify permissions:
sudo chmod 777 /dev/ttyUSB0
  1. Add user to dialout group:
sudo usermod -a -G dialout $USER

SLAM Performance Issues

  • Reduce scan_buffer_size if experiencing dropped messages
  • Adjust correlation_search_space_dimension for better loop closure
  • Modify loop_search_maximum_distance based on environment size

Transform Issues

  • Ensure all required transforms are being published
  • Check TF tree with: ros2 run tf2_tools view_frames
  • Verify timing with: ros2 topic echo /tf

Robot Control Issues

  • Check cmd_vel messages:
    ros2 topic echo /cmd_vel
    
  • Ensure robot is in correct mode for movement commands.

Additional Resources


If you encounter issues not listed here, please contact the OM1 support team or join our community on Discord.