Model Mass not Updating
Hi, I posted this question on on ROS Answers, but I was advised to post it here as well.
I am using Gazebo version 9.11 with ROS-Melodic on Ubuntu 18.04.
I have a URDF that describes a boat. I have attached another link to the boat which acts as a payload, but is just a cylinder in practice. So I basically have baselink <---> payloadlink, with the interconnection being a joint of type "revolute".
I would like to be able to increase/decrease the weight of the payload while the simulation is already running. I have tried using rosservice call /gazebo/setlinkproperties, to update temphasized texthe mass this way. However, it does not affect the simulation. For example, if I update the mass of the cylinder to be 300 kg while Gazebo is running, the rosservice gives a successful message and the link property in the gazebo gui panel shows this update, but the boat itself remains unchanged. However if I set the mass of the cylinder to be 300kg in the urdf file, and then start the simulation, it does take effect and the boat immediately sinks.
I am relatively new to Gazebo and Ros so I am not sure how the Physics engine works, but I suspect it may be the problem. Any tips and suggestions would be much appreciated.
Asked by pauld on 2019-11-02 22:12:25 UTC
Comments