Missing option for locking joint motor

Report crashes, strange behaviour, or apparent bugs
Post Reply
TimD
Posts: 2
Joined: 05 Aug 2021, 09:43

Missing option for locking joint motor

Post by TimD »

Hey Coppelia!

I noticed when using the new version v4.4 that the option "lock moter when velocity is 0" is missing when the joint is in "Velocity Control mode". I noticed while debugging that you could disable the option (if it was enabled in a previous version), but when you do the option dissapears from the menu . Afterwards this option isn't available anymore. I also created a new scene where I added a new joint and put this in the "Velocity Control mode" but even then the option won't appear (In the Joints Dynamic Properties). Has this option been replaced to somewhere else since previous versions or is this a bug?

It's however still available in versions below Coppeliasim V4.4.

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

Re: Missing option for locking joint motor

Post by coppelia »

Hello,

yes, that functionality was removed (but is still working internally). It was removed because it is a kind of a hack, that few engines support. But you can still enable/disable it via sim.setObjectFloatParam and sim.jointintparam_velocity_lock

Cheers

TimD
Posts: 2
Joined: 05 Aug 2021, 09:43

Re: Missing option for locking joint motor

Post by TimD »

Hey Coppelia,

Firstly thanks for your reply :)!
I was indeed suspecting you had removed it but couldn't find it anywhere to confirm it.
Even the helpfiles online still say that it was possible so hence this post.
Do you have intention to fully remove this option and if so do you have any suggestion on how to have the same effect but in a non hacky way.

thanks again!

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

Re: Missing option for locking joint motor

Post by coppelia »

The API access will remain there for another few years for sure ;)

Without it, you have several workarounds, for instance:
  • set a very large force/torque, and a target velocity to 0
  • change the properties of the joint with sim.setJointInterval then call sim.resetDynamicObject
  • a bit more complicated, would be to add/remove a loop closure on the fly, that blocks the mass attached to the joint
Cheers

Post Reply