mirror of
https://github.com/justcallmekoko/ESP32Marauder.git
synced 2025-12-22 15:16:43 -08:00
fixup preprocessor directives
This commit is contained in:
@@ -270,13 +270,16 @@ void CommandLine::runCommand(String input) {
|
||||
#endif
|
||||
}
|
||||
// ls command
|
||||
#ifdef HAS_SD
|
||||
else if (cmd_args.get(0) == LS_CMD) {
|
||||
if (cmd_args.size() > 1)
|
||||
sd_obj.listDir(cmd_args.get(1));
|
||||
else
|
||||
Serial.println("You did not provide a dir to list");
|
||||
}
|
||||
#ifdef HAS_SD
|
||||
if (cmd_args.size() > 1)
|
||||
sd_obj.listDir(cmd_args.get(1));
|
||||
else
|
||||
Serial.println("You did not provide a dir to list");
|
||||
#else
|
||||
Serial.println("SD support disabled, cannot use command");
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
// Channel command
|
||||
@@ -666,16 +669,21 @@ void CommandLine::runCommand(String input) {
|
||||
}
|
||||
// Update via SD
|
||||
else if (sd_sw != -1) {
|
||||
#ifndef WRITE_PACKETS_SERIAL
|
||||
if (!sd_obj.supported) {
|
||||
Serial.println("SD card is not connected. Cannot perform SD Update");
|
||||
return;
|
||||
}
|
||||
wifi_scan_obj.currentScanMode = OTA_UPDATE;
|
||||
sd_obj.runUpdate();
|
||||
#else
|
||||
Serial.println("SD card not initialized. Cannot perform SD Update");
|
||||
#endif
|
||||
#ifdef HAS_SD
|
||||
#ifndef WRITE_PACKETS_SERIAL
|
||||
if (!sd_obj.supported) {
|
||||
Serial.println("SD card is not connected. Cannot perform SD Update");
|
||||
return;
|
||||
}
|
||||
wifi_scan_obj.currentScanMode = OTA_UPDATE;
|
||||
sd_obj.runUpdate();
|
||||
#else
|
||||
Serial.println("SD card not initialized. Cannot perform SD Update");
|
||||
#endif
|
||||
#else
|
||||
Serial.println("SD card support disabled. Cannot perform SD Update");
|
||||
return;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user