Fixes #2007: Handle full SD card in openLogs(). SD card info menu implemented for Taranis, added display of free sectors. Disk IO simulation (all ported from master)
This commit is contained in:
+3
-1
@@ -59,6 +59,9 @@ const pm_char *openLogs()
|
||||
if (!sdMounted())
|
||||
return STR_NO_SDCARD;
|
||||
|
||||
if (sdGetFreeSectors() == 0)
|
||||
return STR_SDCARD_FULL;
|
||||
|
||||
// check and create folder here
|
||||
strcpy_P(filename, STR_LOGS_PATH);
|
||||
result = f_opendir(&folder, filename);
|
||||
@@ -193,7 +196,6 @@ void writeHeader()
|
||||
#endif
|
||||
}
|
||||
|
||||
// TODO test when disk full
|
||||
void writeLogs()
|
||||
{
|
||||
static const pm_char * error_displayed = NULL;
|
||||
|
||||
Reference in New Issue
Block a user