Parameter (ROS 2)
- In French:
- Paramètre (ROS 2)
Definition
A configuration value attached to a ROS 2 node, such as a maximum speed or the name of a frame, that is set at start-up or at run time without changing the code. A parameter lives as long as its node. Initial values can be passed on the command line or in YAML files.
Checked on against the references below. · Written with AI · checked against the sources Source: Official ROS 2 documentation (Jazzy), “Parameters”.
Concrete examples
On TurtleBot 4, the turtlebot4_node node is configured with a YAML parameter file. The manual links to the robot’s default parameter file, then explains how to create your own file and launch the robot with that configuration.
What it changes for you
By default, a node must declare every parameter it accepts, so names and types are fixed at startup, and any attempt to change the type of a declared parameter at runtime fails. Each node also creates services by default, such as get_parameters and set_parameters, which let outside tools read and change its settings.
Additional material checked on .