These docs are public and open source.Edit on GitHub
API REFERENCE / ROS 2
ROS 2 PARAMETERS.
Three groups of settings shape how the car behaves. The node loads its calibration from YAML at launch, the LiDAR driver takes its transport and framing settings, and a handful of drive constants decide how a /drive command maps to actual motion.
IMU calibrationLiDAR driverDrive tuning
IMU CALIBRATION
IMU CALIBRATION BIASES.
The IMU node declares these and reads them from config/imu_cal.yaml and config/mag_cal.yaml when the launch file starts it. The calibration scripts in the repo generate those files; the IMU bias page walks through running them.
| Parameter | Type | Default | Meaning |
|---|---|---|---|
| accelerometer.bias | double[3] | 0, 0, 0 | Per-axis offset subtracted from every acceleration reading, in m/s². The number a flat, still car should read as zero. |
| gyroscope.bias | double[3] | 0, 0, 0 | Per-axis offset subtracted from angular velocity, in rad/s. Removes the slow drift you see when the car is not moving. |
| magnetometer.hard_iron_bias | double[3] | 0, 0, 0 | Hard-iron offset removed from the raw magnetometer vector, in teslas, before any scaling. |
| magnetometer.soft_iron_matrix.data | double[9] | identity | A row-major 3×3 soft-iron correction applied after the hard-iron shift, to round out a skewed field into a sphere. |
LIDAR DRIVER
THE LIDAR DRIVER.
| Parameter | Type | Reference default | Meaning |
|---|---|---|---|
| frame_id | string | lidar_link | The TF frame stamped on every /scan. Your car uses lidar_link; the reference RPLIDAR build defaults this to laser_frame. |
| channel_type | string | serial | Transport to the scanner: serial, tcp, or udp. The LakiBeam1 is an Ethernet unit, so on your car this is the udp path. |
| serial_port | string | /dev/ttyUSB0 | The device file for a serial scanner. Not used on the Ethernet LakiBeam1. |
| serial_baudrate | int | 115200 | Link speed for a serial scanner. Not used on the Ethernet LakiBeam1. |
| angle_compensate | bool | true | Evens out the angular spacing of samples so each index maps to a fixed angle. |
| inverted | bool | false | Flips the scan direction, for a scanner mounted upside down. |
DRIVE TUNING
DRIVE TUNING CONSTANTS.
| Constant | File | Value | Effect |
|---|---|---|---|
| DRIVE_MAX_SPEED | throttle.py | 0.25 | The speed your /drive command is measured against. A speed of 0.25 is treated as full before throttle scaling. |
| CAR_THROTTLE_FORWARD | throttle.py | 0.0425 | The forward duty actually sent to the ESC at full command. This is the real speed cap that keeps a classroom car sane. |
| CAR_THROTTLE_BACKWARD | throttle.py | 0.06 | The reverse duty at full command. Higher than forward because the ESC needs more to break static friction backward. |
| CAR_THROTTLE_TURN | throttle.py | 0.25 | Scales the steering angle before it reaches the servo, trading lock for smoothness. |
| GAMEPAD_THROTTLE_AXIS | gamepad.py | 1 | Which Joy axis the teleop node reads as throttle. |
| GAMEPAD_STEER_AXIS | gamepad.py | 3 | Which Joy axis the teleop node reads as steering. |
//Reading and setting parameters at runtime
bash# What does a node expose? ros2 param list /imu_node # Read one ros2 param get /imu_node gyroscope.bias # Change one while the node runs (declared params only) ros2 param set /imu_node accelerometer.bias "[0.01, -0.02, 0.0]"
