mirror of https://github.com/FOME-Tech/fome-fw.git
no sd if early fatal (#2680)
This commit is contained in:
parent
61b0e85e0a
commit
da1d8edfa1
|
@ -327,6 +327,11 @@ void onUsbConnectedNotifyMmcI() {
|
|||
* Returns a BaseBlockDevice* corresponding to the SD card if successful, otherwise nullptr.
|
||||
*/
|
||||
static BaseBlockDevice* initializeMmcBlockDevice() {
|
||||
// Don't try to mount SD card in case of fatal error - hardware may be in an unexpected state
|
||||
if (hasFirmwareError()) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (!CONFIG(isSdCardEnabled)) {
|
||||
return nullptr;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue