ParameterTree
Access ROS parameter server
Description
A ParameterTree
object communicates with the ROS parameter
server. The ROS parameter server can store strings, integers, doubles, Booleans, and
cell arrays. The parameters are accessible globally over the ROS network. You can use
these parameters to store static data such as configuration parameters.
To directly set, get, or access ROS parameters without creating a
ParameterTree
object, see rosparam
.
The following ROS data types are supported as values of parameters. For each ROS data type, the corresponding MATLAB® data type is also listed.
ROS Data Type | MATLAB Data Type |
---|---|
32-bit integer | int32 |
boolean | logical |
double | double |
string | character vector (char ) |
list | cell array (cell ) |
dictionary | structure (struct ) |
Creation
Description
creates a
parameter tree object, ptree
= rosparamptree
. After
ptree
is created, the connection to the parameter
server remains persistent until the object is deleted or the ROS
master becomes unavailable.
ptree = ros.ParameterTree(
returns a node
)ParameterTree
object to communicate with the
ROS parameter server. The parameter tree attaches to the ROS node,
node
. To connect to the global node, specify
node
as []
.
Properties
Object Functions
Examples
Extended Capabilities
Version History
Introduced in R2019b