Gazebo | Ignition | Community
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I believe the problem is coming from the <robotNamesapce>panda</robotNamespace> in your urdf.

tl;dr: You need to add ns="panda" in all controller_manager spawn nodes. eg. <node name="some_spawner" pkg="controller_manager" type="controller_manager" args="spawn whaterver_controller" ns="panda"/>.

Longer Anwser: In Gazebo9, the gazebo_ros_control plugin starts the controller_manager server in the namespace provided by the <robotNamespace> tag. In your case, panda. If you run rosservice list, you will see the following services

/panda/controller_manager/list_controller_types
/panda/controller_manager/list_controllers
/panda/controller_manager/load_controller
/panda/controller_manager/reload_controller_libraries
/panda/controller_manager/switch_controller
/panda/controller_manager/unload_controller

The node responsible for spawning controllers such as the joint state controller is a client to these services and needs to know the topic names. When using a node statement in the launch file like:

 <node name="some_spawner" pkg="controller_manager" type="controller_manager" args="spawn whaterver_controller"/>

the controller_manager client will look for those service in the root namespace (assuming no parent namespace). And since it can't find them, it will fail to spawn the controllers.

The easiest thing to do is to set ns="your_namespace" on the controller_manager node tags. You can also use <group> tags to create a parent namespace for your nodes.