Noureddine RAMDI / Exploring autonomy_stack_go2: A ROS2 and Unity-based autonomous vehicle simulation stack

Created Sat, 23 May 2026 20:41:14 +0000 Modified Sat, 23 May 2026 20:41:27 +0000

jizhang-cmu/autonomy_stack_go2

Building autonomous vehicles in simulation requires bridging complex middleware with realistic environments. autonomy_stack_go2 tackles this by integrating ROS2 middleware with Unity-based environment models to simulate autonomous vehicle navigation, focusing on base autonomy functions like waypoint following.

what autonomy_stack_go2 does and how it’s built

autonomy_stack_go2 is a C++ ROS2-based autonomous vehicle simulation stack designed to run with Unity environment models. The repository supports ROS2 Foxy and Humble distributions on Ubuntu 22.04, reflecting a practical approach to leveraging long-term support ROS versions.

Under the hood, the system uses ROS2 nodes and messages to interface with vehicle control, sensor simulation, and environment perception. Unity serves as the simulation front-end, rendering the environment and providing realistic vehicle sensor data and physics. This coupling enables developers to test autonomous navigation algorithms in a controlled, visualized setting without physical hardware.

The repository structure includes a base autonomy package that handles core vehicle control and sensor processing, tightly integrated with the Unity environment model, which must be downloaded separately and placed in a specific directory structure.

technical strengths and design tradeoffs

One of the key technical strengths of autonomy_stack_go2 is its multi-version ROS2 support, explicitly tested on both Foxy and Humble. This ensures compatibility with a broad user base and reflects careful maintenance.

The use of Unity for the environment model adds visual fidelity and realistic physics simulation, which is a tradeoff against the complexity of setting up Unity assets and ensuring synchronization with ROS2 messages.

The system also includes RVIZ integration for visualization, and waypoint navigation controls that allow users to interactively set vehicle waypoints. However, the waypoint system expects waypoints to be relatively close to the vehicle, highlighting a practical limitation in the navigation algorithm or simulation model that users must be aware of to avoid vehicle getting stuck.

From a developer experience perspective, the repository requires installing multiple ROS2 packages and Python dependencies, reflecting the complexity typical of robotics simulation stacks. The build process uses colcon with cmake-args for optimized release builds, which is standard but requires familiarity with ROS2 build tools.

Overall, the codebase balances realistic simulation needs with ROS2 standards, but users must manage dependencies and environment setup carefully.

quick start with autonomy_stack_go2

To get started with autonomy_stack_go2, first ensure you have an Ubuntu 22.04 system with ROS2 Foxy or Humble installed. Then install the necessary dependencies:

For Foxy:

sudo apt update
sudo apt install libusb-dev ros-foxy-perception-pcl ros-foxy-sensor-msgs-py ros-foxy-tf-transformations ros-foxy-joy ros-foxy-rmw-cyclonedds-cpp ros-foxy-rosidl-generator-dds-idl python3-colcon-common-extensions python-is-python3 
pip install transforms3d pyyaml

For Humble:

sudo apt update
sudo apt install libusb-dev ros-humble-perception-pcl ros-humble-sensor-msgs-py ros-humble-tf-transformations ros-humble-joy ros-humble-rmw-cyclonedds-cpp ros-humble-rosidl-generator-dds-idl python3-colcon-common-extensions python-is-python3 
pip install transforms3d pyyaml

Next, clone the repository and build it:

git clone https://github.com/jizhang-cmu/autonomy_stack_go2.git
cd autonomy_stack_go2
colcon build --symlink-install --cmake-args -DCMAKE_BUILD_TYPE=Release

After building, download the Unity environment model for Go2 and unzip it into the src/base_autonomy/vehicle_simulator/mesh/unity folder following the required directory structure.

Finally, launch the simulation:

./system_simulation.sh

Once the simulation is running and data appears in RVIZ, you can use the ‘Waypoint’ button to set close-range waypoints and navigate the vehicle around the environment.

verdict

autonomy_stack_go2 is a solid base autonomy simulation stack for developers working with ROS2 and Unity. Its dual ROS2 version support and integration with realistic Unity environments make it a valuable tool for research and development in autonomous vehicle navigation.

The main limitations lie in the dependency on specific ROS2 distributions and the somewhat constrained waypoint navigation system that requires close-range targets. Setting up the Unity environment separately adds complexity but is necessary for the simulation fidelity.

This stack is relevant for robotics developers and researchers who want to test autonomous navigation algorithms in simulation without the need for physical robots. Familiarity with ROS2 and Unity environment setup is essential for a smooth experience.

For anyone exploring autonomous vehicle simulation with ROS2, autonomy_stack_go2 provides a practical and extensible codebase worth investigating.


→ GitHub Repo: jizhang-cmu/autonomy_stack_go2 ⭐ 468 · C++