[ros-users] robot_state_publisher

Wim Meeussen meeussen at willowgarage.com
Tue Apr 6 16:43:10 UTC 2010


> I figured it out. My urdf model didn't have the same number of joints as
> my published joint_states messages.

I don't think this was your problem. The robot state publisher does
not care about additional/missing joints in the joint_states message.

> rostopic info /joint_states
> Type: sensor_msgs/JointState
> Publishers:
>  * /shadowhand_publisher (http://ulster:35258/)
> Subscribers: None

The output above shows the problem: no node is subscribed to the
joint_states topic. So the robot state publisher is not receiving any
messages. This should only happen when you give the robot state
publisher a urdf with no or only one link. In that case, the robot
state publisher couldn't possible publish anything, and it therefore
does not subscribe to the joint_states topic.

But, you should have seen a warning in 'rxconsole'. It should have
shown either "Robot state publisher got an empty tree and cannot
publish any state to tf" or "Robot state publisher got a tree with
only one segment and cannot publish any state to tf". After it shows
this warning, the robot state publisher just sits there, unable to do
anything. I guess that is quite a confusing state. We had a discussion
about this here <https://code.ros.org/trac/ros-pkg/ticket/3224>.  Feel
free to add comments based on your experience with the robot state


Wim Meeussen
Willow Garage Inc.

More information about the ros-users mailing list