Ask Your Question

URDF velocity limit, how it works?

asked 2015-08-11 13:10:28 -0500

rubenvm gravatar image

Hello! I've taken the 06-flexible.urdf model from the urdf_tutorial package, and I've added the lines to set a velocity limit on the head_swivel joint into the urdf file.

Then I've displayed it on rviz thinking that when I would make a fast change on the joint value, it would take a little more time to get into this position, but what I have found is that the velocity limit is not making any effect in the robot representation. The changes take effect inmediately. So, how is the velocity limit supposed to work?

Thank you very much!


edit retag flag offensive close merge delete


Are you using the joint_state_publisher gui slider? I haven't used it in a while but those bypass the velocity limits. You need a controller in operation to respect velocity limits, and then you would be publishing commanded positions into the controller and then watch it work more slowly.

lucasw gravatar image lucasw  ( 2015-08-11 13:26:47 -0500 )edit

First of all, thank you for your answer. Yes, you are right, I'm using the joint_state_publisher gui sliders, I did not know it bypasses the limit. So, how I could implement this controller in operation? Is there any package to make it, or to make it easier? Thanks!

rubenvm gravatar image rubenvm  ( 2015-08-11 14:06:07 -0500 )edit

I've only used the controllers with gazebo following and - the controllers can be used outside of gazebo to connect to real hardware, but without real hardware you would need a sim.

lucasw gravatar image lucasw  ( 2015-08-11 15:04:33 -0500 )edit
lucasw gravatar image lucasw  ( 2015-08-11 15:05:34 -0500 )edit

Aha! Ok, I understand what you mean. We are assembling a robot, so the idea was keeping the simulation near to the robot and watch both. So, it's better if they move in a similar way. Thank you very much, I will try it.

rubenvm gravatar image rubenvm  ( 2015-08-11 15:47:40 -0500 )edit

1 Answer

Sort by » oldest newest most voted

answered 2015-08-12 02:55:14 -0500

Adolfo Rodriguez T gravatar image

Adding joint limits to a URDF is only the specification part. For these limits to be taken into account, you need an implementation that enforces them.

As you have already noticed, not all URDF-parsing implementations take the complete specification into account. The joint_state_publisher, for instance, takes joint names, types and position limits into account for publishing sensor_msgs/JointState messages, but does not not consider joint velocity limits. Also, there are certain specifications, like the maximum joint effort, that cannot be enforced with a kinematic-only implementation. So, the important thing is to understand the scope and limitations of an implementation, and a package's documentation should help here. I went ahead and added to the joint_state_publisher ROS wiki entry a comment to this effect.

As @lucasw mentions, you could consider using the ros_control framework for setting up your robot and move it with controllers that are aware of the complete URDF joint limits spec. You might find the joint_limits_interface package of particular interest. A more general discussion can be found on 24:14 of this video. Note that the overhead of setting up ros_control for your robot will be higher than setting up the joint_state_publisher, there's no free lunch.

edit flag offensive delete link more


Ok, thank you very much! Un placer encontrar españoles por aquí. Regards from Málaga.

rubenvm gravatar image rubenvm  ( 2015-08-12 05:07:07 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2015-08-11 13:10:28 -0500

Seen: 1,682 times

Last updated: Aug 12 '15