From b926f901eb254c47067248684a8bb51de0ed424a Mon Sep 17 00:00:00 2001 From: Patrick Pichon Date: Mon, 5 Sep 2022 10:53:27 +0200 Subject: [PATCH 1/3] prevent to have an unknown zcl_decoder message for IAS ACE as it is handled in inRawAPS --- Zigbee/zclDecoders.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Zigbee/zclDecoders.py b/Zigbee/zclDecoders.py index 79695c8ab..2fe7d40ed 100644 --- a/Zigbee/zclDecoders.py +++ b/Zigbee/zclDecoders.py @@ -102,6 +102,10 @@ def zcl_decoders(self, SrcNwkId, SrcEndPoint, TargetEp, ClusterId, Payload, fram if ClusterId == "0500" and is_direction_to_client(fcf) and Command == "01": return buildframe_8400_cmd(self, "8400", frame, Sqn, SrcNwkId, SrcEndPoint, TargetEp, ClusterId, ManufacturerCode, Command, Data) + + if ClusterId == "0501": + # Handle in inRawAPS + return frame if ClusterId in ( "ef00", "ff00"): # Do not log a message as this will be handled by the inRawAPS and delegated. From 4890b8668ff8c14c36ca8ed51f877091512e120c Mon Sep 17 00:00:00 2001 From: Patrick Pichon Date: Mon, 5 Sep 2022 11:06:24 +0200 Subject: [PATCH 2/3] when doing Reset in ConfigureReporting tool, all ReportingConfiguration records will be removed --- Classes/WebServer/rest_CfgReporting.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Classes/WebServer/rest_CfgReporting.py b/Classes/WebServer/rest_CfgReporting.py index df06bcdd1..3a90abba8 100644 --- a/Classes/WebServer/rest_CfgReporting.py +++ b/Classes/WebServer/rest_CfgReporting.py @@ -9,7 +9,8 @@ import Domoticz from Classes.WebServer.headerResponse import (prepResponseMessage, setupHeadersResponse) -from Modules.pluginDbAttributes import STORE_CUSTOM_CONFIGURE_REPORTING +from Modules.pluginDbAttributes import STORE_READ_CONFIGURE_REPORTING, STORE_CONFIGURE_REPORTING, STORE_CUSTOM_CONFIGURE_REPORTING + from Modules.zigateConsts import SIZE_DATA_TYPE @@ -79,8 +80,14 @@ def rest_cfgrpt_ondemand_with_config_delete(self, verb, data, parameters , _resp if STORE_CUSTOM_CONFIGURE_REPORTING in self.ListOfDevices[ deviceId ]: del self.ListOfDevices[ deviceId ][ STORE_CUSTOM_CONFIGURE_REPORTING ] + + if STORE_READ_CONFIGURE_REPORTING in self.ListOfDevices[ deviceId ]: + del self.ListOfDevices[ deviceId ][ STORE_READ_CONFIGURE_REPORTING ] + + if STORE_CONFIGURE_REPORTING in self.ListOfDevices[ deviceId ]: + del self.ListOfDevices[ deviceId ][ STORE_CONFIGURE_REPORTING ] - action = {"Name": "Configure reporting record removed", "TimeStamp": int(time.time())} + action = {"Name": "Reset Configure reporting records removed", "TimeStamp": int(time.time())} _response["Data"] = json.dumps(action, sort_keys=True) return _response From c73d347d64088f6efb4762a6ad8a4950a0363652 Mon Sep 17 00:00:00 2001 From: Patrick Pichon Date: Mon, 5 Sep 2022 11:09:55 +0200 Subject: [PATCH 3/3] comply with codefactor --- Classes/WebServer/rest_CfgReporting.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Classes/WebServer/rest_CfgReporting.py b/Classes/WebServer/rest_CfgReporting.py index 3a90abba8..cf3ec3a89 100644 --- a/Classes/WebServer/rest_CfgReporting.py +++ b/Classes/WebServer/rest_CfgReporting.py @@ -9,7 +9,7 @@ import Domoticz from Classes.WebServer.headerResponse import (prepResponseMessage, setupHeadersResponse) -from Modules.pluginDbAttributes import STORE_READ_CONFIGURE_REPORTING, STORE_CONFIGURE_REPORTING, STORE_CUSTOM_CONFIGURE_REPORTING +from Modules.pluginDbAttributes import STORE_READ_CONFIGURE_REPORTING, STORE_CONFIGURE_REPORTING, STORE_CUSTOM_CONFIGURE_REPORTING from Modules.zigateConsts import SIZE_DATA_TYPE