AP_InertialSensor: log failure to initialize after max attempts on MPU9250
This happens for example when you are trying to use an SPI speed that's above the one supported by the sensor or the controller.
This commit is contained in:
parent
587471ab54
commit
3dad768e8b
@ -237,6 +237,7 @@ bool AP_InertialSensor_MPU9250::_init_sensor(void)
|
||||
_spi_sem->give();
|
||||
}
|
||||
if (tries++ > 5) {
|
||||
hal.console->printf("MPU9250: 5 unsuccessful attempts to initialize\n");
|
||||
return false;
|
||||
}
|
||||
} while (1);
|
||||
|
Loading…
Reference in New Issue
Block a user