No isLocked property on asBuiltJoints?

lodeKYAQ8
Participant Participant
431 Views
2 Replies
Message 1 of 3

No isLocked property on asBuiltJoints?

lodeKYAQ8
Participant
Participant

Hi all,

 

Using a script to control the angles of some joints in my design, I found out that it is sometimes needed to be able to lock other joints first, as setting one joint can influence others, which is not always wanted.

 

When setting everything manually (via the browser UI), things seem to work, both (normal) joints and asBuiltJoints have the option to lock/unlock them.

 

Via the api, this does not seem to be the case: only (normal) joints have an isLocked property, asBuiltJoints don't seem to have it.

 

Am a overlooking something here?

 

Thanks,

Lode 

0 Likes
Accepted solutions (1)
432 Views
2 Replies
Replies (2)
Message 2 of 3

BrianEkins
Mentor
Mentor
Accepted solution

That's an oversight in the API design and should be added.  I thought there might be a workaround until then but I tried it and ran into another issue so I don't believe there is a solution at the current time.

 

---------------------------------------------------------------
Brian Ekins
Inventor and Fusion 360 API Expert
Website/Blog: https://EkinsSolutions.com
0 Likes
Message 3 of 3

lodeKYAQ8
Participant
Participant

Thanks for the reply Brian!

 

Meanwhile I found a workaround that does the trick for me. I create a (normal) joint between two dummy components (which can be hidden, or implemented in the form of a handle next to the design...) and have that one motion linked with the asBuiltJoint one I want to lock from the API. Now locking the dummy joint 'locks' the asBuiltJoint too, which solves my problem.

 

Something else I noticed is that using the API to change the angle of a joint in a linked component doesn't seem to work either (even though I can confirm I found it traversing through the component hierarchy). And interestingly enough, the above workaround also solves this issue (unless this is not an issue but rather my ignorance... I am a complete fusion noob, only a couple days of experience so far, but learning a lot and enjoying every bit of it)

 

0 Likes