This approach works for Arduino / PlatformIO as well as ESP-IDF projects.
#include <esp_heap_caps.h> uint32_t freeHeapBytes = heap_caps_get_free_size(MALLOC_CAP_DEFAULT);
This approach works for Arduino / PlatformIO as well as ESP-IDF projects.
#include <esp_heap_caps.h> uint32_t freeHeapBytes = heap_caps_get_free_size(MALLOC_CAP_DEFAULT);
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow