examples: print free heap size in hello_world example
This commit is contained in:
parent
2548a3e528
commit
1e462be4ab
1 changed files with 2 additions and 0 deletions
|
@ -31,6 +31,8 @@ void app_main(void)
|
||||||
printf("%dMB %s flash\n", spi_flash_get_chip_size() / (1024 * 1024),
|
printf("%dMB %s flash\n", spi_flash_get_chip_size() / (1024 * 1024),
|
||||||
(chip_info.features & CHIP_FEATURE_EMB_FLASH) ? "embedded" : "external");
|
(chip_info.features & CHIP_FEATURE_EMB_FLASH) ? "embedded" : "external");
|
||||||
|
|
||||||
|
printf("Free heap: %d\n", esp_get_free_heap_size());
|
||||||
|
|
||||||
for (int i = 10; i >= 0; i--) {
|
for (int i = 10; i >= 0; i--) {
|
||||||
printf("Restarting in %d seconds...\n", i);
|
printf("Restarting in %d seconds...\n", i);
|
||||||
vTaskDelay(1000 / portTICK_PERIOD_MS);
|
vTaskDelay(1000 / portTICK_PERIOD_MS);
|
||||||
|
|
Loading…
Reference in a new issue