I'm quite new to Gazebo and I'm trying to access the kinematic properties of a joint during simulation on my custom plugin. While in the official documentation there's a Joint class exposing methods to get position and velocity, I've not found a similar method for the acceleration. Is it something I can get through the ECM?
1 Answer
$\begingroup$
$\endgroup$
You will have to calculate that yourself. Since Gazebo already provides a method of getting velocity, all you need to do is get the derivative of this to get the acceleration: $$ a = \frac{v_t - v_{t-1}}{t_t - t_{t-1}} $$ You just have to store the previous velocity value in the previous iteration.