Unit 08 · lesson

Why Launch Exists

Your Unit 7 system probably needs at least two terminals:

ros2 run robotnix_pubsub talker
ros2 run robotnix_pubsub listener

Now imagine twenty nodes, several parameters, remaps, namespaces, and startup arguments.

Manual startup becomes a source of configuration drift.

Concept flow

Launch turns manual startup choices into inspectable system configuration

A reproducible launch file reduces drift by encoding which nodes start and how they are configured.

  1. MANUAL CHOICESnodes, arguments, parameters, remaps, namespaces
    encode
  2. LAUNCH FILEPython describes startup configuration
    execute
  3. PROCESSESlaunch starts the requested programs
    create
  4. ROS GRAPHnodes appear with declared configuration
    compare
  5. REPRODUCIBLE STARTsame file makes configuration inspectable and repeatable

Launch-system purpose

The pinned ROS 2 tutorial describes launch as a system for describing configuration and executing it, including:

  • what programs/nodes to run;
  • where/how to run them;
  • arguments;
  • ROS-specific configuration;
  • monitoring process state.

Launch files can be written in XML, YAML, or Python. This course requires Python only so students can focus on one representation.

Configuration is part of the system

If two classmates launch the same node code but with different remappings/parameters, they may create different ROS graphs.

A launch file makes those choices inspectable and repeatable.

Checkpoint

List every manual choice needed to start your Unit 7 talker/listener system from a clean terminal. Circle the choices a launch file could encode.