Merge pull request #7380 from etracer65/cli_msc_device_check
Check that flash device is selected for blackbox before msc CLI reboot
This commit is contained in:
commit
06f1661d8f
|
@ -22,6 +22,8 @@
|
||||||
|
|
||||||
#include "platform.h"
|
#include "platform.h"
|
||||||
|
|
||||||
|
#include "blackbox/blackbox.h"
|
||||||
|
|
||||||
#include "drivers/sdcard.h"
|
#include "drivers/sdcard.h"
|
||||||
|
|
||||||
#include "io/flashfs.h"
|
#include "io/flashfs.h"
|
||||||
|
@ -32,10 +34,10 @@ bool mscCheckFilesystemReady(void)
|
||||||
{
|
{
|
||||||
return false
|
return false
|
||||||
#if defined(USE_SDCARD)
|
#if defined(USE_SDCARD)
|
||||||
|| sdcard_isFunctional()
|
|| (blackboxConfig()->device == BLACKBOX_DEVICE_SDCARD && sdcard_isFunctional())
|
||||||
#endif
|
#endif
|
||||||
#if defined(USE_FLASHFS)
|
#if defined(USE_FLASHFS)
|
||||||
|| flashfsGetSize() > 0
|
|| (blackboxConfig()->device == BLACKBOX_DEVICE_FLASH && flashfsGetSize() > 0)
|
||||||
#endif
|
#endif
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue