Unlimited transX Joint with articulation

I’m trying to create a simulation of a fixed endpoints rope. I used the rope demo and built my own version.
I need articulations to get the joints’ forces when the rope is in steady state. It seems like Articulations does not allow transX and when I run the simulation with 2 fixed endpoints I’m getting invalid physX errors.
I tried many variations of the Articulation root but I got eather limit transX or None Type handler.

At the start of the video - One fixed endpoint (no X forces) and everything works perfectly.

The problems start when I try to fix the other endpoint.

I tried to add a linear drive and unlimited transX but the Articulation just removed it.

What can i do? Is there another way to get forces and torques of a joint?

Recording 2024-03-02 105651

code.txt (8.7 KB)

If I understand your problem right then the issue is that the linear limits for a generic D6 joint in an articulation is not supported, you should see warnings like:

                        CARB_LOG_WARN("Translation DOF is expected to be locked for D6 joint in articulation hierarchy, the resulting joint in articulation will have all translation DOF locked.");
                        CARB_LOG_WARN("Linear drives on articulation D6 joints are not supported - drive is ignored. Joint: %s.", desc.articulationJoint->jointPrimPath.GetText());

However you should be able to replace the generic UsdPhysics.Joint with UsdPhysics.PrismaticJoint that supports the drives and limits properly, does that work for you?


Yes! Now transX is working and I can get the forces with the articulation. However, every other direction is limited. In general I need TransX, RotY and RotZ.

You should be able to do so, basically what you can do is to add just xform, add rigid body to it and then add a D6 joint with those rotY, rotZ.
Then the prismatic would be bodyA - new xformRigidBody (set some reasonable mass to it), the D6 would be new xformrigidBody - BodyB.

This is what I’ve understood from your answer, one xForm, inside of those 2 rigidBodies, one of them is connected to the xForm with rotY and rotZ. The other one is connected to the same xForm but with a prismatic joint.
Now it works but relative to a fix point. I’ve tried some more options like making the xForm to be relative to one of the bodies but I didn’t succeed in combining these 2 joints.

Thanks, this is very helpful.
Recording 2024-03-05 221714

I see so should not the order be:
a) prismatic joint between world (no body) and bodyA
b) fixed joint between bodyA and the xform
c) D6 joint between xform and bodyB for the rotY, rotZ
This should then work?

I’ve tried that, same result. when the xForm’s parent is the “world” it is fixed. I’ve also tried to insert the xForm under one of the bodies but
now the prismatic makes the rotY, rotZ locked again…(but it can move together in the space)

Ok, then I maybe misunderstood what you want to achieve can you maybe draw a simplified picture how the two bodies should move?

The simplest way to explain this is just a 6D joint between 2 bodies with rotZ, rotY and transX not locked.
This is the end result I want to get… The bodies should be freely to move in the space.
When I insert Articulation it blocks the transX…
The viedo show the wanted result (I just cant get this when the articulation is apllied).
here the transX limit is ± 0.1 but it is not 0!

Recording 2024-03-07 110557

Does this not work as expected?
d6joint.zip (4.4 KB)

Oh one small note, if you try to attach the rope from both sides to world/static body, this wont work, you will have to exclude one of the joints from the articulation, there is a bool for that.

Firstly, the bodies inside the Articulation folder works!
I don’t understand the note, I’ve realized this problem because I wanted to fix the 2 endpoints. I figured that it was caused by the limited transX. We solved it now? didn’t we?

And can you Explain about the supportBody?

There are two separate problems.

  1. The articulation cant have loops and in this case two fixed ends, this wont simulate, however this should be easy to fix. Simply one of the joints that act as joints to world has to be excluded from the articulation, it will be simulated as maximum coordinate joint, so things should still work as expected, its just that it cant be part of the articulation hierarchy.
  2. For generic D6 joints, PhysX does not support the translation limits (I should double check this maybe things changed since I implemented this). So unfortunately one needs to have a workaround here.
    So thats where the supportBody comes in:
    a) The body can be a simple xform with rigid body, but it would have bad mass properties, hence I added a box collision below it thats set as purpose guide so its not rendered, but adds some reasonable mass properties to this additional body
    b) Now what needs to be done is to change BodyA - D6 - BodyB into BodyA - Prismatic - SupportBody - D6 (angular) - BodyB. At one point I had this implemented behind the back of the user in the parsing, but there is a problem that then you dont have 1:1 mapping between the joints and the stuff thats simulated in PhysX and thats a problem. The biggest problem here is actually the position of the supportbody, because it has to be exactly on the position of the original D6 joint.

I didn’t understand what you’ve ment in (1).
I tried to keep working with answer 2 and according to your example I’ve got this (the video).

when I add limits to the prismatic joints I get the same errors as before. I tried maybe a strong linear drive but no success adding it with the articulation.
Recording 2024-03-08 170450

Can you send me the file please? I can take a look.

codetesting.zip (97.7 KB)

main.zip (2.3 KB)

I created a 5 links version.

I think the problem here is the drive you are trying to add.
As described in the documentation for a prismatic joint the driveAPI token is “linear”:

You assign a drive “transZ” but this is not expected on a prismatic joint, which does have a linear drive. TransZ would have been used for a generic D6 joint to define drive per axis.
If I add a linear drive I think it works as expected, one side note, I did also disable the collisions on the articulation root, otherwise your capsules will collide, which will be a problem for the hidden one. The capsules are not necessary if you provide reasonable mass to the body.

Everything is working! thank you very much, It was very helpful!

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