How to send joint torque command to Isaac Sim

Hello, I want to implement some controller to control robot arm position in Isaac Sim. I have developed my controller on Isaac SDK (c++) and the controller provides control input as torque. Does any components of Robot Engine Bridge can send torque command to Isaac Sim ?. Right now, I only able to send joint position by Joint Control component.

Currently only position and velocity control are supported.
The composite message doesn’t have a Measure that corresponds directly to torque on a joint

What proto message are you using with your controller?

I used composite proto.

Got it, which measure in the proto do you use to specify torque?
https://docs.nvidia.com/isaac/isaac/packages/composite/doc/composite_messages.html

Right now, I can’t specify torque directly, but I know that joint drive in Isaac Sim computes joint torque with this equation.

torque = stiffness × (targetPosition - p) + damping × (targetVelocity - v)

Then, I set damping = 0 and use Position Measure to send targetPosition = torque/stiffness + p which should turn above equation into just torque. However, with this work around method there are some limitations. Such as, the position feedback (p) from Isaac Sim only has value within [-2pi, 2pi] and simulation step size of Isaac Sim maybe isn’t small enough, so the behavior of my robot arm look unrealistic.

Do you have plan to support torque control in the future ?

From the Isaac Sim side there is already support to specify joint torques/efforts via the dynamic control API. The issue is that there isn’t proper support in the Composite proto for torque/effort messages from the Isaac SDK side.

It is possible to write a pyalice app to receive a custom effort message and then pass this onto dynamic control to do the joint control via a isaac sim extension/python script, I’ll make a note to add an example for this to make sure it would work.

https://docs.omniverse.nvidia.com/py/isaacsim/source/extensions/omni.isaac.dynamic_control/docs/index.html#omni.isaac.dynamic_control._dynamic_control.DynamicControl.set_articulation_dof_efforts

2 Likes

Actually, if you set stiffness to 0, it will be able to control directly torque

I am really interested in knowing more about your idea of using the extension/python to receive the message directly from the SDK. Are there exists now any examples of how this works?
Thanks

Is there any example to make isaac sdk torque control work? @Hammad_M

Hello, have you solved the problem?

I manage to write the custom python extension that can send/receive data between Isaac Sim and Isaac SDK through UDP. However, the second problem arises. The simulation sampling rate of Isaac Sim is too low and I can’t implement high gain control. Right now, my PC can only handle the simulation step of 120 Hz because the simulation step is bound to the render step.

Thanks for replying. Can you tell me which part of isaac sim extension api is used to send/receive custom message from isaac sdk?

Thanks for replying. Can you tell me which part of isaac sim extension api is used to send/receive custom message from isaac sdk?

I write my own networking library on both Isaac Sim and SDK to communicate with each other. On the Isaac Sim side, the library is based on python asyncio, while on the SDK side is based on Boost ASIO.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.