How to use a Python script to set the state of a robot urdf in Gazebo so that it stays that way?
I can change the position randomly with service('/gazebo/set_model_state) and keep it there by subscribing to (gazebo/model_states), but when I give any other commands to the robot model, it stays in the same place. If I stop subscribing (gazebo/model_states), the robot will go back to its starting point (0,0).
The answer will depend on which gazebo model we are talking about. Is this a simulation of a robot arm? Are we talking about a revolute joint?
Please edit the question description to copy/paste 1) your urdf, and 2) your current python code.
You edit using the "edit" button near the end of the description. Format the urdf & code using the 101010 button.