Created
April 4, 2021 20:35
-
-
Save b13n1u/08922d2f821ee378c563130ce2c1b881 to your computer and use it in GitHub Desktop.
Get ESP8266 memory stats
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void loop() | |
{ | |
static uint32_t lastmin=65536; | |
static uint32_t myfree; | |
static uint16_t mymax; | |
static uint8_t myfrag; | |
ESP.getHeapStats(&myfree, &mymax, &myfrag); | |
Serial.printf("(%d) -> free: %5d - max: %5d - frag: %3d%% <- \n", millis(), myfree, mymax, myfrag); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment