Docs Overview Workspace repo
Docs menu

Docs

How the Racerbot cars' ROS 2 workspace is organized, how to run each driving algorithm, the mathematics each algorithm is built on, and beginner guides for new members.

The two Racerbot cars run one ROS 2 Jazzy workspace, Racerbot-Car-Workspace, on an NVIDIA Jetson Orin Nano Super. Both cars run the same code. Each car’s own hardware values live in its car profile, so a change to the driving code reaches both cars with one commit. These pages document that workspace, from how the nodes connect to the commands for every driving mode and the mathematics behind each algorithm. New members start with Beginners, which covers the terminal, a Docker development environment, ROS 2 and the simulator.

The two cars

Both cars use the same chassis (a Traxxas Ford Fiesta ST Rally VXL), the same Jetson, a Hokuyo LiDAR, a VESC motor controller with a built-in IMU and a BNO085 IMU. They differ in the sensors’ connections and in their calibration. A machine finds its car from its Jetson serial number in machines.yamlGitHub: car 1 is rb1 and car 2 is rb2. On a development computer or in the simulator, RACERBOT_CAR=rb1 or RACERBOT_CAR=rb2 chooses the car. Each car’s values are in its profile, cars/rb1/Car 1 or cars/rb2/Car 2, and The cars explains the profile. Where a page depends on one of these values, it shows a table like this one. The full list of differences, with the file that holds each, is docs/car1-vs-car2.mdGitHub.

Hardware and calibration
Car 1Car 2
LiDARHokuyo UST-30LX over USB, at /dev/sensors/hokuyoHokuyo UST-10LX over Ethernet, at 192.168.0.10
CameraUVC USB webcam at /dev/video0Intel RealSense D435i
BNO085 IMUJetson I2C bus 7, address 0x4AJetson I2C bus 7, address 0x4A; mount yaw and position not yet measured
Full-stick steering0.38 rad0.436 rad
Autonomy steering limit0.33 rad0.349 rad
Servo map
Speed to ERPM gain36504614
Dashboard site IDrb1rb2

Both cars model the same geometry: a 0.36 m wheelbase, a 0.31 m padded body width, and the LiDAR 0.26 m ahead of the rear axle. These were measured on car 2 on August 24, 2026. Car 1 uses the same values and has not been measured separately.

How the software is organized

Every piece of the stack communicates over ROS 2 topics. A launch is always two layers, each in its own terminal:

  1. Bringup (bringup_launch.py) starts the drivers for the gamepad, LiDAR and VESC, and ackermann_mux. Bringup never moves the car by itself.
  2. A control layer runs on top. It is teleop_launch.py for manual driving, or one autonomy node such as gap_follow or pure_pursuit.

ackermann_mux gives manual commands on /teleop (priority 100) precedence over autonomy commands on /drive (priority 10). Because joy_teleop keeps publishing while LB is released, no autonomy command reaches the motor for as long as teleop_launch.py is running, even though the autonomy node itself runs normally. Stop teleop before starting an autonomy node.

ROS 2 topic graph of the car Bringup's drivers read the hardware: joy_node the F710 gamepad, urg_node the Hokuyo LiDAR and vesc_driver_node the VESC. The control layer is joy_teleop on /teleop or an autonomy node on /drive, and ackermann_mux forwards the higher-priority command as /ackermann_cmd. ackermann_to_vesc converts it into motor and servo commands, while vesc_to_odom integrates the VESC's motor speed and servo command into /odom. F710 gamepad Hokuyo LiDAR VESC 6 MOTOR + SERVO joy_node urg_node vesc_driver_node vesc_to_odom_node ackermann_mux TELEOP 100 DRIVE 10 ackermann_to_vesc joy_teleop gap_follow or pure_pursuit /joy /joy LB /scan /teleop /drive /ackermann_cmd /odom /sensors/core /commands/motor/speed, /commands/servo/position USB USB/ETH USB Bringup: started once, never moves the car Control layer: run exactly one
The topic graph. Navy nodes start with bringup. The blue node is the control layer: exactly one of joy_teleop, gap_follow or pure_pursuit runs at a time. ackermann_mux passes the winning command on as /ackermann_cmd.

Safety rules

At full stick, manual driving commands 5 m/s, gap_follow is configured for up to 5.0 m/s and pure_pursuit for up to 4.0 m/s. Every mode on these pages follows the same rules.

Hold LB to drive. Every node that can move the car checks that the driver is holding LB on the F710 gamepad (XInput mode). Releasing LB, or losing /joy for 0.5 s, commands zero speed. Autonomy nodes enforce this check themselves, in addition to ackermann_mux. Never set enable_deadman to false on the car.
  • Run any new or changed driving code with the wheels off the ground first.
  • Never run teleop_launch.py alongside an autonomy node.
  • Keep one person beside the battery switch whenever the car drives itself.
  • Run ros2 run racerbot_doctor doctor before a session. It checks every device from USB up to the ROS topic and never publishes anything. See the pre-run checklist.

Relation to the course

The workspace implements the methods taught in the club’s RoboRacer course, which is adapted from the F1TENTH course. The labs build each method from scratch in the simulator, and the workspace runs the same methods on the car with what a physical car adds: a body-sized collision model, speed limits from braking distance and grip, and the LB check.

Course material Topic In the workspace
Lecture 1 (notes), Lab 1 ROS 2, packages, nodes, launch files ROS 2 in this workspace
Lecture 2 (notes), Lab 2 Time to collision and automatic emergency braking The TTC brake in Follow the gap
Lecture 3 (notes), Tutorial 3 (notes) Coordinate frames and TF2 Coordinate frames
Lecture 5 (notes), Lab 4 Follow the gap, safety bubble, disparity extender Follow the gap
Lecture 6 (notes) Vehicle states and the kinematic bicycle model Wheel odometry, Pure pursuit
Lecture 7 (notes) Bayes filters, Kalman filters, particle filters IMU fusion, SLAM and localization
Lecture 8 (notes), Lecture 9 (notes), Tutorial 5 (notes) SLAM, occupancy grids, pose graphs, slam_toolbox and the particle filter SLAM and localization, Map a course and race
Lecture 10 (notes) Pure pursuit Pure pursuit

Beginners

Get started

Safety

Run the car

Architecture

Autonomy

State estimation

Tools

Develop

Reference

Checked against workspace commit 556284c.