mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-02 14:08:45 -04:00
We should call imu.update() before asking for accel/gyro values so that we get timely, fresh numbers.
Most other consumers of the accel/gyro values should be asking us for them anyway. At that point, what they are getting are the values we sampled here. git-svn-id: https://arducopter.googlecode.com/svn/trunk@1376 f9c3cf11-9bcb-44bc-f272-b75c42450872
This commit is contained in:
parent
f4511fa7e6
commit
19f6c999ce
@ -41,6 +41,7 @@ AP_DCM::set_compass(Compass *compass)
|
||||
void
|
||||
AP_DCM::update_DCM(float _G_Dt)
|
||||
{
|
||||
_imu->update();
|
||||
_gyro_vector = _imu->get_gyro(); // Get current values for IMU sensors
|
||||
_accel_vector = _imu->get_accel(); // Get current values for IMU sensors
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user