From d32ff191d807987f13bc908ea35851e903b3036f Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Tue, 2 Nov 2021 09:18:26 -0400 Subject: [PATCH] Remove GetLastNetworkCommissioningResult from Network cluster (#11264) * Delete GetLastNetworkCommissioningResult from XML and zap regen * Delete GetLastNetworkCommissioningResult from .zap files * Restyle fixes --- .../all-clusters-common/all-clusters-app.zap | 16 ------- .../bridge-app/bridge-common/bridge-app.zap | 8 ---- .../lighting-common/lighting-app.zap | 8 ---- examples/lock-app/lock-common/lock-app.zap | 8 ---- .../ota-provider-common/ota-provider-app.zap | 8 ---- .../ota-requestor-app.zap | 8 ---- examples/pump-app/pump-common/pump-app.zap | 8 ---- .../pump-controller-app.zap | 8 ---- .../esp32/main/temperature-measurement.zap | 8 ---- .../thermostat-common/thermostat.zap | 16 ------- examples/tv-app/tv-common/tv-app.zap | 8 ---- .../tv-casting-common/tv-casting-app.zap | 16 ------- examples/window-app/common/window-app.zap | 16 ------- .../network-commissioning-ember.cpp | 7 --- .../zcl/data-model/chip/commissioning.xml | 4 -- .../data_model/controller-clusters.zap | 8 ---- .../java/zap-generated/CHIPClusters-JNI.cpp | 47 ------------------- .../chip/devicecontroller/ChipClusters.java | 7 --- .../devicecontroller/ClusterInfoMapping.java | 25 ---------- .../python/chip/clusters/CHIPClusters.cpp | 8 ---- .../python/chip/clusters/CHIPClusters.py | 16 ------- .../python/chip/clusters/Objects.py | 16 ------- .../CHIP/zap-generated/CHIPClustersObjc.h | 1 - .../CHIP/zap-generated/CHIPClustersObjc.mm | 7 --- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../app-common/zap-generated/callback.h | 6 --- .../zap-generated/cluster-objects.cpp | 34 -------------- .../zap-generated/cluster-objects.h | 28 ----------- .../app-common/zap-generated/command-id.h | 1 - .../app-common/zap-generated/ids/Commands.h | 4 -- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/cluster/Commands.h | 47 ++++--------------- .../zap-generated/CHIPClusters.cpp | 43 ----------------- .../zap-generated/CHIPClusters.h | 2 - .../zap-generated/CHIPClustersInvoke.cpp | 6 --- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../tv-app/zap-generated/CHIPClusters.cpp | 43 ----------------- .../tv-app/zap-generated/CHIPClusters.h | 2 - .../zap-generated/CHIPClustersInvoke.cpp | 6 --- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- .../zap-generated/IMClusterCommandHandler.cpp | 10 ---- 48 files changed, 10 insertions(+), 614 deletions(-) diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap index 781252b99f0d46..fc9066598cb05e 100644 --- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap +++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap @@ -1605,14 +1605,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ @@ -8855,14 +8847,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/bridge-app/bridge-common/bridge-app.zap b/examples/bridge-app/bridge-common/bridge-app.zap index e841a367357785..f367ba6f4e7de3 100644 --- a/examples/bridge-app/bridge-common/bridge-app.zap +++ b/examples/bridge-app/bridge-common/bridge-app.zap @@ -593,14 +593,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/lighting-app/lighting-common/lighting-app.zap b/examples/lighting-app/lighting-common/lighting-app.zap index 85c3da4d2c5e24..5d3cca03b49f4c 100644 --- a/examples/lighting-app/lighting-common/lighting-app.zap +++ b/examples/lighting-app/lighting-common/lighting-app.zap @@ -1479,14 +1479,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/lock-app/lock-common/lock-app.zap b/examples/lock-app/lock-common/lock-app.zap index 4bae20d3161cc4..ae139b563c6055 100644 --- a/examples/lock-app/lock-common/lock-app.zap +++ b/examples/lock-app/lock-common/lock-app.zap @@ -1387,14 +1387,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap b/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap index 3199bbc26a5ce7..ffafffc8b23946 100644 --- a/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap +++ b/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap @@ -1335,14 +1335,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap index ae55dfdb357668..5e3a06f0d43843 100644 --- a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap +++ b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap @@ -1374,14 +1374,6 @@ "source": "client", "incoming": 1, "outgoing": 0 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 0 } ], "attributes": [] diff --git a/examples/pump-app/pump-common/pump-app.zap b/examples/pump-app/pump-common/pump-app.zap index 0bdff0af3a16d1..f1368ec2d0d820 100644 --- a/examples/pump-app/pump-common/pump-app.zap +++ b/examples/pump-app/pump-common/pump-app.zap @@ -1301,14 +1301,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 0, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap b/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap index 5682297f128530..25a28a60e38e9d 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap @@ -1301,14 +1301,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/temperature-measurement-app/esp32/main/temperature-measurement.zap b/examples/temperature-measurement-app/esp32/main/temperature-measurement.zap index 593a47da9321e7..b227b7e1ce97da 100644 --- a/examples/temperature-measurement-app/esp32/main/temperature-measurement.zap +++ b/examples/temperature-measurement-app/esp32/main/temperature-measurement.zap @@ -979,14 +979,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/thermostat/thermostat-common/thermostat.zap b/examples/thermostat/thermostat-common/thermostat.zap index b69b1417145878..a0f8df36cb3291 100644 --- a/examples/thermostat/thermostat-common/thermostat.zap +++ b/examples/thermostat/thermostat-common/thermostat.zap @@ -1500,14 +1500,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ @@ -8094,14 +8086,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/tv-app/tv-common/tv-app.zap b/examples/tv-app/tv-common/tv-app.zap index 5a68dcf6d55a66..c2598636c026d3 100644 --- a/examples/tv-app/tv-common/tv-app.zap +++ b/examples/tv-app/tv-common/tv-app.zap @@ -1485,14 +1485,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap b/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap index a7c3f90ea97f16..a8356bc5904536 100644 --- a/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap +++ b/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap @@ -1500,14 +1500,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ @@ -8094,14 +8086,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/examples/window-app/common/window-app.zap b/examples/window-app/common/window-app.zap index fe95ec93bda4d2..8a7f864403126c 100644 --- a/examples/window-app/common/window-app.zap +++ b/examples/window-app/common/window-app.zap @@ -1068,14 +1068,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ @@ -4260,14 +4252,6 @@ "source": "client", "incoming": 1, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 1, - "outgoing": 1 } ], "attributes": [ diff --git a/src/app/clusters/network-commissioning/network-commissioning-ember.cpp b/src/app/clusters/network-commissioning/network-commissioning-ember.cpp index 6607e0edd3c6c4..73a05309d0582e 100644 --- a/src/app/clusters/network-commissioning/network-commissioning-ember.cpp +++ b/src/app/clusters/network-commissioning/network-commissioning-ember.cpp @@ -91,13 +91,6 @@ bool emberAfNetworkCommissioningClusterDisableNetworkCallback(app::CommandHandle return false; } -bool emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback( - app::CommandHandler * commandObj, const app::ConcreteCommandPath & commandPath, - const Commands::GetLastNetworkCommissioningResult::DecodableType & commandData) -{ - return false; -} - bool emberAfNetworkCommissioningClusterRemoveNetworkCallback(app::CommandHandler * commandObj, const app::ConcreteCommandPath & commandPath, const Commands::RemoveNetwork::DecodableType & commandData) diff --git a/src/app/zap-templates/zcl/data-model/chip/commissioning.xml b/src/app/zap-templates/zcl/data-model/chip/commissioning.xml index 9db6dc5450ad9f..36647a7946cff5 100644 --- a/src/app/zap-templates/zcl/data-model/chip/commissioning.xml +++ b/src/app/zap-templates/zcl/data-model/chip/commissioning.xml @@ -158,9 +158,5 @@ limitations under the License. - - TODO - - diff --git a/src/controller/data_model/controller-clusters.zap b/src/controller/data_model/controller-clusters.zap index 49b33c958e9090..851a59a40b24dc 100644 --- a/src/controller/data_model/controller-clusters.zap +++ b/src/controller/data_model/controller-clusters.zap @@ -2813,14 +2813,6 @@ "source": "client", "incoming": 0, "outgoing": 1 - }, - { - "name": "GetLastNetworkCommissioningResult", - "code": 16, - "mfgCode": null, - "source": "client", - "incoming": 0, - "outgoing": 1 } ], "attributes": [ diff --git a/src/controller/java/zap-generated/CHIPClusters-JNI.cpp b/src/controller/java/zap-generated/CHIPClusters-JNI.cpp index 16092a72f7ac34..24ce083abe7cf5 100644 --- a/src/controller/java/zap-generated/CHIPClusters-JNI.cpp +++ b/src/controller/java/zap-generated/CHIPClusters-JNI.cpp @@ -21643,53 +21643,6 @@ JNI_METHOD(void, NetworkCommissioningCluster, enableNetwork) timeoutMs); SuccessOrExit(err); -exit: - if (err != CHIP_NO_ERROR) - { - jthrowable exception; - jmethodID method; - - err = JniReferences::GetInstance().FindMethod(env, callback, "onError", "(Ljava/lang/Exception;)V", &method); - if (err != CHIP_NO_ERROR) - { - ChipLogError(Zcl, "Error throwing IllegalStateException %" CHIP_ERROR_FORMAT, err.Format()); - return; - } - - err = CreateIllegalStateException(env, "Error invoking cluster", err, exception); - if (err != CHIP_NO_ERROR) - { - ChipLogError(Zcl, "Error throwing IllegalStateException %" CHIP_ERROR_FORMAT, err.Format()); - return; - } - env->CallVoidMethod(callback, method, exception); - } - else - { - onSuccess.release(); - onFailure.release(); - } -} -JNI_METHOD(void, NetworkCommissioningCluster, getLastNetworkCommissioningResult) -(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jlong timeoutMs) -{ - chip::DeviceLayer::StackLock lock; - CHIP_ERROR err = CHIP_NO_ERROR; - NetworkCommissioningCluster * cppCluster; - - std::unique_ptr onSuccess( - Platform::New(callback), Platform::Delete); - std::unique_ptr onFailure( - Platform::New(callback), Platform::Delete); - VerifyOrExit(onSuccess.get() != nullptr, err = CHIP_ERROR_INCORRECT_STATE); - VerifyOrExit(onFailure.get() != nullptr, err = CHIP_ERROR_INCORRECT_STATE); - - cppCluster = reinterpret_cast(clusterPtr); - VerifyOrExit(cppCluster != nullptr, err = CHIP_ERROR_INCORRECT_STATE); - - err = cppCluster->GetLastNetworkCommissioningResult(onSuccess->Cancel(), onFailure->Cancel(), timeoutMs); - SuccessOrExit(err); - exit: if (err != CHIP_NO_ERROR) { diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java index b03b41c30ac20d..bd6de9f102b2b3 100644 --- a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java +++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java @@ -4317,10 +4317,6 @@ public void enableNetwork( enableNetwork(chipClusterPtr, callback, networkID, breadcrumb, timeoutMs); } - public void getLastNetworkCommissioningResult(DefaultClusterCallback callback, long timeoutMs) { - getLastNetworkCommissioningResult(chipClusterPtr, callback, timeoutMs); - } - public void removeNetwork( RemoveNetworkResponseCallback callback, byte[] networkID, long breadcrumb, long timeoutMs) { removeNetwork(chipClusterPtr, callback, networkID, breadcrumb, timeoutMs); @@ -4377,9 +4373,6 @@ private native void enableNetwork( long breadcrumb, long timeoutMs); - private native void getLastNetworkCommissioningResult( - long chipClusterPtr, DefaultClusterCallback callback, long timeoutMs); - private native void removeNetwork( long chipClusterPtr, RemoveNetworkResponseCallback callback, diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java index 56a412f5039bab..7ff6abb55939eb 100644 --- a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java +++ b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java @@ -5513,31 +5513,6 @@ public Map getClusterMap() { networkCommissioningenableNetworkCommandParams); networkCommissioningClusterCommandInfoMap.put( "enableNetwork", networkCommissioningenableNetworkCommandInfo); - Map - networkCommissioninggetLastNetworkCommissioningResultCommandParams = - new LinkedHashMap(); - CommandParameterInfo networkCommissioninggetLastNetworkCommissioningResultCommandParameterInfo = - new CommandParameterInfo("NetworkCommissioning", ChipClusters.DefaultClusterCallback.class); - CommandParameterInfo - networkCommissioninggetLastNetworkCommissioningResulttimeoutMsCommandParameterInfo = - new CommandParameterInfo("timeoutMs", long.class); - networkCommissioninggetLastNetworkCommissioningResultCommandParams.put( - "timeoutMs", - networkCommissioninggetLastNetworkCommissioningResulttimeoutMsCommandParameterInfo); - - // Populate commands - CommandInfo networkCommissioninggetLastNetworkCommissioningResultCommandInfo = - new CommandInfo( - (cluster, callback, commandArguments) -> { - ((ChipClusters.NetworkCommissioningCluster) cluster) - .getLastNetworkCommissioningResult( - (DefaultClusterCallback) callback, (Long) commandArguments.get("timeoutMs")); - }, - () -> new DelegatedDefaultClusterCallback(), - networkCommissioninggetLastNetworkCommissioningResultCommandParams); - networkCommissioningClusterCommandInfoMap.put( - "getLastNetworkCommissioningResult", - networkCommissioninggetLastNetworkCommissioningResultCommandInfo); Map networkCommissioningremoveNetworkCommandParams = new LinkedHashMap(); CommandParameterInfo networkCommissioningremoveNetworkCommandParameterInfo = diff --git a/src/controller/python/chip/clusters/CHIPClusters.cpp b/src/controller/python/chip/clusters/CHIPClusters.cpp index 2585a4957123b6..d8dcf29ce95e5b 100644 --- a/src/controller/python/chip/clusters/CHIPClusters.cpp +++ b/src/controller/python/chip/clusters/CHIPClusters.cpp @@ -5678,14 +5678,6 @@ chip::ChipError::StorageType chip_ime_AppendCommand_NetworkCommissioning_EnableN cluster.Associate(device, ZCLendpointId); return cluster.EnableNetwork(nullptr, nullptr, chip::ByteSpan(networkID, networkID_Len), breadcrumb, timeoutMs).AsInteger(); } -chip::ChipError::StorageType chip_ime_AppendCommand_NetworkCommissioning_GetLastNetworkCommissioningResult( - chip::Controller::Device * device, chip::EndpointId ZCLendpointId, chip::GroupId, uint32_t timeoutMs) -{ - VerifyOrReturnError(device != nullptr, CHIP_ERROR_INVALID_ARGUMENT.AsInteger()); - chip::Controller::NetworkCommissioningCluster cluster; - cluster.Associate(device, ZCLendpointId); - return cluster.GetLastNetworkCommissioningResult(nullptr, nullptr, timeoutMs).AsInteger(); -} chip::ChipError::StorageType chip_ime_AppendCommand_NetworkCommissioning_RemoveNetwork(chip::Controller::Device * device, chip::EndpointId ZCLendpointId, chip::GroupId, const uint8_t * networkID, diff --git a/src/controller/python/chip/clusters/CHIPClusters.py b/src/controller/python/chip/clusters/CHIPClusters.py index 55e29308b5a4cd..85e22cc0a4e725 100644 --- a/src/controller/python/chip/clusters/CHIPClusters.py +++ b/src/controller/python/chip/clusters/CHIPClusters.py @@ -2377,13 +2377,6 @@ class ChipClusters: "timeoutMs": "int", }, }, - 0x00000010: { - "commandId": 0x00000010, - "commandName": "GetLastNetworkCommissioningResult", - "args": { - "timeoutMs": "int", - }, - }, 0x0000000A: { "commandId": 0x0000000A, "commandName": "RemoveNetwork", @@ -5103,11 +5096,6 @@ def ClusterNetworkCommissioning_CommandEnableNetwork(self, device: ctypes.c_void networkID), breadcrumb, timeoutMs ) - def ClusterNetworkCommissioning_CommandGetLastNetworkCommissioningResult(self, device: ctypes.c_void_p, ZCLendpoint: int, ZCLgroupid: int, timeoutMs: int): - return self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_GetLastNetworkCommissioningResult( - device, ZCLendpoint, ZCLgroupid, timeoutMs - ) - def ClusterNetworkCommissioning_CommandRemoveNetwork(self, device: ctypes.c_void_p, ZCLendpoint: int, ZCLgroupid: int, networkID: bytes, breadcrumb: int, timeoutMs: int): return self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_RemoveNetwork( device, ZCLendpoint, ZCLgroupid, networkID, len( @@ -8678,10 +8666,6 @@ def InitLib(self, chipLib): self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_EnableNetwork.argtypes = [ ctypes.c_void_p, ctypes.c_uint8, ctypes.c_uint16, ctypes.c_char_p, ctypes.c_uint32, ctypes.c_uint64, ctypes.c_uint32] self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_EnableNetwork.restype = ctypes.c_uint32 - # Cluster NetworkCommissioning Command GetLastNetworkCommissioningResult - self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_GetLastNetworkCommissioningResult.argtypes = [ - ctypes.c_void_p, ctypes.c_uint8, ctypes.c_uint16, ctypes.c_uint32] - self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_GetLastNetworkCommissioningResult.restype = ctypes.c_uint32 # Cluster NetworkCommissioning Command RemoveNetwork self._chipLib.chip_ime_AppendCommand_NetworkCommissioning_RemoveNetwork.argtypes = [ ctypes.c_void_p, ctypes.c_uint8, ctypes.c_uint16, ctypes.c_char_p, ctypes.c_uint32, ctypes.c_uint64, ctypes.c_uint32] diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py index 193d97cfcedd19..bc6b81ad0507e7 100644 --- a/src/controller/python/chip/clusters/Objects.py +++ b/src/controller/python/chip/clusters/Objects.py @@ -6270,22 +6270,6 @@ def descriptor(cls) -> ClusterObjectDescriptor: errorCode: 'uint' = None debugText: 'str' = None - @dataclass - class GetLastNetworkCommissioningResult(ClusterCommand): - cluster_id: typing.ClassVar[int] = 0x0031 - command_id: typing.ClassVar[int] = 0x0010 - is_client: typing.ClassVar[bool] = True - - @ChipUtility.classproperty - def descriptor(cls) -> ClusterObjectDescriptor: - return ClusterObjectDescriptor( - Fields=[ - ClusterObjectFieldDescriptor( - Label="timeoutMs", Tag=0, Type=uint), - ]) - - timeoutMs: 'uint' = None - class Attributes: class FeatureMap(ClusterAttributeDescriptor): @ChipUtility.classproperty diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h index 7471f369156df3..6594a21d791b98 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h @@ -1137,7 +1137,6 @@ NS_ASSUME_NONNULL_BEGIN breadcrumb:(uint64_t)breadcrumb timeoutMs:(uint32_t)timeoutMs responseHandler:(ResponseHandler)responseHandler; -- (void)getLastNetworkCommissioningResult:(uint32_t)timeoutMs responseHandler:(ResponseHandler)responseHandler; - (void)removeNetwork:(NSData *)networkID breadcrumb:(uint64_t)breadcrumb timeoutMs:(uint32_t)timeoutMs diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm index 29d362472d2c5d..a9da41fa0889ee 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm @@ -3370,13 +3370,6 @@ new CHIPNetworkCommissioningClusterEnableNetworkResponseCallbackBridge( }); } -- (void)getLastNetworkCommissioningResult:(uint32_t)timeoutMs responseHandler:(ResponseHandler)responseHandler -{ - new CHIPDefaultSuccessCallbackBridge(self.callbackQueue, responseHandler, ^(Cancelable * success, Cancelable * failure) { - return self.cppCluster.GetLastNetworkCommissioningResult(success, failure, timeoutMs); - }); -} - - (void)removeNetwork:(NSData *)networkID breadcrumb:(uint64_t)breadcrumb timeoutMs:(uint32_t)timeoutMs diff --git a/zzz_generated/all-clusters-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/all-clusters-app/zap-generated/IMClusterCommandHandler.cpp index 427794a4ec3ffa..ae876292017256 100644 --- a/zzz_generated/all-clusters-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/all-clusters-app/zap-generated/IMClusterCommandHandler.cpp @@ -1198,16 +1198,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/app-common/app-common/zap-generated/callback.h b/zzz_generated/app-common/app-common/zap-generated/callback.h index 5b42529b5f0ceb..46522b004b02f2 100644 --- a/zzz_generated/app-common/app-common/zap-generated/callback.h +++ b/zzz_generated/app-common/app-common/zap-generated/callback.h @@ -13038,12 +13038,6 @@ bool emberAfNetworkCommissioningClusterDisableNetworkCallback( bool emberAfNetworkCommissioningClusterDisableNetworkResponseCallback(chip::EndpointId endpoint, chip::app::CommandSender * commandObj, uint8_t errorCode, chip::CharSpan debugText); -/** - * @brief Network Commissioning Cluster GetLastNetworkCommissioningResult Command callback (from client) - */ -bool emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback( - chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, - const chip::app::Clusters::NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::DecodableType & commandData); /** * @brief Diagnostic Logs Cluster RetrieveLogsRequest Command callback (from client) */ diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp index 0e7ec73e83a0b9..46f38bc92b2054 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp @@ -5974,40 +5974,6 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) return CHIP_NO_ERROR; } } // namespace DisableNetworkResponse. -namespace GetLastNetworkCommissioningResult { -CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const -{ - TLV::TLVType outer; - ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer)); - ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kTimeoutMs)), timeoutMs)); - ReturnErrorOnFailure(writer.EndContainer(outer)); - return CHIP_NO_ERROR; -} - -CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) -{ - CHIP_ERROR err = CHIP_NO_ERROR; - TLV::TLVType outer; - VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE); - ReturnErrorOnFailure(reader.EnterContainer(outer)); - while ((err = reader.Next()) == CHIP_NO_ERROR) - { - VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG); - switch (TLV::TagNumFromTag(reader.GetTag())) - { - case to_underlying(Fields::kTimeoutMs): - ReturnErrorOnFailure(DataModel::Decode(reader, timeoutMs)); - break; - default: - break; - } - } - - VerifyOrReturnError(err == CHIP_END_OF_TLV, err); - ReturnErrorOnFailure(reader.ExitContainer(outer)); - return CHIP_NO_ERROR; -} -} // namespace GetLastNetworkCommissioningResult. } // namespace Commands namespace Events { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h index bf41dfaaac471a..0fc32cbd401e24 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h @@ -7445,34 +7445,6 @@ struct DecodableType CHIP_ERROR Decode(TLV::TLVReader & reader); }; }; // namespace DisableNetworkResponse -namespace GetLastNetworkCommissioningResult { -enum class Fields -{ - kTimeoutMs = 0, -}; - -struct Type -{ -public: - // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand - static constexpr CommandId GetCommandId() { return Commands::GetLastNetworkCommissioningResult::Id; } - static constexpr ClusterId GetClusterId() { return Clusters::NetworkCommissioning::Id; } - - uint32_t timeoutMs; - - CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const; -}; - -struct DecodableType -{ -public: - static constexpr CommandId GetCommandId() { return Commands::GetLastNetworkCommissioningResult::Id; } - static constexpr ClusterId GetClusterId() { return Clusters::NetworkCommissioning::Id; } - - uint32_t timeoutMs; - CHIP_ERROR Decode(TLV::TLVReader & reader); -}; -}; // namespace GetLastNetworkCommissioningResult } // namespace Commands namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/command-id.h b/zzz_generated/app-common/app-common/zap-generated/command-id.h index bdce02368eb61d..8b9697b6ba324c 100644 --- a/zzz_generated/app-common/app-common/zap-generated/command-id.h +++ b/zzz_generated/app-common/app-common/zap-generated/command-id.h @@ -197,7 +197,6 @@ #define ZCL_ENABLE_NETWORK_RESPONSE_COMMAND_ID (0x0D) #define ZCL_DISABLE_NETWORK_COMMAND_ID (0x0E) #define ZCL_DISABLE_NETWORK_RESPONSE_COMMAND_ID (0x0F) -#define ZCL_GET_LAST_NETWORK_COMMISSIONING_RESULT_COMMAND_ID (0x10) // Commands for cluster: Diagnostic Logs #define ZCL_RETRIEVE_LOGS_REQUEST_COMMAND_ID (0x00) diff --git a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h index 01bacb1bd0ce73..182884edcdadee 100644 --- a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h +++ b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h @@ -658,10 +658,6 @@ namespace DisableNetworkResponse { static constexpr CommandId Id = 0x0000000F; } // namespace DisableNetworkResponse -namespace GetLastNetworkCommissioningResult { -static constexpr CommandId Id = 0x00000010; -} // namespace GetLastNetworkCommissioningResult - } // namespace Commands } // namespace NetworkCommissioning diff --git a/zzz_generated/bridge-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/bridge-app/zap-generated/IMClusterCommandHandler.cpp index b8fcb88a73d458..b2c6ddff88e13e 100644 --- a/zzz_generated/bridge-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/bridge-app/zap-generated/IMClusterCommandHandler.cpp @@ -357,16 +357,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h index c6ff59a19029a3..93a55d60662dd1 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h @@ -14588,7 +14588,6 @@ class ReadModeSelectClusterRevision : public ModelCommand | * AddWiFiNetwork | 0x02 | | * DisableNetwork | 0x0E | | * EnableNetwork | 0x0C | -| * GetLastNetworkCommissioningResult | 0x10 | | * RemoveNetwork | 0x0A | | * ScanNetworks | 0x00 | | * UpdateThreadNetwork | 0x08 | @@ -14708,31 +14707,6 @@ class NetworkCommissioningEnableNetwork : public ModelCommand chip::app::Clusters::NetworkCommissioning::Commands::EnableNetwork::Type mRequest; }; -/* - * Command GetLastNetworkCommissioningResult - */ -class NetworkCommissioningGetLastNetworkCommissioningResult : public ModelCommand -{ -public: - NetworkCommissioningGetLastNetworkCommissioningResult() : ModelCommand("get-last-network-commissioning-result") - { - AddArgument("TimeoutMs", 0, UINT32_MAX, &mRequest.timeoutMs); - ModelCommand::AddArguments(); - } - - CHIP_ERROR SendCommand(ChipDevice * device, uint8_t endpointId) override - { - ChipLogProgress(chipTool, "Sending cluster (0x00000031) command (0x00000010) on endpoint %" PRIu8, endpointId); - - chip::Controller::NetworkCommissioningCluster cluster; - cluster.Associate(device, endpointId); - return cluster.InvokeCommand(mRequest, this, OnDefaultSuccess, OnDefaultFailure); - } - -private: - chip::app::Clusters::NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::Type mRequest; -}; - /* * Command RemoveNetwork */ @@ -28027,17 +28001,16 @@ void registerClusterNetworkCommissioning(Commands & commands) const char * clusterName = "NetworkCommissioning"; commands_list clusterCommands = { - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // - make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // + make_unique(), // }; commands.Register(clusterName, clusterCommands); diff --git a/zzz_generated/controller-clusters/zap-generated/CHIPClusters.cpp b/zzz_generated/controller-clusters/zap-generated/CHIPClusters.cpp index 98b27a2047edb0..453a63e66885fa 100644 --- a/zzz_generated/controller-clusters/zap-generated/CHIPClusters.cpp +++ b/zzz_generated/controller-clusters/zap-generated/CHIPClusters.cpp @@ -8262,49 +8262,6 @@ CHIP_ERROR NetworkCommissioningCluster::EnableNetwork(Callback::Cancelable * onS return err; } -CHIP_ERROR NetworkCommissioningCluster::GetLastNetworkCommissioningResult(Callback::Cancelable * onSuccessCallback, - Callback::Cancelable * onFailureCallback, - uint32_t timeoutMs) -{ - CHIP_ERROR err = CHIP_NO_ERROR; - TLV::TLVWriter * writer = nullptr; - uint8_t argSeqNumber = 0; - - // Used when encoding non-empty command. Suppress error message when encoding empty commands. - (void) writer; - (void) argSeqNumber; - - VerifyOrReturnError(mDevice != nullptr, CHIP_ERROR_INCORRECT_STATE); - - app::CommandPathParams cmdParams = { mEndpoint, /* group id */ 0, mClusterId, - NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::Id, - (app::CommandPathFlags::kEndpointIdValid) }; - - CommandSenderHandle sender( - Platform::New(mDevice->GetInteractionModelDelegate(), mDevice->GetExchangeManager())); - - VerifyOrReturnError(sender != nullptr, CHIP_ERROR_NO_MEMORY); - - SuccessOrExit(err = sender->PrepareCommand(cmdParams)); - - VerifyOrExit((writer = sender->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); - // timeoutMs: int32u - SuccessOrExit(err = writer->Put(TLV::ContextTag(argSeqNumber++), timeoutMs)); - - SuccessOrExit(err = sender->FinishCommand()); - - // #6308: This is a temporary solution before we fully support IM on application side and should be replaced by IMDelegate. - mDevice->AddIMResponseHandler(sender.get(), onSuccessCallback, onFailureCallback); - - SuccessOrExit(err = mDevice->SendCommands(sender.get())); - - // We have successfully sent the command, and the callback handler will be responsible to free the object, release the object - // now. - sender.release(); -exit: - return err; -} - CHIP_ERROR NetworkCommissioningCluster::RemoveNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs) diff --git a/zzz_generated/controller-clusters/zap-generated/CHIPClusters.h b/zzz_generated/controller-clusters/zap-generated/CHIPClusters.h index c0ca67bc29a45e..2b487e70bfc34b 100644 --- a/zzz_generated/controller-clusters/zap-generated/CHIPClusters.h +++ b/zzz_generated/controller-clusters/zap-generated/CHIPClusters.h @@ -959,8 +959,6 @@ class DLL_EXPORT NetworkCommissioningCluster : public ClusterBase chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); CHIP_ERROR EnableNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); - CHIP_ERROR GetLastNetworkCommissioningResult(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, - uint32_t timeoutMs); CHIP_ERROR RemoveNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); CHIP_ERROR ScanNetworks(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan ssid, diff --git a/zzz_generated/controller-clusters/zap-generated/CHIPClustersInvoke.cpp b/zzz_generated/controller-clusters/zap-generated/CHIPClustersInvoke.cpp index 1c31d4daf0bfa2..3549c92db7084d 100644 --- a/zzz_generated/controller-clusters/zap-generated/CHIPClustersInvoke.cpp +++ b/zzz_generated/controller-clusters/zap-generated/CHIPClustersInvoke.cpp @@ -670,12 +670,6 @@ ClusterBase::InvokeCommand, CommandResponseFailureCallback); -template CHIP_ERROR -ClusterBase::InvokeCommand( - const chip::app::Clusters::NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::Type &, void *, - CommandResponseSuccessCallback, CommandResponseFailureCallback); - template CHIP_ERROR ClusterBase::InvokeCommand( diff --git a/zzz_generated/lighting-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/lighting-app/zap-generated/IMClusterCommandHandler.cpp index a9ce61037e183a..3f9448fbc71805 100644 --- a/zzz_generated/lighting-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/lighting-app/zap-generated/IMClusterCommandHandler.cpp @@ -598,16 +598,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/lock-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/lock-app/zap-generated/IMClusterCommandHandler.cpp index e07cb335cc771e..96de6025e1ac59 100644 --- a/zzz_generated/lock-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/lock-app/zap-generated/IMClusterCommandHandler.cpp @@ -255,16 +255,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/ota-provider-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/ota-provider-app/zap-generated/IMClusterCommandHandler.cpp index a4517146947837..9ffc417766c69e 100644 --- a/zzz_generated/ota-provider-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/ota-provider-app/zap-generated/IMClusterCommandHandler.cpp @@ -156,16 +156,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/ota-requestor-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/ota-requestor-app/zap-generated/IMClusterCommandHandler.cpp index a47c8edd61dbe1..4ce300b05aac68 100644 --- a/zzz_generated/ota-requestor-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/ota-requestor-app/zap-generated/IMClusterCommandHandler.cpp @@ -156,16 +156,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/pump-controller-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/pump-controller-app/zap-generated/IMClusterCommandHandler.cpp index 3c090783bd5702..199373d627dd6e 100644 --- a/zzz_generated/pump-controller-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/pump-controller-app/zap-generated/IMClusterCommandHandler.cpp @@ -264,16 +264,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/temperature-measurement-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/temperature-measurement-app/zap-generated/IMClusterCommandHandler.cpp index 8dd429aa029eee..a47f49b3591c3f 100644 --- a/zzz_generated/temperature-measurement-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/temperature-measurement-app/zap-generated/IMClusterCommandHandler.cpp @@ -246,16 +246,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/thermostat/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/thermostat/zap-generated/IMClusterCommandHandler.cpp index 1645a70b7c3cf1..22ae47395baee1 100644 --- a/zzz_generated/thermostat/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/thermostat/zap-generated/IMClusterCommandHandler.cpp @@ -543,16 +543,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/tv-app/zap-generated/CHIPClusters.cpp b/zzz_generated/tv-app/zap-generated/CHIPClusters.cpp index ec1ef2ba87a429..5d5427b630f3a9 100644 --- a/zzz_generated/tv-app/zap-generated/CHIPClusters.cpp +++ b/zzz_generated/tv-app/zap-generated/CHIPClusters.cpp @@ -312,49 +312,6 @@ CHIP_ERROR NetworkCommissioningCluster::EnableNetwork(Callback::Cancelable * onS return err; } -CHIP_ERROR NetworkCommissioningCluster::GetLastNetworkCommissioningResult(Callback::Cancelable * onSuccessCallback, - Callback::Cancelable * onFailureCallback, - uint32_t timeoutMs) -{ - CHIP_ERROR err = CHIP_NO_ERROR; - TLV::TLVWriter * writer = nullptr; - uint8_t argSeqNumber = 0; - - // Used when encoding non-empty command. Suppress error message when encoding empty commands. - (void) writer; - (void) argSeqNumber; - - VerifyOrReturnError(mDevice != nullptr, CHIP_ERROR_INCORRECT_STATE); - - app::CommandPathParams cmdParams = { mEndpoint, /* group id */ 0, mClusterId, - NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::Id, - (app::CommandPathFlags::kEndpointIdValid) }; - - CommandSenderHandle sender( - Platform::New(mDevice->GetInteractionModelDelegate(), mDevice->GetExchangeManager())); - - VerifyOrReturnError(sender != nullptr, CHIP_ERROR_NO_MEMORY); - - SuccessOrExit(err = sender->PrepareCommand(cmdParams)); - - VerifyOrExit((writer = sender->GetCommandDataIBTLVWriter()) != nullptr, err = CHIP_ERROR_INCORRECT_STATE); - // timeoutMs: int32u - SuccessOrExit(err = writer->Put(TLV::ContextTag(argSeqNumber++), timeoutMs)); - - SuccessOrExit(err = sender->FinishCommand()); - - // #6308: This is a temporary solution before we fully support IM on application side and should be replaced by IMDelegate. - mDevice->AddIMResponseHandler(sender.get(), onSuccessCallback, onFailureCallback); - - SuccessOrExit(err = mDevice->SendCommands(sender.get())); - - // We have successfully sent the command, and the callback handler will be responsible to free the object, release the object - // now. - sender.release(); -exit: - return err; -} - CHIP_ERROR NetworkCommissioningCluster::RemoveNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs) diff --git a/zzz_generated/tv-app/zap-generated/CHIPClusters.h b/zzz_generated/tv-app/zap-generated/CHIPClusters.h index 96ad36df895876..2a8d7fd071f975 100644 --- a/zzz_generated/tv-app/zap-generated/CHIPClusters.h +++ b/zzz_generated/tv-app/zap-generated/CHIPClusters.h @@ -65,8 +65,6 @@ class DLL_EXPORT NetworkCommissioningCluster : public ClusterBase chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); CHIP_ERROR EnableNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); - CHIP_ERROR GetLastNetworkCommissioningResult(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, - uint32_t timeoutMs); CHIP_ERROR RemoveNetwork(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan networkID, uint64_t breadcrumb, uint32_t timeoutMs); CHIP_ERROR ScanNetworks(Callback::Cancelable * onSuccessCallback, Callback::Cancelable * onFailureCallback, chip::ByteSpan ssid, diff --git a/zzz_generated/tv-app/zap-generated/CHIPClustersInvoke.cpp b/zzz_generated/tv-app/zap-generated/CHIPClustersInvoke.cpp index 639acebad3b823..5d37300058cb47 100644 --- a/zzz_generated/tv-app/zap-generated/CHIPClustersInvoke.cpp +++ b/zzz_generated/tv-app/zap-generated/CHIPClustersInvoke.cpp @@ -66,12 +66,6 @@ ClusterBase::InvokeCommand, CommandResponseFailureCallback); -template CHIP_ERROR -ClusterBase::InvokeCommand( - const chip::app::Clusters::NetworkCommissioning::Commands::GetLastNetworkCommissioningResult::Type &, void *, - CommandResponseSuccessCallback, CommandResponseFailureCallback); - template CHIP_ERROR ClusterBase::InvokeCommand( diff --git a/zzz_generated/tv-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/tv-app/zap-generated/IMClusterCommandHandler.cpp index a680bf54539f2f..48487d87cf0693 100644 --- a/zzz_generated/tv-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/tv-app/zap-generated/IMClusterCommandHandler.cpp @@ -1694,16 +1694,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/tv-casting-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/tv-casting-app/zap-generated/IMClusterCommandHandler.cpp index 9b33cc38890aa1..7bf8fdf7772c36 100644 --- a/zzz_generated/tv-casting-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/tv-casting-app/zap-generated/IMClusterCommandHandler.cpp @@ -1026,16 +1026,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData); diff --git a/zzz_generated/window-app/zap-generated/IMClusterCommandHandler.cpp b/zzz_generated/window-app/zap-generated/IMClusterCommandHandler.cpp index f80703d91709ad..423fc9646c30ae 100644 --- a/zzz_generated/window-app/zap-generated/IMClusterCommandHandler.cpp +++ b/zzz_generated/window-app/zap-generated/IMClusterCommandHandler.cpp @@ -216,16 +216,6 @@ void DispatchServerCommand(CommandHandler * apCommandObj, const ConcreteCommandP } break; } - case Commands::GetLastNetworkCommissioningResult::Id: { - Commands::GetLastNetworkCommissioningResult::DecodableType commandData; - TLVError = DataModel::Decode(aDataTlv, commandData); - if (TLVError == CHIP_NO_ERROR) - { - wasHandled = emberAfNetworkCommissioningClusterGetLastNetworkCommissioningResultCallback(apCommandObj, aCommandPath, - commandData); - } - break; - } case Commands::RemoveNetwork::Id: { Commands::RemoveNetwork::DecodableType commandData; TLVError = DataModel::Decode(aDataTlv, commandData);