AP_InertialSensor: poll for new data in num_samples_available()

this lowers the latency for new data
This commit is contained in:
Andrew Tridgell 2013-01-09 20:31:09 +11:00
parent 4ab1cddd15
commit f48790a56e

View File

@ -600,6 +600,7 @@ float AP_InertialSensor_MPU6000::get_gyro_drift_rate(void)
// get number of samples read from the sensors // get number of samples read from the sensors
uint16_t AP_InertialSensor_MPU6000::num_samples_available() uint16_t AP_InertialSensor_MPU6000::num_samples_available()
{ {
_poll_data(0);
return _count; return _count;
} }