1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 00:05:33 +03:00

Indicate failure when CONFIG_IN_SDCARD is used and no SD card is

inserted.
This commit is contained in:
Dominic Clifton 2021-05-05 21:22:17 +02:00
parent 2a5e457603
commit e0f2b89828
2 changed files with 5 additions and 0 deletions

View file

@ -374,6 +374,10 @@ void init(void)
sdCardAndFSInit();
initFlags |= SD_INIT_ATTEMPTED;
if (!sdcard_isInserted()) {
failureMode(FAILURE_SDCARD_REQUIRED);
}
while (afatfs_getFilesystemState() != AFATFS_FILESYSTEM_STATE_READY) {
afatfs_poll();