Direct joint torque/force control

Requests or suggestions for new features
Post Reply
tgurriet
Posts: 10
Joined: 14 Feb 2018, 14:23

Direct joint torque/force control

Post by tgurriet »

Hello,

Would it be possible have direct control over the torque/force at the joint?

I know it's possible to do so by enabling the motor at the joint and playing with desired velocity and max torque.
But it is a bit convoluted for something that basic...

When the joint is in torque/force mode but the motor is not enable, it should be possible to set a torque different from zero via a single API function call.

Thanks in advance,
Tom

coppelia
Site Admin
Posts: 10336
Joined: 14 Dec 2012, 00:25

Re: Direct joint torque/force control

Post by coppelia »

Hello,

setting the torque/target velocity of your joint when the motor in not enable will have no effect: the joint will remain free (not motorized).

When your motor is enabled, simply set a large target velocity (e.g. 600 deg/s for a revolute joint). Then, simply modulate the torque/force with sim.setJointforce.

Cheers

tgurriet
Posts: 10
Joined: 14 Feb 2018, 14:23

Re: Direct joint torque/force control

Post by tgurriet »

Sure, but that requires 2 API calls (to set the force and change the sign of the target velocity) for something very basic.

Hence the "request" for a mode where we can control joint torque directly with one API call.

Post Reply