diff --git a/CHANGELOG.md b/CHANGELOG.md index 4cda5b6e7..b55ccef20 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ All notable changes to this project will be documented in this file. ### Fixed - ESP32 ``Upload``, ``Upgrade``, ``WebGetConfig``, ``WebQuery`` and ``WebSend`` random HTTP(S) connection timeout set to 5 sec (commit 542eca3) +- ESP32 energy monitoring set StartTotalTime regression from v12.3.1.5 (#18385) ### Removed diff --git a/RELEASENOTES.md b/RELEASENOTES.md index dc1b36e5c..81b691ee0 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -153,3 +153,4 @@ The latter links can be used for OTA upgrades too like ``OtaUrl https://ota.tasm - Refactor energy monitoring reducing stack usage and solve inherent exceptions and watchdogs [#18164](https://github.com/arendst/Tasmota/issues/18164) - ESP32 ``Upload``, ``Upgrade``, ``WebGetConfig``, ``WebQuery`` and ``WebSend`` random HTTP(S) connection timeout set to 5 sec (commit 542eca3) - ESP32 energy period shows kWh value instead of Wh regression from v12.3.1.5 [#15856](https://github.com/arendst/Tasmota/issues/15856) +- ESP32 energy monitoring set StartTotalTime regression from v12.3.1.5 [#18385](https://github.com/arendst/Tasmota/issues/18385) \ No newline at end of file diff --git a/tasmota/tasmota_support/support_rtc.ino b/tasmota/tasmota_support/support_rtc.ino index 1c10811fc..84f775a98 100644 --- a/tasmota/tasmota_support/support_rtc.ino +++ b/tasmota/tasmota_support/support_rtc.ino @@ -186,9 +186,6 @@ String GetDateAndTime(uint8_t time_type) { } time = Rtc.restart_time; break; - case DT_ENERGY: - time = Settings->energy_kWhtotal_time; - break; case DT_BOOTCOUNT: time = Settings->bootcount_reset_time; break; diff --git a/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino b/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino index cd3c61770..ebbad0f72 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino @@ -1260,7 +1260,7 @@ void EnergyShow(bool json) { bool show_energy_period = (0 == TasmotaGlobal.tele_period); ResponseAppend_P(PSTR(",\"" D_RSLT_ENERGY "\":{\"" D_JSON_TOTAL_START_TIME "\":\"%s\",\"" D_JSON_TOTAL "\":%s"), - GetDateAndTime(DT_ENERGY).c_str(), + GetDT(Settings->energy_kWhtotal_time).c_str(), EnergyFmt(Energy->total, Settings->flag2.energy_resolution, 2)); if (energy_tariff) { diff --git a/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino b/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino index 0070dbe55..2261c53f2 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino @@ -1494,7 +1494,7 @@ void EnergyShow(bool json) { bool show_energy_period = (0 == TasmotaGlobal.tele_period); ResponseAppend_P(PSTR(",\"" D_RSLT_ENERGY "\":{\"" D_JSON_TOTAL_START_TIME "\":\"%s\",\"" D_JSON_TOTAL "\":%s"), - GetDateAndTime(DT_ENERGY).c_str(), + GetDT(Energy->Settings.energy_kWhtotal_time).c_str(), EnergyFmt(Energy->total, Settings->flag2.energy_resolution, 2)); if (energy_tariff) {