Hi Jim,<div><br><div>I've answered inline</div><div><br><div class="gmail_quote">On Thu, Jan 27, 2011 at 10:37 AM, Jim Rothrock <span dir="ltr"><<a href="mailto:jim.rothrock@wunderkammerlab.com">jim.rothrock@wunderkammerlab.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">I am applying a torque to an axle like this:<br>
<br>
apply_effort = rospy.ServiceProxy("gazebo/apply_joint_effort",<br>
ApplyJointEffort)<br>
apply_effort("axle", 0.01, rospy.Time(), rospy.Duration(-1))<br>
rospy.sleep(0.05)<br>
apply_effort("axle", 0, rospy.Time(), rospy.Duration(-1))<br>
<br>
I expected the axle's angular velocity to accelerate for 0.05 seconds,<br>
then remain constant. In reality, the axle continues to accelerate. It<br>
appears that apply_joint_effort is cumulative, and my code actually<br>
needs to be like this:<br>
<br>
apply_effort("axle", 0.01, rospy.Time(), rospy.Duration(-1))<br>
rospy.sleep(0.05)<br>
apply_effort("axle", -0.01, rospy.Time(), rospy.Duration(-1))  # Cancel<br>
previous torque.<br>
<br>
Is my understanding correct?<br></blockquote><div><br></div><div>yes, the forces applied are cumulative.  I've updated the wiki to reflect so.</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

I tried to use gazebo/clear_joint_forces instead of applying a -0.01<br>
effort, but it appears that clear_joint_forces is no longer in ROS, even<br>
though it is in the Gazebo package documentation in the ROS wiki.<br></blockquote><div><br></div><div>which release are you running?  I see the clear_joint_forces service calls in both <a href="https://code.ros.org/svn/ros-pkg/stacks/simulator_gazebo/tags/cturtle/gazebo/src/gazeboros.cpp">cturtle</a> and <a href="https://code.ros.org/svn/ros-pkg/stacks/simulator_gazebo/tags/unstable/gazebo/src/gazeboros.cpp">unstable</a>(diamondback alpha) files.</div>

<div><br></div><div>Thanks,</div><div>John</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<font color="#888888"><br>
--<br>
Jim Rothrock | Wunderkammer Laboratory<br>
<a href="mailto:jim.rothrock@wunderkammerlab.com">jim.rothrock@wunderkammerlab.com</a><br>
<br>
_______________________________________________<br>
ros-users mailing list<br>
<a href="mailto:ros-users@code.ros.org">ros-users@code.ros.org</a><br>
<a href="https://code.ros.org/mailman/listinfo/ros-users" target="_blank">https://code.ros.org/mailman/listinfo/ros-users</a><br>
</font></blockquote></div><br></div></div>