diff --git a/CHANGELOG.md b/CHANGELOG.md index 6017cc034..762bcad53 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ All notable changes to this project will be documented in this file. - Shelly 2PM Gen3 template {"NAME":"Shelly 2PM Gen3","GPIO":[9472,3458,576,225,4736,224,640,608,1,1,193,0,0,0,0,0,0,0,192,32,1,1],"FLAG":0,"BASE":1,"CMND":"AdcGpio4 10000,10000,4000"} - Shelly i4 Gen3 template {"NAME":"Shelly i4 Gen3","GPIO":[0,0,0,4736,32,195,194,193,1,1,192,0,0,0,0,0,0,0,0,0,1,1],"FLAG":0,"BASE":1,"CMND":"AdcGpio3 10000,10000,4000} - Show Active Power Total with any multi-phase energy monitoring (#22579) +- Command `SetOption162 1` to disable adding export energy to energy today (#22578) ### Breaking Changed - ESP32 ArtNet switches from GRB to RGB encoding (#22556) diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 873b43eeb..438b246e3 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -117,7 +117,8 @@ The latter links can be used for OTA upgrades too like ``OtaUrl https://ota.tasm ## Changelog v14.3.0.7 ### Added - Command `WebColor20` to control color of Button when Off -- Command `SetOption161 1` to disable display of state text (#22515) +- Command `SetOption161 1` to disable display of state text [#22515](https://github.com/arendst/Tasmota/issues/22515) +- Command `SetOption162 1` to disable adding export energy to energy today [#22578](https://github.com/arendst/Tasmota/issues/22578) - DALI support for short addresses (gear) and groups - DALI command `DaliGear` to set max found gear to speed up scan response - DALI command `DaliGroup` to add gear to groups diff --git a/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino b/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino index ae9086cfd..aae18311e 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_03_energy.ino @@ -278,7 +278,9 @@ void EnergyUpdateToday(void) { int32_t delta = Energy->kWhtoday_delta[i] / 1000; delta_sum_balanced += delta; Energy->kWhtoday_delta[i] -= (delta * 1000); - Energy->kWhtoday[i] += delta; + if (!Settings->flag6.no_export_energy_today || (delta > 0)) { // SetOption162 - (Energy) Do not add export energy to energy today (1) + Energy->kWhtoday[i] += delta; + } if (delta < 0) { // Export energy Energy->kWhtoday_export[i] += (delta *-1); if (Energy->kWhtoday_export[i] > 100) { diff --git a/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino b/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino index e44ec4fa5..e8ec16a2b 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_03_esp32_energy.ino @@ -543,7 +543,9 @@ void EnergyUpdateToday(void) { int32_t delta = Energy->kWhtoday_delta[i] / 1000; delta_sum_balanced += delta; Energy->kWhtoday_delta[i] -= (delta * 1000); - Energy->kWhtoday[i] += delta; + if (!Settings->flag6.no_export_energy_today || (delta > 0)) { // SetOption162 - (Energy) Do not add export energy to energy today (1) + Energy->kWhtoday[i] += delta; + } if (delta < 0) { // Export energy RtcEnergySettings.energy_export_kWh[i] += ((float)(delta / 100) *-1) / 1000; } diff --git a/tools/decode-status.py b/tools/decode-status.py index dd487a206..d8d9076af 100755 --- a/tools/decode-status.py +++ b/tools/decode-status.py @@ -216,8 +216,9 @@ a_setoption = [[ "(MQTT) Disable publish ModbusReceived MQTT messages (1), you must use event trigger rules instead", "(Counter) Enable counting on both rising and falling edge (1)", "(LD2410) Disable generate moving event by sensor report - use LD2410 out pin for events (1)", - "", - "","","","", + "(GUI) Disable display of state text (1)", + "(Energy) Do not add export energy to energy today (1)", + "","","", "","","","", "","","","", "","","","" @@ -340,7 +341,7 @@ else: obj = json.load(fp) def StartDecode(): - print ("\n*** decode-status.py v14.3.0.5 by Theo Arends and Jacek Ziolkowski ***") + print ("\n*** decode-status.py v14.3.0.7 by Theo Arends and Jacek Ziolkowski ***") # print("Decoding\n{}".format(obj))