AP_FlashIface: panic if we haven't found a matching flash device

This commit is contained in:
Siddharth Purohit 2021-06-11 20:52:35 +05:30 committed by Andrew Tridgell
parent 30eb5501ce
commit 1a66b5afd7
1 changed files with 4 additions and 0 deletions

View File

@ -111,6 +111,10 @@ bool AP_FlashIface_JEDEC::init()
}
}
if (!_dev) {
AP_HAL::panic("Ext Flash Not Found!");
}
DELAY_MILLIS(5); // required by w25q
// Reset Device involves trying to soft reset the chip
// as when system reboots the device might not have.