Bugfix: uxTaskGetStackHighWaterMark only works in esp32

This commit is contained in:
Ewoud
2023-11-23 13:56:02 +01:00
parent 43a5a290c0
commit 587e6766c1
4 changed files with 1207 additions and 1207 deletions

View File

@@ -985,9 +985,9 @@ void serializeInfo(JsonObject root)
root[F("getflash")] = ESP.getFlashChipSize(); //WLEDMM and Athom, works for both ESP32 and ESP8266
root[F("freeheap")] = ESP.getFreeHeap();
root[F("freestack")] = uxTaskGetStackHighWaterMark(NULL); //WLEDMM
//WLEDMM: conditional on esp32
#if defined(ARDUINO_ARCH_ESP32)
root[F("freestack")] = uxTaskGetStackHighWaterMark(NULL); //WLEDMM
root[F("minfreeheap")] = ESP.getMinFreeHeap();
#endif
#if defined(ARDUINO_ARCH_ESP32) && defined(BOARD_HAS_PSRAM)