mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-09 01:18:29 -04:00
AP_NavEKF2: fix vertical flyaways when rangefinder stops providing data
This commit is contained in:
parent
3f6b43e3aa
commit
2b02c84ae4
@ -52,6 +52,8 @@ void NavEKF2_core::readRangeFinder(void)
|
|||||||
}
|
}
|
||||||
storedRngMeasTime_ms[sensorIndex][rngMeasIndex[sensorIndex]] = imuSampleTime_ms - 25;
|
storedRngMeasTime_ms[sensorIndex][rngMeasIndex[sensorIndex]] = imuSampleTime_ms - 25;
|
||||||
storedRngMeas[sensorIndex][rngMeasIndex[sensorIndex]] = sensor->distance_cm() * 0.01f;
|
storedRngMeas[sensorIndex][rngMeasIndex[sensorIndex]] = sensor->distance_cm() * 0.01f;
|
||||||
|
} else {
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// check for three fresh samples
|
// check for three fresh samples
|
||||||
|
Loading…
Reference in New Issue
Block a user