JointController doesn't move the joint

asked 2016-10-28 09:48:07 -0600

bustun gravatar image

Hi, I created a simple robot model using urdf. In the urdf, there is a prismatic joint, which is supposed to move a link (a small box) vertically for position control.

joint values in urdf file : type="prismatic" limit effort="1000.0" lower="0" upper="2" velocity="1"

To move it vertically, I wrote a ROS aware gazebo plugin that takes the target position via ROS message. Then I used getJointController to move it like this:

my_model_->GetJointController()->SetPositionTarget(myJointName, 1.2);

my_model_->GetJointController()->SetPositionPID(myJointName, common::PID(2, 0, 1));

I just give a position target and filled the pid. not involved in effort, force or torque.

I tried my code in 2 different setup.

  1. virtualbox - ubuntu 16 - ros kinetic - gazebo 7.0

  2. virtualbox - ubuntu 16 - ros kinetic - gazebo 7.4

the code run on gazebo 7.0 without error and able to move the link as I wanted.

the code run on gazebo 7.4 without error but nothing moved.

Am I missing something or could it be related to a gazebo 7.4 issue ?

edit retag flag offensive close merge delete

Comments

There shouldn't be changes in API in a minor version, so the same code should be working with both. Sounds like a bug, you could ticket an issue here: https://bitbucket.org/osrf/gazebo/issues

chapulina gravatar imagechapulina ( 2016-10-28 12:33:57 -0600 )edit

Is there any update on this particular issue. I am facing a similar issue and I also use virtual machine. It might be related to the virtual machine usage

clrhurricane gravatar imageclrhurricane ( 2018-06-06 05:08:02 -0600 )edit