Skip to main content

Launch & Config Files

All customizations for the UAV's software should live inside the session folder, not in the installed system packages.

Launch Files

Grouped ROS2 nodes — such as all of the UAV's custom static transforms — live in XML launch files under the session's launch/ folder:

example_session/
└── launch/
└── static_tfs.launch.xml # All custom static transforms for this UAV

Launch files are invoked from the tmux session with ros2 launch ./launch/<file>.launch.xml. See Static Transforms for the full static_tfs.launch.xml example.

Scripts

Short, single-command wrappers (e.g. the rosbag recording command) stay as bash scripts directly in the session folder:

example_session/
├── record.sh # Rosbag recording command
└── ...

Each script is referenced as a command in the tmux session definition (see Base Session).

Configuration Files

Place all customized configuration files in the session's config/ folder:

example_session/
└── config/
├── custom_config.yaml # MRS UAV Status config
├── livox_mid360.json # Livox LiDAR driver config
├── camera_calibrations/ # Camera calibration files
│ ├── left_camera.yaml
│ └── right_camera.yaml
└── ...

Passing Config Files to Drivers

When a sensor driver supports a config/parameter file argument, point it at the copy in the session's config/ folder rather than editing the driver's packaged defaults. This keeps client-specific tuning inside the session folder and survives system updates.

Most ROS2 launch files expose these paths as launch arguments that can be overridden with key:=value on the ros2 launch command. For example, the Livox driver accepts user_config_path:

# Launch the Livox driver with a session-local config
'Livox' 'waitForRos; ros2 launch livox_ros_driver2 mid360.launch.py user_config_path:=./config/livox_mid360.json
'

The same pattern applies to any driver that exposes a config path as a launch argument — check the driver's launch file for the argument name (common ones: config_file, params_file, user_config_path, calibration_file).

tip

To see what arguments a launch file accepts:

ros2 launch <package> <launch_file> --show-args

Camera Calibrations

Store camera calibration files (generated during the Sensor Drivers step) in config/camera_calibrations/:

mkdir -p ~/example_session/config/camera_calibrations
cp <calibration_file>.yaml ~/example_session/config/camera_calibrations/

Reference these calibration files from your camera driver scripts or launch configurations.

Configuring the Session

Edit the session's tmux configuration to launch all sensors and additional software. The tmux session should start:

  1. The core MRS UAV System nodes
  2. All sensor drivers (cameras, LiDARs, rangefinders)
  3. Any additional software (SLAM, collision avoidance)
  4. The custom static transforms launch file
  5. MRS UAV Status monitoring

Each of these is added as an entry in the tmux session's input array (see the Base Session example). For example, to launch the custom static transforms:

'StaticTFs' 'waitForTime; ros2 launch ./launch/static_tfs.launch.xml
'
tip

Keep the session configuration organized. Group related nodes in the same tmux window or pane for easier monitoring during flights.