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

Revision history [back]

click to hide/show revision 1
initial version

As the first paragraph of the Names page says, these names can describe nodes, parameters, topics, and services. Essentially, names for all these resources use the same naming scheme, and that is what the Names page describes. When you use commands like rosnode list, rostopic list and rosparam list, you will see these names.

Names can be organised in a hierarchy because this makes it easier to structure them and find resources. The last part of the name after a slash is called the basename and that is the actual resource (topic, node, parameter, etc.). The rest is the namespace. Often namespaces are named after nodes, which makes it easy to identify, for example, parameters that are used by a specific node, or topics published by a specific node.

In the parameter server example you copied, /camera is a name space and may refer to a node named camera or may just be used to organise all camera parameters under a single namespace, /left and /right are organisational name spaces which could be used to identify the left and right cameras in a stereo camera setup, and /name and /exposure are the actual parameters. Note that there are two instances of both name and exposure; if they were not put in namespaces then they would collide, so using namespaces helps us to prevent collisions without naming parameters in non-reusable ways.

What names you choose is entirely up to you, but it helps to have a consistent naming scheme. Much of ROS has settled on conventions for names, so copying others is a good way to start.