ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
3

Delete multiple ROS parameters at once

asked 2012-04-12 06:05:24 -0600

Julius gravatar image

I am trying to delete multiple ROS parameters at once using rosparam delete but the command-line only allows to delete the parameters one by one. Unfortunately, sometimes, when re-running a node some of the node state is preserved in the parameters, hence when I want to make sure the nodes start in initial, canonical state I want to clear multiple parameter values at once. I imagine something like

rosparam delete '/my_node/*'

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
12

answered 2012-04-12 07:07:17 -0600

Lorenz gravatar image

From the command line, you can delete it with:

rosparam delete /my_node

This should get rid of all parameters in your node's namespace. Alternatively, when using a launch file you can use clear_params (see here):

<node name="foo" pkg="bar" type="baz" clear_params="true" />

This will get rid of all params in namespace foo before launching the node.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2012-04-12 06:05:24 -0600

Seen: 6,582 times

Last updated: Apr 12 '12