mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 14:25:20 +03:00
Prevent the system from booting when EEPROM_IN_FLASH is used and the
flash chip is not detected. This will ensure that the flash config partition will always be present when requested.
This commit is contained in:
parent
720132b2af
commit
45f8168b60
2 changed files with 7 additions and 2 deletions
|
@ -324,7 +324,11 @@ void init(void)
|
|||
#error "EEPROM_IN_EXTERNAL_FLASH requires USE_FLASH_CHIP to be defined."
|
||||
#endif
|
||||
|
||||
flashInit(flashConfig());
|
||||
bool haveFlash = flashInit(flashConfig());
|
||||
|
||||
if (!haveFlash) {
|
||||
failureMode(FAILURE_EXTERNAL_FLASH_INIT_FAILED);
|
||||
}
|
||||
|
||||
#endif // EEPROM_IN_EXTERNAL_FLASH
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue