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

Revision history [back]

You can use the namespace attribute ns to the rosparam call in your general_launch.launch file.

I.e. something along the lines of:

<launch>
  <rosparam command="load" file="$(arg param_file_name)" ns="my_node"/>
  <include file="$(find my_pkg)/my_node.launch"/>
</launch>

About the conceptual setup: I'd say that parameters in a private namespace should only belong to that node. I.e.

/my_node/param_x --> used by my_node, is fine
/my_node/param_y --> NOT used by my_node, I wouldn't do that...

If you want to group them, because they belong to one functionality or component, or something, I'd suggest to put the node in another namespace (using e.g. the group tag). I.e.

/my_functionality/my_node/param_x --> used by my_node, is fine
/my_functionality/param_y --> NOT used by my_node, but belongs to the functionality, like a general parameter used by multiple nodes