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

URDF model frames not published properly by robot_state_publisher

asked 2018-03-12 10:14:06 -0600

mindthomas gravatar image


I'm struggling with getting a URDF (or XACRO file to be exact) working with the robot_state_publisher. I know that it has been working when I made the file originally, but after updating and getting back to this project I simply can not get the robot_state_publisher to publish all the frames correctly.

You find the XACRO file as part of my repository here:

Try and clone the repository and build it with catkin and then run the rviz launch file. Or you can try and just run the robot_state_publisher on the xacro file output. Running a TF view_frames on the published frames gives the following incorrect result:

image description

It seems like the problem is related to the revolute or continuous joints. At least if I replace these joints with fixed joints the frames are published correctly.

PS. I'm running ROS Kinetic on Ubuntu 16.04.

Best regards, Thomas Jespersen

edit retag flag offensive close merge delete


Your problem is that you don't have all your tf published (those linked to the shafts) ?

Delb gravatar image Delb  ( 2018-03-12 10:50:28 -0600 )edit

Yes, agreed. But why doesn't the robot_state_publisher handle these missing ones (attached to the shafts) when the node seems to be publishing all the frames from the same URDF file nicely?

mindthomas gravatar image mindthomas  ( 2018-03-12 10:54:40 -0600 )edit

Well it's embarassing because when I run your code I had those tf published so it's not a problem with your code. I ran roslaunch jetsoncar_description rviz.launch and then rosrun rqt_tf_tree rqt_tf_tree

Delb gravatar image Delb  ( 2018-03-12 11:15:32 -0600 )edit

What does "can not get the robot_state_publisher to publish all the frames correctly"? What are we supposed to see? Please describe that in your question text.

gvdhoorn gravatar image gvdhoorn  ( 2018-03-12 11:38:03 -0600 )edit

@Delb If I try to run rosrun rqt_tf_tree rqt_tf_tree I get a segmentation fault.

@gvdhoorn You are supposed to see both left and right bearings and wheels attached to the front shaft and left and right wheels attached to the rear shaft.

mindthomas gravatar image mindthomas  ( 2018-03-13 09:10:13 -0600 )edit

Here is what I get with your urdf and rqt_tf_tree so you clearly have another issue. Try to do a simple urdf with multiples links to see if you have them all

Delb gravatar image Delb  ( 2018-03-13 09:44:54 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2018-03-17 04:04:12 -0600

mindthomas gravatar image

Problem has been solved by uninstalling/removing Anaconda. I don't know how Anaconda managed to mess up the runtime execution.

Any suggestions how to install and use Anaconda next to a well working ROS Kinetic environment?

edit flag offensive delete link more

Question Tools



Asked: 2018-03-12 10:14:06 -0600

Seen: 582 times

Last updated: Mar 17 '18