diff --git a/hardware.cpp b/hardware.cpp index be740b3..72c7a8c 100644 --- a/hardware.cpp +++ b/hardware.cpp @@ -10,6 +10,10 @@ #include #endif +#if defined(ESP8266) +#include +#endif + #include "memory.h" #include "ps2drv.h" #include "CPU.h" @@ -39,10 +43,12 @@ bool hardware_reset() { #if defined(USE_SD) success = SD.begin(SD_CS, 2, SD_SPI); pinMode(SPI_CS, OUTPUT); // without this, the SPI-RAM isn't seen -#endif -#if defined(USE_SPIFFS) +#elif defined(USE_SPIFFS) success = SPIFFS.begin(true); + +#elif defined(ESP8266) + success = SPIFFS.begin(); #endif #if defined(TFT_BACKLIGHT) diff --git a/sdtape.cpp b/sdtape.cpp index 59129a7..b0202c9 100644 --- a/sdtape.cpp +++ b/sdtape.cpp @@ -23,7 +23,6 @@ static Dir dir; bool sdtape::start(const char *programs) { #if defined(ESP8266) - SPIFFS.begin(); dir = SPIFFS.openDir("/"); #elif defined(DISK) dir = DISK.open(programs);