Robotics StackExchange | Archived questions

Is it possible to dynamically change a model's "static" parameter e.g. using a plugin?

I am simulating a robot that is meant to anchor itself to the environment. I am wondering if it would be possible to make the base link of the robot static, dynamically (e.g. when a condition is met in the simulation), or if anyone would have any recommendations on how to achieve this result?

Edit: I was looking through related questions and I think I found what I was looking for: SetLinkStatic()

However, when I use this command in a plugin it doesn't quite seem to work as expected... If I select the robot in Gazebo, the "is_static" tag is checked, as expected. However, the model is still affected by gravity and falls the the ground... Disabling gravity using SetGravityMode(false) also doesn't seem to help.

Conversely, if I set a model to static directly in the .SDF, it can "float", unaffected by gravity. Why does SetStatic()

Any help would be greatly appreciated!

Asked by shonig on 2020-10-08 14:19:54 UTC

Comments

@shonig Any update on this? I would be interested in the solution too.

Asked by Basti on 2021-03-10 05:01:45 UTC

Answers