Provides parameter service functionality for ROS 2 nodes.
This module implements the standard ROS 2 parameter services:
- ~/get_parameters
- ~/set_parameters
- ~/set_parameters_atomically
- ~/list_parameters
- ~/describe_parameters
- ~/get_parameter_types
Summary
Functions
Add an on-set callback for parameter updates.
Add a post-set callback for parameter updates.
Add a pre-set callback for parameter updates.
Returns a specification to start this module under a supervisor.
Declare a parameter on the node.
Get parameter descriptors for the given parameter names.
Get the value of a parameter.
Get parameter types for the given parameter names.
Callback implementation for GenServer.init/1.
List all declared parameters.
Remove an on-set callback.
Remove a post-set callback.
Remove a pre-set callback.
Set single parameter.
Set multiple parameters atomically.
Functions
Add an on-set callback for parameter updates.
The callback receives a list of {name, parameter_value} tuples and may
approve or reject the update.
Add a post-set callback for parameter updates.
The callback is invoked with (parameter_name, new_value, old_value).
Add a pre-set callback for parameter updates.
The callback receives a list of {name, parameter_value} tuples and may
return a modified list.
Returns a specification to start this module under a supervisor.
See Supervisor.
Declare a parameter on the node.
Parameters must be declared before they can be set or retrieved.
Get parameter descriptors for the given parameter names.
If no names are provided, returns descriptors for all parameters.
Get the value of a parameter.
Returns {:ok, value} if the parameter exists, {:error, reason} otherwise.
Get parameter types for the given parameter names.
Returns a list of parameter types corresponding to the parameter names.
Callback implementation for GenServer.init/1.
List all declared parameters.
Get a list of parameter names and their prefixes.
Returns a list of parameter names.
Remove an on-set callback.
Remove a post-set callback.
Remove a pre-set callback.
Set single parameter.
Returns :ok if the parameter was set successfully, {:error, reason} otherwise.
Set multiple parameters atomically.
Returns :ok if all parameters were set successfully, {:error, reason} otherwise.