AirSim
AirSim copied to clipboard
why subtracting gravity when calculating linear_acceleration in ImuSimple
I saw below code in ImuSimple.hpp output.linear_acceleration = ground_truth.kinematics->accelerations.linear - ground_truth.environment->getState().gravity;
but I don't understand why subtracting gravity. That will make the linear_acceleration output near -10 always when the drone flying in a constant speed.
Is this an issue?
Thank you.
I got the idea suddenly. It's my fault. Sorry for that.
Thank you.
I understand how the imu working now. Thank you.