# Find joint axes with RViz TF, rather than link axes?

Hi

I am new to ROS and RViz and am getting used to the display options. I am learning kinematics. As I understand it, when you click the TF box in RVIz, this will show you your link axes.

However, I would like to view the joint axes.

This is because I have been told the URDF axis orientation for the robot I am looking at is different to those you would find in a Denavit Hartenberg analysis (Its the KUKA KR210). I may have to apply further rotations to make them match. I would like a visual representation of the URDF joint orientations to aid my understanding as I go about finding the DH equations and HT's for each joint.

Is it possible to display the URDF joint axes, as opposed to the URDF link axes?

Thanks!

edit retag close merge delete

Sort by » oldest newest most voted

You need to have a /robot_description (loaded from urdf/xacro) and use the RobotModel visualization in rviz to see the joints. Expand RobotModel and there should be an item called 'Links', which via the 'Link Tree Style' option can be changed to 'Joints in Alphabetic Order' or 'Tree of links and joints'. With either of those it is possible to check 'Show Joint Axis' for any joint in the robot.

That is at least in the kinetic version since rviz 1.12.4. https://github.com/ros-visualization/...

more

Apologies if this sounds confused, but I think what I am after is the "reference frames" of one joint to another, as opposed to just the plain old xyz axes. Its difficult to know the right questions to ask when you're learning!

( 2017-09-11 20:52:51 -0600 )edit

I think I would need a diagram to completely follow here, but I wonder if you split every joint into two, a fixed parent with the translation and a child with the rotation (though many joints are all xyz or all rpy), and then did tf lookups between the frames in the middle would be what you want

( 2017-09-12 09:58:04 -0600 )edit

But if you don't want to alter the urdf/xacro then you would have to look (programmatically) into the robot_description a do more complex tf lookups + additional operations to get the same thing, which I think is what @gvdhoorn is getting at.

( 2017-09-12 10:00:57 -0600 )edit

This is because I have been told the URDF axis orientation for the robot I am looking at is different to those you would find in a Denavit Hartenberg analysis

Yes, that is most definitely true, unless the person modelling the robot you are lookin at based it on D-H in the first place. For the KR210 you mention (this one?), that is most likely not the case.

URDF supports an arbitrary axis of rotation, where D-H requires / assumes the Z axis to always be used. Additionally, frames in ROS are supposed / required to follow REP-103 for chirality and axis orientation, and I don't believe that is compatible with D-H conventions necessarily.

But if I understand you correctly, then the "link axes" you are referring to are in fact what you are looking for.

The joint element in a urdf/xacro actually defines the transform from a parent link to a child link. After the transform tree is setup, the transforms of joints that are not of type fixed are used in FK to update the pose of all link frames according to values in JointState messages. But the joint elements themselves are really not used much any more.

link origins in ROS / urdf are not in their 'centre', so the transform from parent to child links actually defines the location of what you call 'joint axes'.

In summary: look at the links in a urdf to find the 'joint axes' you are after.

more