Copter: added RPM dataflash logging

This commit is contained in:
Andrew Tridgell 2015-08-07 20:34:27 +10:00
parent ab7e400a89
commit 80ad9aa605
1 changed files with 5 additions and 0 deletions

View File

@ -75,6 +75,11 @@ int16_t Copter::read_sonar(void)
void Copter::rpm_update(void)
{
rpm_sensor.update();
if (rpm_sensor.healthy(0) || rpm_sensor.healthy(1)) {
if (should_log(MASK_LOG_RCIN)) {
DataFlash.Log_Write_RPM(rpm_sensor);
}
}
}
// initialise compass