AP_NavEKF2: removed duplicate compass switch check

left over from last set of changes
This commit is contained in:
Andrew Tridgell 2020-09-17 07:53:01 +10:00
parent 1fce38c62a
commit d6dcbda0d3

View File

@ -269,13 +269,6 @@ void NavEKF2_core::readMagData()
}
}
// check for a failed compass and switch if failed for magFailTimeLimit_ms
if (maxCount > 1 &&
!compass.healthy(magSelectIndex) &&
imuSampleTime_ms - lastMagRead_ms > frontend->magFailTimeLimit_ms) {
tryChangeCompass();
}
// do not accept new compass data faster than 14Hz (nominal rate is 10Hz) to prevent high processor loading
// because magnetometer fusion is an expensive step and we could overflow the FIFO buffer
if (use_compass() &&