From 736d4d6576a5ac0abea8a68097299a9098428aae Mon Sep 17 00:00:00 2001 From: s-hadinger <49731213+s-hadinger@users.noreply.github.com> Date: Wed, 30 Apr 2025 10:01:59 +0200 Subject: [PATCH] WebUI heap status (#23356) --- CHANGELOG.md | 1 + tasmota/my_user_config.h | 1 + tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino | 3 +++ 3 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3a8fe96ed..37387db7a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ All notable changes to this project will be documented in this file. - Wireguard VPN (#23347) - Optional Wifi strength indicator in WebUI status line (#23352) - WebUI status line left and renamed events `FUNC_WEB_STATUS_LEFT` and `FUNC_WEB_STATUS_RIGHT` (#23354) +- WebUI heap status ### Breaking Changed diff --git a/tasmota/my_user_config.h b/tasmota/my_user_config.h index 848909e4c..f84b5b734 100644 --- a/tasmota/my_user_config.h +++ b/tasmota/my_user_config.h @@ -509,6 +509,7 @@ #define USE_ENHANCED_GUI_WIFI_SCAN // Enable Wi-Fi scan output with BSSID (+0k5 code) #define USE_WEB_STATUS_LINE // Enable upper status line in web UI (+0k5 code) // #define USE_WEB_STATUS_LINE_WIFI // Enable upper left wifi indicator in main page (+0k5 code) +// #define USE_WEB_STATUS_LINE_HEAP // Enable upper left display of free heap memory (+0k1 code) // #define USE_ALPINEJS // Enable AlpineJS v2.8.2 (+8k8 code) // #define USE_WEBSEND_RESPONSE // Enable command WebSend response message (+1k code) // #define USE_WEBGETCONFIG // Enable restoring config from external webserver (+0k6) diff --git a/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino b/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino index e36dfb288..440fd14ea 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_01_9_webserver.ino @@ -1931,6 +1931,9 @@ bool HandleRootStatusRefresh(void) { rssi >= -85 ? "active" : ""); } #endif // USE_WEB_STATUS_LINE_WIFI +#ifdef USE_WEB_STATUS_LINE_HEAP + WSContentSend_P(" %ik", ESP_getFreeHeap() / 1024); +#endif // USE_WEB_STATUS_LINE_HEAP // display here anything that goes on the left side XsnsXdrvCall(FUNC_WEB_STATUS_LEFT); WSContentSend_P(PSTR(""));