From 3efb8e4e5ab29b27c54ce591634f111e2c81a8a1 Mon Sep 17 00:00:00 2001 From: mkardous-silabs <84793247+mkardous-silabs@users.noreply.github.com> Date: Fri, 3 Nov 2023 17:07:56 -0400 Subject: [PATCH 01/11] [ICD] Add LIT ICD reference app for tests and certification (#30092) * Initial example creation * intial clean up * update build.gb * update build configs * correct build.gn * Add example to CI * zap regen * update linux targets * Add default config for user active trigger * remove clusters that shouldn't be on endpoint 0 * fix device conformance --- .github/workflows/darwin-tests.yaml | 1 + .github/workflows/examples-linux-arm.yaml | 1 + examples/lit-icd-app/linux/.gn | 25 + examples/lit-icd-app/linux/BUILD.gn | 42 + examples/lit-icd-app/linux/Dockerfile | 23 + examples/lit-icd-app/linux/args.gni | 30 + examples/lit-icd-app/linux/build_overrides | 1 + examples/lit-icd-app/linux/entrypoint.sh | 29 + .../linux/include/CHIPProjectAppConfig.h | 42 + examples/lit-icd-app/linux/main.cpp | 40 + .../linux/third_party/connectedhomeip | 1 + examples/lit-icd-app/lit-icd-common/BUILD.gn | 24 + .../lit-icd-common/lit-icd-server-app.matter | 1563 ++++++++ .../lit-icd-common/lit-icd-server-app.zap | 3569 +++++++++++++++++ scripts/build/build/targets.py | 1 + scripts/build/builders/host.py | 6 + .../build/testdata/all_targets_linux_x64.txt | 2 +- 17 files changed, 5399 insertions(+), 1 deletion(-) create mode 100644 examples/lit-icd-app/linux/.gn create mode 100644 examples/lit-icd-app/linux/BUILD.gn create mode 100644 examples/lit-icd-app/linux/Dockerfile create mode 100644 examples/lit-icd-app/linux/args.gni create mode 120000 examples/lit-icd-app/linux/build_overrides create mode 100755 examples/lit-icd-app/linux/entrypoint.sh create mode 100644 examples/lit-icd-app/linux/include/CHIPProjectAppConfig.h create mode 100644 examples/lit-icd-app/linux/main.cpp create mode 120000 examples/lit-icd-app/linux/third_party/connectedhomeip create mode 100644 examples/lit-icd-app/lit-icd-common/BUILD.gn create mode 100644 examples/lit-icd-app/lit-icd-common/lit-icd-server-app.matter create mode 100644 examples/lit-icd-app/lit-icd-common/lit-icd-server-app.zap diff --git a/.github/workflows/darwin-tests.yaml b/.github/workflows/darwin-tests.yaml index 7afef91f345f4d..74d2f7e32deb0f 100644 --- a/.github/workflows/darwin-tests.yaml +++ b/.github/workflows/darwin-tests.yaml @@ -98,6 +98,7 @@ jobs: --target darwin-x64-ota-requestor-${BUILD_VARIANT} \ --target darwin-x64-tv-app-${BUILD_VARIANT} \ --target darwin-x64-bridge-${BUILD_VARIANT} \ + --target darwin-x64-lit-icd-${BUILD_VARIANT} \ build \ --copy-artifacts-to objdir-clone \ " diff --git a/.github/workflows/examples-linux-arm.yaml b/.github/workflows/examples-linux-arm.yaml index 4ef5edd01cc5ce..f0f62060f0930e 100644 --- a/.github/workflows/examples-linux-arm.yaml +++ b/.github/workflows/examples-linux-arm.yaml @@ -64,6 +64,7 @@ jobs: --target linux-arm64-minmdns-clang \ --target linux-arm64-light-rpc-ipv6only-clang \ --target linux-arm64-thermostat-no-ble-clang \ + --target linux-arm64-lit-icd-no-ble-clang \ build \ " - name: Bloat report - chip-tool diff --git a/examples/lit-icd-app/linux/.gn b/examples/lit-icd-app/linux/.gn new file mode 100644 index 00000000000000..5d1ce757507582 --- /dev/null +++ b/examples/lit-icd-app/linux/.gn @@ -0,0 +1,25 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") + +# The location of the build configuration file. +buildconfig = "${build_root}/config/BUILDCONFIG.gn" + +# CHIP uses angle bracket includes. +check_system_includes = true + +default_args = { + import("//args.gni") +} diff --git a/examples/lit-icd-app/linux/BUILD.gn b/examples/lit-icd-app/linux/BUILD.gn new file mode 100644 index 00000000000000..6a2a26c7b8a034 --- /dev/null +++ b/examples/lit-icd-app/linux/BUILD.gn @@ -0,0 +1,42 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/build.gni") +import("//build_overrides/chip.gni") + +executable("lit-icd-app") { + sources = [ "main.cpp" ] + + deps = [ + "${chip_root}/examples/lit-icd-app/lit-icd-common", + "${chip_root}/examples/platform/linux:app-main", + "${chip_root}/src/app/icd:manager", + "${chip_root}/src/lib", + "${chip_root}/third_party/jsoncpp", + ] + + include_dirs = [ "include" ] + + cflags = [ "-Wconversion" ] + + output_dir = root_out_dir +} + +group("linux") { + deps = [ ":lit-icd-app" ] +} + +group("default") { + deps = [ ":linux" ] +} diff --git a/examples/lit-icd-app/linux/Dockerfile b/examples/lit-icd-app/linux/Dockerfile new file mode 100644 index 00000000000000..0ed4d3035b6455 --- /dev/null +++ b/examples/lit-icd-app/linux/Dockerfile @@ -0,0 +1,23 @@ +# +# Copyright (c) 2020 Project CHIP Authors +# All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +from generic_node_image +RUN apt-get install -y libglib2.0 +COPY out/debug/lit-icd-app /usr/bin/ +COPY entrypoint.sh / + +ENTRYPOINT ["/entrypoint.sh", "server"] diff --git a/examples/lit-icd-app/linux/args.gni b/examples/lit-icd-app/linux/args.gni new file mode 100644 index 00000000000000..50691e9c530522 --- /dev/null +++ b/examples/lit-icd-app/linux/args.gni @@ -0,0 +1,30 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") + +import("${chip_root}/config/standalone/args.gni") + +chip_device_project_config_include = "" +chip_project_config_include = "" +chip_system_project_config_include = "" + +chip_project_config_include_dirs = + [ "${chip_root}/examples/lit-icd-app/linux/include" ] +chip_project_config_include_dirs += [ "${chip_root}/config/standalone" ] +matter_enable_tracing_support = true + +# ICD configurations +chip_enable_icd_server = true +chip_subscription_timeout_resumption = false diff --git a/examples/lit-icd-app/linux/build_overrides b/examples/lit-icd-app/linux/build_overrides new file mode 120000 index 00000000000000..e578e73312ebd1 --- /dev/null +++ b/examples/lit-icd-app/linux/build_overrides @@ -0,0 +1 @@ +../../build_overrides \ No newline at end of file diff --git a/examples/lit-icd-app/linux/entrypoint.sh b/examples/lit-icd-app/linux/entrypoint.sh new file mode 100755 index 00000000000000..db8bda19153e07 --- /dev/null +++ b/examples/lit-icd-app/linux/entrypoint.sh @@ -0,0 +1,29 @@ +#!/usr/bin/env bash + +# +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +set -ex + +service dbus start +sleep 1 +/usr/sbin/otbr-agent -I wpan0 spinel+hdlc+uart:///dev/ttyUSB0 & +sleep 1 +ot-ctl panid 0x1234 +ot-ctl ifconfig up +ot-ctl thread start + +lit-icd-app diff --git a/examples/lit-icd-app/linux/include/CHIPProjectAppConfig.h b/examples/lit-icd-app/linux/include/CHIPProjectAppConfig.h new file mode 100644 index 00000000000000..60cf9dfd7324b5 --- /dev/null +++ b/examples/lit-icd-app/linux/include/CHIPProjectAppConfig.h @@ -0,0 +1,42 @@ +/* + * + * Copyright (c) 2022 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * Example project configuration file for CHIP. + * + * This is a place to put application or project-specific overrides + * to the default configuration values for general CHIP features. + * + */ + +#pragma once + +// include the CHIPProjectConfig from config/standalone +#include + +// Allows app options (ports) to be configured on launch of app +#define CHIP_DEVICE_ENABLE_PORT_PARAMS 1 + +// Enable subscriptions synchronization +#define CHIP_CONFIG_SYNCHRONOUS_REPORTS_ENABLED 1 + +// ICD configurations +#define CHIP_CONFIG_ICD_IDLE_MODE_DURATION_SEC 3600 +#define CHIP_CONFIG_ICD_ACTIVE_MODE_DURATION_MS 10000 +#define CHIP_CONFIG_ICD_ACTIVE_MODE_THRESHOLD_MS 1000 diff --git a/examples/lit-icd-app/linux/main.cpp b/examples/lit-icd-app/linux/main.cpp new file mode 100644 index 00000000000000..1f4031af407d42 --- /dev/null +++ b/examples/lit-icd-app/linux/main.cpp @@ -0,0 +1,40 @@ +/* + * + * Copyright (c) 2020 Project CHIP Authors + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "AppMain.h" +#include + +using namespace chip; +using namespace chip::app; + +void ApplicationInit() {} + +void ApplicationShutdown() {} + +int main(int argc, char * argv[]) +{ + VerifyOrDie(ChipLinuxAppInit(argc, argv) == 0); + ChipLinuxAppMainLoop(); + return 0; +} + +void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & attributePath, uint8_t type, uint16_t size, + uint8_t * value) +{ + // TODO: Watch ICDM Cluster changes +} diff --git a/examples/lit-icd-app/linux/third_party/connectedhomeip b/examples/lit-icd-app/linux/third_party/connectedhomeip new file mode 120000 index 00000000000000..11a54ed360106c --- /dev/null +++ b/examples/lit-icd-app/linux/third_party/connectedhomeip @@ -0,0 +1 @@ +../../../../ \ No newline at end of file diff --git a/examples/lit-icd-app/lit-icd-common/BUILD.gn b/examples/lit-icd-app/lit-icd-common/BUILD.gn new file mode 100644 index 00000000000000..a20d519c1cd7fa --- /dev/null +++ b/examples/lit-icd-app/lit-icd-common/BUILD.gn @@ -0,0 +1,24 @@ +# Copyright (c) 2020 Project CHIP Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import("//build_overrides/chip.gni") +import("${chip_root}/src/app/chip_data_model.gni") + +chip_data_model("lit-icd-common") { + zap_file = "lit-icd-server-app.zap" + + zap_pregenerated_dir = + "${chip_root}/zzz_generated/lit-icd-server-app/zap-generated" + is_server = true +} diff --git a/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.matter b/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.matter new file mode 100644 index 00000000000000..204c4bb8f10412 --- /dev/null +++ b/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.matter @@ -0,0 +1,1563 @@ +// This IDL was generated automatically by ZAP. +// It is for view/code review purposes only. + +/** Attributes and commands for putting a device into Identification mode (e.g. flashing a light). */ +server cluster Identify = 3 { + enum EffectIdentifierEnum : enum8 { + kBlink = 0; + kBreathe = 1; + kOkay = 2; + kChannelChange = 11; + kFinishEffect = 254; + kStopEffect = 255; + } + + enum EffectVariantEnum : enum8 { + kDefault = 0; + } + + enum IdentifyTypeEnum : enum8 { + kNone = 0; + kLightOutput = 1; + kVisibleIndicator = 2; + kAudibleBeep = 3; + kDisplay = 4; + kActuator = 5; + } + + attribute int16u identifyTime = 0; + readonly attribute IdentifyTypeEnum identifyType = 1; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct IdentifyRequest { + int16u identifyTime = 0; + } + + command access(invoke: manage) Identify(IdentifyRequest): DefaultSuccess = 0; +} + +/** The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. */ +server cluster Descriptor = 29 { + bitmap Feature : bitmap32 { + kTagList = 0x1; + } + + struct DeviceTypeStruct { + devtype_id deviceType = 0; + int16u revision = 1; + } + + struct SemanticTagStruct { + nullable vendor_id mfgCode = 0; + enum8 namespaceID = 1; + enum8 tag = 2; + optional nullable char_string label = 3; + } + + readonly attribute DeviceTypeStruct deviceTypeList[] = 0; + readonly attribute cluster_id serverList[] = 1; + readonly attribute cluster_id clientList[] = 2; + readonly attribute endpoint_no partsList[] = 3; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** The Access Control Cluster exposes a data model view of a + Node's Access Control List (ACL), which codifies the rules used to manage + and enforce Access Control for the Node's endpoints and their associated + cluster instances. */ +server cluster AccessControl = 31 { + enum AccessControlEntryAuthModeEnum : enum8 { + kPASE = 1; + kCASE = 2; + kGroup = 3; + } + + enum AccessControlEntryPrivilegeEnum : enum8 { + kView = 1; + kProxyView = 2; + kOperate = 3; + kManage = 4; + kAdminister = 5; + } + + enum ChangeTypeEnum : enum8 { + kChanged = 0; + kAdded = 1; + kRemoved = 2; + } + + struct AccessControlTargetStruct { + nullable cluster_id cluster = 0; + nullable endpoint_no endpoint = 1; + nullable devtype_id deviceType = 2; + } + + fabric_scoped struct AccessControlEntryStruct { + fabric_sensitive AccessControlEntryPrivilegeEnum privilege = 1; + fabric_sensitive AccessControlEntryAuthModeEnum authMode = 2; + nullable fabric_sensitive int64u subjects[] = 3; + nullable fabric_sensitive AccessControlTargetStruct targets[] = 4; + fabric_idx fabricIndex = 254; + } + + fabric_scoped struct AccessControlExtensionStruct { + fabric_sensitive octet_string<128> data = 1; + fabric_idx fabricIndex = 254; + } + + fabric_sensitive info event access(read: administer) AccessControlEntryChanged = 0 { + nullable node_id adminNodeID = 1; + nullable int16u adminPasscodeID = 2; + ChangeTypeEnum changeType = 3; + nullable AccessControlEntryStruct latestValue = 4; + fabric_idx fabricIndex = 254; + } + + fabric_sensitive info event access(read: administer) AccessControlExtensionChanged = 1 { + nullable node_id adminNodeID = 1; + nullable int16u adminPasscodeID = 2; + ChangeTypeEnum changeType = 3; + nullable AccessControlExtensionStruct latestValue = 4; + fabric_idx fabricIndex = 254; + } + + attribute access(read: administer, write: administer) AccessControlEntryStruct acl[] = 0; + attribute access(read: administer, write: administer) AccessControlExtensionStruct extension[] = 1; + readonly attribute int16u subjectsPerAccessControlEntry = 2; + readonly attribute int16u targetsPerAccessControlEntry = 3; + readonly attribute int16u accessControlEntriesPerFabric = 4; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** This cluster provides attributes and events for determining basic information about Nodes, which supports both + Commissioning and operational determination of Node characteristics, such as Vendor ID, Product ID and serial number, + which apply to the whole Node. Also allows setting user device information such as location. */ +server cluster BasicInformation = 40 { + enum ColorEnum : enum8 { + kBlack = 0; + kNavy = 1; + kGreen = 2; + kTeal = 3; + kMaroon = 4; + kPurple = 5; + kOlive = 6; + kGray = 7; + kBlue = 8; + kLime = 9; + kAqua = 10; + kRed = 11; + kFuchsia = 12; + kYellow = 13; + kWhite = 14; + kNickel = 15; + kChrome = 16; + kBrass = 17; + kCopper = 18; + kSilver = 19; + kGold = 20; + } + + enum ProductFinishEnum : enum8 { + kOther = 0; + kMatte = 1; + kSatin = 2; + kPolished = 3; + kRugged = 4; + kFabric = 5; + } + + struct CapabilityMinimaStruct { + int16u caseSessionsPerFabric = 0; + int16u subscriptionsPerFabric = 1; + } + + struct ProductAppearanceStruct { + ProductFinishEnum finish = 0; + nullable ColorEnum primaryColor = 1; + } + + critical event StartUp = 0 { + int32u softwareVersion = 0; + } + + critical event ShutDown = 1 { + } + + info event Leave = 2 { + fabric_idx fabricIndex = 0; + } + + info event ReachableChanged = 3 { + boolean reachableNewValue = 0; + } + + readonly attribute int16u dataModelRevision = 0; + readonly attribute char_string<32> vendorName = 1; + readonly attribute vendor_id vendorID = 2; + readonly attribute char_string<32> productName = 3; + readonly attribute int16u productID = 4; + attribute access(write: manage) char_string<32> nodeLabel = 5; + attribute access(write: administer) char_string<2> location = 6; + readonly attribute int16u hardwareVersion = 7; + readonly attribute char_string<64> hardwareVersionString = 8; + readonly attribute int32u softwareVersion = 9; + readonly attribute char_string<64> softwareVersionString = 10; + readonly attribute CapabilityMinimaStruct capabilityMinima = 19; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** Provides an interface for providing OTA software updates */ +client cluster OtaSoftwareUpdateProvider = 41 { + enum ApplyUpdateActionEnum : enum8 { + kProceed = 0; + kAwaitNextAction = 1; + kDiscontinue = 2; + } + + enum DownloadProtocolEnum : enum8 { + kBDXSynchronous = 0; + kBDXAsynchronous = 1; + kHTTPS = 2; + kVendorSpecific = 3; + } + + enum StatusEnum : enum8 { + kUpdateAvailable = 0; + kBusy = 1; + kNotAvailable = 2; + kDownloadProtocolNotSupported = 3; + } + + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct QueryImageRequest { + vendor_id vendorID = 0; + int16u productID = 1; + int32u softwareVersion = 2; + DownloadProtocolEnum protocolsSupported[] = 3; + optional int16u hardwareVersion = 4; + optional char_string<2> location = 5; + optional boolean requestorCanConsent = 6; + optional octet_string<512> metadataForProvider = 7; + } + + response struct QueryImageResponse = 1 { + StatusEnum status = 0; + optional int32u delayedActionTime = 1; + optional char_string<256> imageURI = 2; + optional int32u softwareVersion = 3; + optional char_string<64> softwareVersionString = 4; + optional octet_string<32> updateToken = 5; + optional boolean userConsentNeeded = 6; + optional octet_string<512> metadataForRequestor = 7; + } + + request struct ApplyUpdateRequestRequest { + octet_string<32> updateToken = 0; + int32u newVersion = 1; + } + + response struct ApplyUpdateResponse = 3 { + ApplyUpdateActionEnum action = 0; + int32u delayedActionTime = 1; + } + + request struct NotifyUpdateAppliedRequest { + octet_string<32> updateToken = 0; + int32u softwareVersion = 1; + } + + /** Determine availability of a new Software Image */ + command QueryImage(QueryImageRequest): QueryImageResponse = 0; + /** Determine next action to take for a downloaded Software Image */ + command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2; + /** Notify OTA Provider that an update was applied */ + command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4; +} + +/** Provides an interface for downloading and applying OTA software updates */ +server cluster OtaSoftwareUpdateRequestor = 42 { + enum AnnouncementReasonEnum : enum8 { + kSimpleAnnouncement = 0; + kUpdateAvailable = 1; + kUrgentUpdateAvailable = 2; + } + + enum ChangeReasonEnum : enum8 { + kUnknown = 0; + kSuccess = 1; + kFailure = 2; + kTimeOut = 3; + kDelayByProvider = 4; + } + + enum UpdateStateEnum : enum8 { + kUnknown = 0; + kIdle = 1; + kQuerying = 2; + kDelayedOnQuery = 3; + kDownloading = 4; + kApplying = 5; + kDelayedOnApply = 6; + kRollingBack = 7; + kDelayedOnUserConsent = 8; + } + + fabric_scoped struct ProviderLocation { + node_id providerNodeID = 1; + endpoint_no endpoint = 2; + fabric_idx fabricIndex = 254; + } + + info event StateTransition = 0 { + UpdateStateEnum previousState = 0; + UpdateStateEnum newState = 1; + ChangeReasonEnum reason = 2; + nullable int32u targetSoftwareVersion = 3; + } + + critical event VersionApplied = 1 { + int32u softwareVersion = 0; + int16u productID = 1; + } + + info event DownloadError = 2 { + int32u softwareVersion = 0; + int64u bytesDownloaded = 1; + nullable int8u progressPercent = 2; + nullable int64s platformCode = 3; + } + + attribute ProviderLocation defaultOTAProviders[] = 0; + readonly attribute boolean updatePossible = 1; + readonly attribute UpdateStateEnum updateState = 2; + readonly attribute nullable int8u updateStateProgress = 3; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct AnnounceOTAProviderRequest { + node_id providerNodeID = 0; + vendor_id vendorID = 1; + AnnouncementReasonEnum announcementReason = 2; + optional octet_string<512> metadataForNode = 3; + endpoint_no endpoint = 4; + } + + command AnnounceOTAProvider(AnnounceOTAProviderRequest): DefaultSuccess = 0; +} + +/** Nodes should be expected to be deployed to any and all regions of the world. These global regions + may have differing preferences for the units in which values are conveyed in communication to a + user. As such, Nodes that visually or audibly convey measurable values to the user need a + mechanism by which they can be configured to use a user’s preferred unit. */ +server cluster UnitLocalization = 45 { + enum TempUnitEnum : enum8 { + kFahrenheit = 0; + kCelsius = 1; + kKelvin = 2; + } + + bitmap Feature : bitmap32 { + kTemperatureUnit = 0x1; + } + + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** This cluster is used to manage global aspects of the Commissioning flow. */ +server cluster GeneralCommissioning = 48 { + enum CommissioningErrorEnum : enum8 { + kOK = 0; + kValueOutsideRange = 1; + kInvalidAuthentication = 2; + kNoFailSafe = 3; + kBusyWithOtherAdmin = 4; + } + + enum RegulatoryLocationTypeEnum : enum8 { + kIndoor = 0; + kOutdoor = 1; + kIndoorOutdoor = 2; + } + + struct BasicCommissioningInfo { + int16u failSafeExpiryLengthSeconds = 0; + int16u maxCumulativeFailsafeSeconds = 1; + } + + attribute access(write: administer) int64u breadcrumb = 0; + readonly attribute BasicCommissioningInfo basicCommissioningInfo = 1; + readonly attribute RegulatoryLocationTypeEnum regulatoryConfig = 2; + readonly attribute RegulatoryLocationTypeEnum locationCapability = 3; + readonly attribute boolean supportsConcurrentConnection = 4; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct ArmFailSafeRequest { + int16u expiryLengthSeconds = 0; + int64u breadcrumb = 1; + } + + request struct SetRegulatoryConfigRequest { + RegulatoryLocationTypeEnum newRegulatoryConfig = 0; + char_string countryCode = 1; + int64u breadcrumb = 2; + } + + response struct ArmFailSafeResponse = 1 { + CommissioningErrorEnum errorCode = 0; + char_string debugText = 1; + } + + response struct SetRegulatoryConfigResponse = 3 { + CommissioningErrorEnum errorCode = 0; + char_string debugText = 1; + } + + response struct CommissioningCompleteResponse = 5 { + CommissioningErrorEnum errorCode = 0; + char_string debugText = 1; + } + + command access(invoke: administer) ArmFailSafe(ArmFailSafeRequest): ArmFailSafeResponse = 0; + command access(invoke: administer) SetRegulatoryConfig(SetRegulatoryConfigRequest): SetRegulatoryConfigResponse = 2; + fabric command access(invoke: administer) CommissioningComplete(): CommissioningCompleteResponse = 4; +} + +/** Functionality to configure, enable, disable network credentials and access on a Matter device. */ +server cluster NetworkCommissioning = 49 { + enum NetworkCommissioningStatusEnum : enum8 { + kSuccess = 0; + kOutOfRange = 1; + kBoundsExceeded = 2; + kNetworkIDNotFound = 3; + kDuplicateNetworkID = 4; + kNetworkNotFound = 5; + kRegulatoryError = 6; + kAuthFailure = 7; + kUnsupportedSecurity = 8; + kOtherConnectionFailure = 9; + kIPV6Failed = 10; + kIPBindFailed = 11; + kUnknownError = 12; + } + + enum WiFiBandEnum : enum8 { + k2G4 = 0; + k3G65 = 1; + k5G = 2; + k6G = 3; + k60G = 4; + k1G = 5; + } + + bitmap Feature : bitmap32 { + kWiFiNetworkInterface = 0x1; + kThreadNetworkInterface = 0x2; + kEthernetNetworkInterface = 0x4; + } + + bitmap ThreadCapabilitiesBitmap : bitmap16 { + kIsBorderRouterCapable = 0x1; + kIsRouterCapable = 0x2; + kIsSleepyEndDeviceCapable = 0x4; + kIsFullThreadDevice = 0x8; + kIsSynchronizedSleepyEndDeviceCapable = 0x10; + } + + bitmap WiFiSecurityBitmap : bitmap8 { + kUnencrypted = 0x1; + kWEP = 0x2; + kWPAPersonal = 0x4; + kWPA2Personal = 0x8; + kWPA3Personal = 0x10; + } + + struct NetworkInfoStruct { + octet_string<32> networkID = 0; + boolean connected = 1; + } + + struct ThreadInterfaceScanResultStruct { + int16u panId = 0; + int64u extendedPanId = 1; + char_string<16> networkName = 2; + int16u channel = 3; + int8u version = 4; + octet_string<8> extendedAddress = 5; + int8s rssi = 6; + int8u lqi = 7; + } + + struct WiFiInterfaceScanResultStruct { + WiFiSecurityBitmap security = 0; + octet_string<32> ssid = 1; + octet_string<6> bssid = 2; + int16u channel = 3; + WiFiBandEnum wiFiBand = 4; + int8s rssi = 5; + } + + readonly attribute access(read: administer) int8u maxNetworks = 0; + readonly attribute access(read: administer) NetworkInfoStruct networks[] = 1; + readonly attribute int8u scanMaxTimeSeconds = 2; + readonly attribute int8u connectMaxTimeSeconds = 3; + attribute access(write: administer) boolean interfaceEnabled = 4; + readonly attribute access(read: administer) nullable NetworkCommissioningStatusEnum lastNetworkingStatus = 5; + readonly attribute access(read: administer) nullable octet_string<32> lastNetworkID = 6; + readonly attribute access(read: administer) nullable int32s lastConnectErrorValue = 7; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct ScanNetworksRequest { + optional nullable octet_string<32> ssid = 0; + optional int64u breadcrumb = 1; + } + + request struct AddOrUpdateWiFiNetworkRequest { + octet_string<32> ssid = 0; + octet_string<64> credentials = 1; + optional int64u breadcrumb = 2; + } + + request struct AddOrUpdateThreadNetworkRequest { + octet_string<254> operationalDataset = 0; + optional int64u breadcrumb = 1; + } + + request struct RemoveNetworkRequest { + octet_string<32> networkID = 0; + optional int64u breadcrumb = 1; + } + + request struct ConnectNetworkRequest { + octet_string<32> networkID = 0; + optional int64u breadcrumb = 1; + } + + request struct ReorderNetworkRequest { + octet_string<32> networkID = 0; + int8u networkIndex = 1; + optional int64u breadcrumb = 2; + } + + response struct ScanNetworksResponse = 1 { + NetworkCommissioningStatusEnum networkingStatus = 0; + optional char_string debugText = 1; + optional WiFiInterfaceScanResultStruct wiFiScanResults[] = 2; + optional ThreadInterfaceScanResultStruct threadScanResults[] = 3; + } + + response struct NetworkConfigResponse = 5 { + NetworkCommissioningStatusEnum networkingStatus = 0; + optional char_string<512> debugText = 1; + optional int8u networkIndex = 2; + } + + response struct ConnectNetworkResponse = 7 { + NetworkCommissioningStatusEnum networkingStatus = 0; + optional char_string debugText = 1; + nullable int32s errorValue = 2; + } + + command access(invoke: administer) ScanNetworks(ScanNetworksRequest): ScanNetworksResponse = 0; + command access(invoke: administer) AddOrUpdateWiFiNetwork(AddOrUpdateWiFiNetworkRequest): NetworkConfigResponse = 2; + command access(invoke: administer) AddOrUpdateThreadNetwork(AddOrUpdateThreadNetworkRequest): NetworkConfigResponse = 3; + command access(invoke: administer) RemoveNetwork(RemoveNetworkRequest): NetworkConfigResponse = 4; + command access(invoke: administer) ConnectNetwork(ConnectNetworkRequest): ConnectNetworkResponse = 6; + command access(invoke: administer) ReorderNetwork(ReorderNetworkRequest): NetworkConfigResponse = 8; +} + +/** The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ +server cluster GeneralDiagnostics = 51 { + enum BootReasonEnum : enum8 { + kUnspecified = 0; + kPowerOnReboot = 1; + kBrownOutReset = 2; + kSoftwareWatchdogReset = 3; + kHardwareWatchdogReset = 4; + kSoftwareUpdateCompleted = 5; + kSoftwareReset = 6; + } + + enum HardwareFaultEnum : enum8 { + kUnspecified = 0; + kRadio = 1; + kSensor = 2; + kResettableOverTemp = 3; + kNonResettableOverTemp = 4; + kPowerSource = 5; + kVisualDisplayFault = 6; + kAudioOutputFault = 7; + kUserInterfaceFault = 8; + kNonVolatileMemoryError = 9; + kTamperDetected = 10; + } + + enum InterfaceTypeEnum : enum8 { + kUnspecified = 0; + kWiFi = 1; + kEthernet = 2; + kCellular = 3; + kThread = 4; + } + + enum NetworkFaultEnum : enum8 { + kUnspecified = 0; + kHardwareFailure = 1; + kNetworkJammed = 2; + kConnectionFailed = 3; + } + + enum RadioFaultEnum : enum8 { + kUnspecified = 0; + kWiFiFault = 1; + kCellularFault = 2; + kThreadFault = 3; + kNFCFault = 4; + kBLEFault = 5; + kEthernetFault = 6; + } + + struct NetworkInterface { + char_string<32> name = 0; + boolean isOperational = 1; + nullable boolean offPremiseServicesReachableIPv4 = 2; + nullable boolean offPremiseServicesReachableIPv6 = 3; + octet_string<8> hardwareAddress = 4; + octet_string IPv4Addresses[] = 5; + octet_string IPv6Addresses[] = 6; + InterfaceTypeEnum type = 7; + } + + critical event HardwareFaultChange = 0 { + HardwareFaultEnum current[] = 0; + HardwareFaultEnum previous[] = 1; + } + + critical event RadioFaultChange = 1 { + RadioFaultEnum current[] = 0; + RadioFaultEnum previous[] = 1; + } + + critical event NetworkFaultChange = 2 { + NetworkFaultEnum current[] = 0; + NetworkFaultEnum previous[] = 1; + } + + critical event BootReason = 3 { + BootReasonEnum bootReason = 0; + } + + readonly attribute NetworkInterface networkInterfaces[] = 0; + readonly attribute int16u rebootCount = 1; + readonly attribute boolean testEventTriggersEnabled = 8; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct TestEventTriggerRequest { + octet_string<16> enableKey = 0; + int64u eventTrigger = 1; + } + + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; +} + +/** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ +server cluster ThreadNetworkDiagnostics = 53 { + enum ConnectionStatusEnum : enum8 { + kConnected = 0; + kNotConnected = 1; + } + + enum NetworkFaultEnum : enum8 { + kUnspecified = 0; + kLinkDown = 1; + kHardwareFailure = 2; + kNetworkJammed = 3; + } + + enum RoutingRoleEnum : enum8 { + kUnspecified = 0; + kUnassigned = 1; + kSleepyEndDevice = 2; + kEndDevice = 3; + kREED = 4; + kRouter = 5; + kLeader = 6; + } + + bitmap Feature : bitmap32 { + kPacketCounts = 0x1; + kErrorCounts = 0x2; + kMLECounts = 0x4; + kMACCounts = 0x8; + } + + struct NeighborTableStruct { + int64u extAddress = 0; + int32u age = 1; + int16u rloc16 = 2; + int32u linkFrameCounter = 3; + int32u mleFrameCounter = 4; + int8u lqi = 5; + nullable int8s averageRssi = 6; + nullable int8s lastRssi = 7; + int8u frameErrorRate = 8; + int8u messageErrorRate = 9; + boolean rxOnWhenIdle = 10; + boolean fullThreadDevice = 11; + boolean fullNetworkData = 12; + boolean isChild = 13; + } + + struct OperationalDatasetComponents { + boolean activeTimestampPresent = 0; + boolean pendingTimestampPresent = 1; + boolean masterKeyPresent = 2; + boolean networkNamePresent = 3; + boolean extendedPanIdPresent = 4; + boolean meshLocalPrefixPresent = 5; + boolean delayPresent = 6; + boolean panIdPresent = 7; + boolean channelPresent = 8; + boolean pskcPresent = 9; + boolean securityPolicyPresent = 10; + boolean channelMaskPresent = 11; + } + + struct RouteTableStruct { + int64u extAddress = 0; + int16u rloc16 = 1; + int8u routerId = 2; + int8u nextHop = 3; + int8u pathCost = 4; + int8u LQIIn = 5; + int8u LQIOut = 6; + int8u age = 7; + boolean allocated = 8; + boolean linkEstablished = 9; + } + + struct SecurityPolicy { + int16u rotationTime = 0; + int16u flags = 1; + } + + info event ConnectionStatus = 0 { + ConnectionStatusEnum connectionStatus = 0; + } + + info event NetworkFaultChange = 1 { + NetworkFaultEnum current[] = 0; + NetworkFaultEnum previous[] = 1; + } + + readonly attribute nullable int16u channel = 0; + readonly attribute nullable RoutingRoleEnum routingRole = 1; + readonly attribute nullable char_string<16> networkName = 2; + readonly attribute nullable int16u panId = 3; + readonly attribute nullable int64u extendedPanId = 4; + readonly attribute nullable octet_string<17> meshLocalPrefix = 5; + readonly attribute NeighborTableStruct neighborTable[] = 7; + readonly attribute RouteTableStruct routeTable[] = 8; + readonly attribute nullable int32u partitionId = 9; + readonly attribute nullable int16u weighting = 10; + readonly attribute nullable int16u dataVersion = 11; + readonly attribute nullable int16u stableDataVersion = 12; + readonly attribute nullable int8u leaderRouterId = 13; + readonly attribute nullable SecurityPolicy securityPolicy = 59; + readonly attribute nullable octet_string<4> channelPage0Mask = 60; + readonly attribute nullable OperationalDatasetComponents operationalDatasetComponents = 61; + readonly attribute NetworkFaultEnum activeNetworkFaultsList[] = 62; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ +server cluster WiFiNetworkDiagnostics = 54 { + enum AssociationFailureCauseEnum : enum8 { + kUnknown = 0; + kAssociationFailed = 1; + kAuthenticationFailed = 2; + kSsidNotFound = 3; + } + + enum ConnectionStatusEnum : enum8 { + kConnected = 0; + kNotConnected = 1; + } + + enum SecurityTypeEnum : enum8 { + kUnspecified = 0; + kNone = 1; + kWEP = 2; + kWPA = 3; + kWPA2 = 4; + kWPA3 = 5; + } + + enum WiFiVersionEnum : enum8 { + kA = 0; + kB = 1; + kG = 2; + kN = 3; + kAc = 4; + kAx = 5; + kAh = 6; + } + + bitmap Feature : bitmap32 { + kPacketCounts = 0x1; + kErrorCounts = 0x2; + } + + info event Disconnection = 0 { + int16u reasonCode = 0; + } + + info event AssociationFailure = 1 { + AssociationFailureCauseEnum associationFailureCause = 0; + int16u status = 1; + } + + info event ConnectionStatus = 2 { + ConnectionStatusEnum connectionStatus = 0; + } + + readonly attribute nullable octet_string<6> bssid = 0; + readonly attribute nullable SecurityTypeEnum securityType = 1; + readonly attribute nullable WiFiVersionEnum wiFiVersion = 2; + readonly attribute nullable int16u channelNumber = 3; + readonly attribute nullable int8s rssi = 4; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ +server cluster EthernetNetworkDiagnostics = 55 { + enum PHYRateEnum : enum8 { + kRate10M = 0; + kRate100M = 1; + kRate1G = 2; + kRate25G = 3; + kRate5G = 4; + kRate10G = 5; + kRate40G = 6; + kRate100G = 7; + kRate200G = 8; + kRate400G = 9; + } + + bitmap Feature : bitmap32 { + kPacketCounts = 0x1; + kErrorCounts = 0x2; + } + + readonly attribute nullable PHYRateEnum PHYRate = 0; + readonly attribute nullable boolean fullDuplex = 1; + readonly attribute int64u packetRxCount = 2; + readonly attribute int64u packetTxCount = 3; + readonly attribute int64u txErrCount = 4; + readonly attribute int64u collisionCount = 5; + readonly attribute int64u overrunCount = 6; + readonly attribute nullable boolean carrierDetect = 7; + readonly attribute int64u timeSinceReset = 8; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + command access(invoke: manage) ResetCounts(): DefaultSuccess = 0; +} + +/** Commands to trigger a Node to allow a new Administrator to commission it. */ +server cluster AdministratorCommissioning = 60 { + enum CommissioningWindowStatusEnum : enum8 { + kWindowNotOpen = 0; + kEnhancedWindowOpen = 1; + kBasicWindowOpen = 2; + } + + enum StatusCode : enum8 { + kBusy = 2; + kPAKEParameterError = 3; + kWindowNotOpen = 4; + } + + bitmap Feature : bitmap32 { + kBasic = 0x1; + } + + readonly attribute CommissioningWindowStatusEnum windowStatus = 0; + readonly attribute nullable fabric_idx adminFabricIndex = 1; + readonly attribute nullable vendor_id adminVendorId = 2; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct OpenCommissioningWindowRequest { + int16u commissioningTimeout = 0; + octet_string PAKEPasscodeVerifier = 1; + int16u discriminator = 2; + int32u iterations = 3; + octet_string<32> salt = 4; + } + + timed command access(invoke: administer) OpenCommissioningWindow(OpenCommissioningWindowRequest): DefaultSuccess = 0; + timed command access(invoke: administer) RevokeCommissioning(): DefaultSuccess = 2; +} + +/** This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated Fabrics. */ +server cluster OperationalCredentials = 62 { + enum CertificateChainTypeEnum : enum8 { + kDACCertificate = 1; + kPAICertificate = 2; + } + + enum NodeOperationalCertStatusEnum : enum8 { + kOK = 0; + kInvalidPublicKey = 1; + kInvalidNodeOpId = 2; + kInvalidNOC = 3; + kMissingCsr = 4; + kTableFull = 5; + kInvalidAdminSubject = 6; + kFabricConflict = 9; + kLabelConflict = 10; + kInvalidFabricIndex = 11; + } + + fabric_scoped struct FabricDescriptorStruct { + octet_string<65> rootPublicKey = 1; + vendor_id vendorID = 2; + fabric_id fabricID = 3; + node_id nodeID = 4; + char_string<32> label = 5; + fabric_idx fabricIndex = 254; + } + + fabric_scoped struct NOCStruct { + fabric_sensitive octet_string noc = 1; + nullable fabric_sensitive octet_string icac = 2; + fabric_idx fabricIndex = 254; + } + + readonly attribute access(read: administer) NOCStruct NOCs[] = 0; + readonly attribute FabricDescriptorStruct fabrics[] = 1; + readonly attribute int8u supportedFabrics = 2; + readonly attribute int8u commissionedFabrics = 3; + readonly attribute octet_string trustedRootCertificates[] = 4; + readonly attribute int8u currentFabricIndex = 5; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct AttestationRequestRequest { + octet_string<32> attestationNonce = 0; + } + + request struct CertificateChainRequestRequest { + CertificateChainTypeEnum certificateType = 0; + } + + request struct CSRRequestRequest { + octet_string<32> CSRNonce = 0; + optional boolean isForUpdateNOC = 1; + } + + request struct AddNOCRequest { + octet_string<400> NOCValue = 0; + optional octet_string<400> ICACValue = 1; + octet_string<16> IPKValue = 2; + int64u caseAdminSubject = 3; + vendor_id adminVendorId = 4; + } + + request struct UpdateNOCRequest { + octet_string NOCValue = 0; + optional octet_string ICACValue = 1; + } + + request struct UpdateFabricLabelRequest { + char_string<32> label = 0; + } + + request struct RemoveFabricRequest { + fabric_idx fabricIndex = 0; + } + + request struct AddTrustedRootCertificateRequest { + octet_string rootCACertificate = 0; + } + + response struct AttestationResponse = 1 { + octet_string<900> attestationElements = 0; + octet_string<64> attestationSignature = 1; + } + + response struct CertificateChainResponse = 3 { + octet_string<600> certificate = 0; + } + + response struct CSRResponse = 5 { + octet_string NOCSRElements = 0; + octet_string attestationSignature = 1; + } + + response struct NOCResponse = 8 { + NodeOperationalCertStatusEnum statusCode = 0; + optional fabric_idx fabricIndex = 1; + optional char_string<128> debugText = 2; + } + + command access(invoke: administer) AttestationRequest(AttestationRequestRequest): AttestationResponse = 0; + command access(invoke: administer) CertificateChainRequest(CertificateChainRequestRequest): CertificateChainResponse = 2; + command access(invoke: administer) CSRRequest(CSRRequestRequest): CSRResponse = 4; + command access(invoke: administer) AddNOC(AddNOCRequest): NOCResponse = 6; + fabric command access(invoke: administer) UpdateNOC(UpdateNOCRequest): NOCResponse = 7; + fabric command access(invoke: administer) UpdateFabricLabel(UpdateFabricLabelRequest): NOCResponse = 9; + command access(invoke: administer) RemoveFabric(RemoveFabricRequest): NOCResponse = 10; + command access(invoke: administer) AddTrustedRootCertificate(AddTrustedRootCertificateRequest): DefaultSuccess = 11; +} + +/** The Group Key Management Cluster is the mechanism by which group keys are managed. */ +server cluster GroupKeyManagement = 63 { + enum GroupKeySecurityPolicyEnum : enum8 { + kTrustFirst = 0; + kCacheAndSync = 1; + } + + bitmap Feature : bitmap32 { + kCacheAndSync = 0x1; + } + + fabric_scoped struct GroupInfoMapStruct { + group_id groupId = 1; + endpoint_no endpoints[] = 2; + optional char_string<16> groupName = 3; + fabric_idx fabricIndex = 254; + } + + fabric_scoped struct GroupKeyMapStruct { + group_id groupId = 1; + int16u groupKeySetID = 2; + fabric_idx fabricIndex = 254; + } + + struct GroupKeySetStruct { + int16u groupKeySetID = 0; + GroupKeySecurityPolicyEnum groupKeySecurityPolicy = 1; + nullable octet_string<16> epochKey0 = 2; + nullable epoch_us epochStartTime0 = 3; + nullable octet_string<16> epochKey1 = 4; + nullable epoch_us epochStartTime1 = 5; + nullable octet_string<16> epochKey2 = 6; + nullable epoch_us epochStartTime2 = 7; + } + + attribute access(write: manage) GroupKeyMapStruct groupKeyMap[] = 0; + readonly attribute GroupInfoMapStruct groupTable[] = 1; + readonly attribute int16u maxGroupsPerFabric = 2; + readonly attribute int16u maxGroupKeysPerFabric = 3; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct KeySetWriteRequest { + GroupKeySetStruct groupKeySet = 0; + } + + request struct KeySetReadRequest { + int16u groupKeySetID = 0; + } + + request struct KeySetRemoveRequest { + int16u groupKeySetID = 0; + } + + response struct KeySetReadResponse = 2 { + GroupKeySetStruct groupKeySet = 0; + } + + response struct KeySetReadAllIndicesResponse = 5 { + int16u groupKeySetIDs[] = 0; + } + + fabric command access(invoke: administer) KeySetWrite(KeySetWriteRequest): DefaultSuccess = 0; + fabric command access(invoke: administer) KeySetRead(KeySetReadRequest): KeySetReadResponse = 1; + fabric command access(invoke: administer) KeySetRemove(KeySetRemoveRequest): DefaultSuccess = 3; + fabric command access(invoke: administer) KeySetReadAllIndices(): KeySetReadAllIndicesResponse = 4; +} + +/** The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only +labels. */ +server cluster FixedLabel = 64 { + struct LabelStruct { + char_string<16> label = 0; + char_string<16> value = 1; + } + + readonly attribute LabelStruct labelList[] = 0; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** The User Label Cluster provides a feature to tag an endpoint with zero or more labels. */ +server cluster UserLabel = 65 { + struct LabelStruct { + char_string<16> label = 0; + char_string<16> value = 1; + } + + attribute access(write: manage) LabelStruct labelList[] = 0; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; +} + +/** Allows servers to ensure that listed clients are notified when a server is available for communication. */ +server cluster IcdManagement = 70 { + bitmap Feature : bitmap32 { + kCheckInProtocolSupport = 0x1; + kUserActiveModeTrigger = 0x2; + kLongIdleTimeSupport = 0x4; + } + + bitmap UserActiveModeTriggerBitmap : bitmap32 { + kPowerCycle = 0x1; + kSettingsMenu = 0x2; + kCustomInstruction = 0x4; + kDeviceManual = 0x8; + kActuateSensor = 0x10; + kActuateSensorSeconds = 0x20; + kActuateSensorTimes = 0x40; + kActuateSensorLightsBlink = 0x80; + kResetButton = 0x100; + kResetButtonLightsBlink = 0x200; + kResetButtonSeconds = 0x400; + kResetButtonTimes = 0x800; + kSetupButton = 0x1000; + kSetupButtonSeconds = 0x2000; + kSetupButtonLightsBlink = 0x4000; + kSetupButtonTimes = 0x8000; + kAppDefinedButton = 0x10000; + } + + fabric_scoped struct MonitoringRegistrationStruct { + fabric_sensitive node_id checkInNodeID = 1; + fabric_sensitive int64u monitoredSubject = 2; + fabric_idx fabricIndex = 254; + } + + readonly attribute int32u idleModeDuration = 0; + readonly attribute int32u activeModeDuration = 1; + readonly attribute int16u activeModeThreshold = 2; + readonly attribute access(read: administer) MonitoringRegistrationStruct registeredClients[] = 3; + readonly attribute access(read: administer) int32u ICDCounter = 4; + readonly attribute int16u clientsSupportedPerFabric = 5; + readonly attribute UserActiveModeTriggerBitmap userActiveModeTriggerHint = 6; + readonly attribute char_string<128> userActiveModeTriggerInstruction = 7; + readonly attribute command_id generatedCommandList[] = 65528; + readonly attribute command_id acceptedCommandList[] = 65529; + readonly attribute event_id eventList[] = 65530; + readonly attribute attrib_id attributeList[] = 65531; + readonly attribute bitmap32 featureMap = 65532; + readonly attribute int16u clusterRevision = 65533; + + request struct RegisterClientRequest { + node_id checkInNodeID = 0; + int64u monitoredSubject = 1; + octet_string<16> key = 2; + optional octet_string<16> verificationKey = 3; + } + + request struct UnregisterClientRequest { + node_id checkInNodeID = 0; + optional octet_string<16> verificationKey = 1; + } + + response struct RegisterClientResponse = 1 { + int32u ICDCounter = 0; + } + + fabric command access(invoke: manage) RegisterClient(RegisterClientRequest): RegisterClientResponse = 0; + fabric command access(invoke: manage) UnregisterClient(UnregisterClientRequest): DefaultSuccess = 2; +} + +endpoint 0 { + device type ma_rootdevice = 22, version 1; + device type ma_powersource = 17, version 1; + + binding cluster OtaSoftwareUpdateProvider; + + server cluster Identify { + ram attribute identifyTime default = 0x0000; + ram attribute identifyType default = 0x0; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 4; + + handle command Identify; + } + + server cluster Descriptor { + callback attribute deviceTypeList; + callback attribute serverList; + callback attribute clientList; + callback attribute partsList; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + callback attribute clusterRevision default = 1; + } + + server cluster AccessControl { + emits event AccessControlEntryChanged; + callback attribute acl; + callback attribute extension; + callback attribute subjectsPerAccessControlEntry default = 4; + callback attribute targetsPerAccessControlEntry default = 3; + callback attribute accessControlEntriesPerFabric default = 4; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + callback attribute clusterRevision default = 1; + } + + server cluster BasicInformation { + emits event StartUp; + callback attribute dataModelRevision default = 10; + callback attribute vendorName; + callback attribute vendorID; + callback attribute productName; + callback attribute productID; + persist attribute nodeLabel; + callback attribute location default = "XX"; + callback attribute hardwareVersion default = 0; + callback attribute hardwareVersionString; + callback attribute softwareVersion default = 0; + callback attribute softwareVersionString; + callback attribute capabilityMinima; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 2; + } + + server cluster OtaSoftwareUpdateRequestor { + emits event StateTransition; + emits event VersionApplied; + emits event DownloadError; + callback attribute defaultOTAProviders default = 0; + ram attribute updatePossible default = 1; + ram attribute updateState default = 0; + ram attribute updateStateProgress default = 0; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + + handle command AnnounceOTAProvider; + } + + server cluster UnitLocalization { + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + } + + server cluster GeneralCommissioning { + ram attribute breadcrumb default = 0x0000000000000000; + callback attribute basicCommissioningInfo; + callback attribute regulatoryConfig default = 0; + callback attribute locationCapability default = 0; + callback attribute supportsConcurrentConnection default = 1; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + + handle command ArmFailSafe; + handle command ArmFailSafeResponse; + handle command SetRegulatoryConfig; + handle command SetRegulatoryConfigResponse; + handle command CommissioningComplete; + handle command CommissioningCompleteResponse; + } + + server cluster NetworkCommissioning { + ram attribute maxNetworks; + callback attribute networks; + ram attribute scanMaxTimeSeconds; + ram attribute connectMaxTimeSeconds; + ram attribute interfaceEnabled; + ram attribute lastNetworkingStatus; + ram attribute lastNetworkID; + ram attribute lastConnectErrorValue; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 2; + ram attribute clusterRevision default = 1; + + handle command ScanNetworks; + handle command ScanNetworksResponse; + handle command AddOrUpdateWiFiNetwork; + handle command AddOrUpdateThreadNetwork; + handle command RemoveNetwork; + handle command NetworkConfigResponse; + handle command ConnectNetwork; + handle command ConnectNetworkResponse; + handle command ReorderNetwork; + } + + server cluster GeneralDiagnostics { + callback attribute networkInterfaces; + callback attribute rebootCount default = 0x0000; + callback attribute testEventTriggersEnabled; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + + handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; + } + + server cluster ThreadNetworkDiagnostics { + callback attribute channel; + callback attribute routingRole; + callback attribute networkName default = "0"; + callback attribute panId default = 0x0000; + callback attribute extendedPanId default = 0x0000000000000000; + callback attribute meshLocalPrefix; + callback attribute neighborTable; + callback attribute routeTable; + callback attribute partitionId; + callback attribute weighting; + callback attribute dataVersion; + callback attribute stableDataVersion; + callback attribute leaderRouterId; + callback attribute securityPolicy; + callback attribute channelPage0Mask default = "0x0000"; + callback attribute operationalDatasetComponents; + callback attribute activeNetworkFaultsList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + } + + server cluster WiFiNetworkDiagnostics { + callback attribute bssid; + callback attribute securityType; + callback attribute wiFiVersion; + callback attribute channelNumber default = 0x0000; + callback attribute rssi default = 0x00; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + } + + server cluster EthernetNetworkDiagnostics { + callback attribute PHYRate; + callback attribute fullDuplex default = 0x00; + callback attribute packetRxCount default = 0x0000000000000000; + callback attribute packetTxCount default = 0x0000000000000000; + callback attribute txErrCount default = 0x0000000000000000; + callback attribute collisionCount default = 0x0000000000000000; + callback attribute overrunCount default = 0x0000000000000000; + callback attribute carrierDetect default = 0x00; + callback attribute timeSinceReset default = 0x0000000000000000; + ram attribute featureMap default = 3; + ram attribute clusterRevision default = 1; + + handle command ResetCounts; + } + + server cluster AdministratorCommissioning { + callback attribute windowStatus default = 0; + callback attribute adminFabricIndex default = 1; + callback attribute adminVendorId default = 0; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + + handle command OpenCommissioningWindow; + handle command RevokeCommissioning; + } + + server cluster OperationalCredentials { + callback attribute NOCs; + callback attribute fabrics; + callback attribute supportedFabrics; + callback attribute commissionedFabrics; + callback attribute trustedRootCertificates; + callback attribute currentFabricIndex; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + + handle command AttestationRequest; + handle command AttestationResponse; + handle command CertificateChainRequest; + handle command CertificateChainResponse; + handle command CSRRequest; + handle command CSRResponse; + handle command AddNOC; + handle command UpdateNOC; + handle command NOCResponse; + handle command UpdateFabricLabel; + handle command RemoveFabric; + handle command AddTrustedRootCertificate; + } + + server cluster GroupKeyManagement { + callback attribute groupKeyMap; + callback attribute groupTable; + callback attribute maxGroupsPerFabric; + callback attribute maxGroupKeysPerFabric; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + callback attribute featureMap default = 0; + callback attribute clusterRevision default = 1; + + handle command KeySetWrite; + handle command KeySetRead; + handle command KeySetReadResponse; + handle command KeySetRemove; + handle command KeySetReadAllIndices; + handle command KeySetReadAllIndicesResponse; + } + + server cluster FixedLabel { + callback attribute labelList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + } + + server cluster UserLabel { + callback attribute labelList; + ram attribute featureMap default = 0; + ram attribute clusterRevision default = 1; + } + + server cluster IcdManagement { + callback attribute idleModeDuration default = 1; + callback attribute activeModeDuration default = 300; + callback attribute activeModeThreshold default = 300; + callback attribute registeredClients; + callback attribute ICDCounter default = 0; + callback attribute clientsSupportedPerFabric default = 2; + callback attribute userActiveModeTriggerHint default = 5; + callback attribute userActiveModeTriggerInstruction default = "This is a test"; + callback attribute generatedCommandList; + callback attribute acceptedCommandList; + callback attribute eventList; + callback attribute attributeList; + ram attribute featureMap default = 0x0007; + ram attribute clusterRevision default = 2; + + handle command RegisterClient; + handle command RegisterClientResponse; + handle command UnregisterClient; + } +} + + diff --git a/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.zap b/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.zap new file mode 100644 index 00000000000000..fa168ff6d61a1f --- /dev/null +++ b/examples/lit-icd-app/lit-icd-common/lit-icd-server-app.zap @@ -0,0 +1,3569 @@ +{ + "fileFormat": 2, + "featureLevel": 99, + "creator": "zap", + "keyValuePairs": [ + { + "key": "commandDiscovery", + "value": "1" + }, + { + "key": "defaultResponsePolicy", + "value": "always" + }, + { + "key": "manufacturerCodes", + "value": "0x1002" + } + ], + "package": [ + { + "pathRelativity": "relativeToZap", + "path": "../../../src/app/zap-templates/zcl/zcl.json", + "type": "zcl-properties", + "category": "matter", + "version": 1, + "description": "Matter SDK ZCL data" + }, + { + "pathRelativity": "relativeToZap", + "path": "../../../src/app/zap-templates/app-templates.json", + "type": "gen-templates-json", + "version": "chip-v1" + } + ], + "endpointTypes": [ + { + "id": 1, + "name": "MA-rootdevice", + "deviceTypeRef": { + "code": 17, + "profileId": 259, + "label": "MA-powersource", + "name": "MA-powersource" + }, + "deviceTypes": [ + { + "code": 17, + "profileId": 259, + "label": "MA-powersource", + "name": "MA-powersource" + }, + { + "code": 22, + "profileId": 259, + "label": "MA-rootdevice", + "name": "MA-rootdevice" + } + ], + "deviceVersions": [ + 1, + 1 + ], + "deviceIdentifiers": [ + 17, + 22 + ], + "deviceTypeName": "MA-powersource", + "deviceTypeCode": 17, + "deviceTypeProfileId": 259, + "clusters": [ + { + "name": "Identify", + "code": 3, + "mfgCode": null, + "define": "IDENTIFY_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "Identify", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "IdentifyTime", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "IdentifyType", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "IdentifyTypeEnum", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "4", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Descriptor", + "code": 29, + "mfgCode": null, + "define": "DESCRIPTOR_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "DeviceTypeList", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ServerList", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ClientList", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "PartsList", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Access Control", + "code": 31, + "mfgCode": null, + "define": "ACCESS_CONTROL_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "ACL", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "Extension", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "SubjectsPerAccessControlEntry", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "4", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "TargetsPerAccessControlEntry", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "3", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AccessControlEntriesPerFabric", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "4", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + } + ], + "events": [ + { + "name": "AccessControlEntryChanged", + "code": 0, + "mfgCode": null, + "side": "server", + "included": 1 + } + ] + }, + { + "name": "Basic Information", + "code": 40, + "mfgCode": null, + "define": "BASIC_INFORMATION_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "DataModelRevision", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "10", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "VendorName", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "VendorID", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "vendor_id", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ProductName", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ProductID", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "NodeLabel", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "NVM", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "Location", + "code": 6, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "XX", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "HardwareVersion", + "code": 7, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "HardwareVersionString", + "code": 8, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "SoftwareVersion", + "code": 9, + "mfgCode": null, + "side": "server", + "type": "int32u", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "SoftwareVersionString", + "code": 10, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "CapabilityMinima", + "code": 19, + "mfgCode": null, + "side": "server", + "type": "CapabilityMinimaStruct", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 1, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 1, + "bounded": 0, + "defaultValue": "2", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ], + "events": [ + { + "name": "StartUp", + "code": 0, + "mfgCode": null, + "side": "server", + "included": 1 + } + ] + }, + { + "name": "OTA Software Update Provider", + "code": 41, + "mfgCode": null, + "define": "OTA_SOFTWARE_UPDATE_PROVIDER_CLUSTER", + "side": "client", + "enabled": 1, + "commands": [ + { + "name": "QueryImage", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "ApplyUpdateRequest", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "ApplyUpdateResponse", + "code": 3, + "mfgCode": null, + "source": "server", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "NotifyUpdateApplied", + "code": 4, + "mfgCode": null, + "source": "client", + "isIncoming": 0, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "client", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "OTA Software Update Requestor", + "code": 42, + "mfgCode": null, + "define": "OTA_SOFTWARE_UPDATE_REQUESTOR_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "AnnounceOTAProvider", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "DefaultOTAProviders", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "UpdatePossible", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "UpdateState", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "UpdateStateEnum", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "UpdateStateProgress", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ], + "events": [ + { + "name": "StateTransition", + "code": 0, + "mfgCode": null, + "side": "server", + "included": 1 + }, + { + "name": "VersionApplied", + "code": 1, + "mfgCode": null, + "side": "server", + "included": 1 + }, + { + "name": "DownloadError", + "code": 2, + "mfgCode": null, + "side": "server", + "included": 1 + } + ] + }, + { + "name": "Unit Localization", + "code": 45, + "mfgCode": null, + "define": "UNIT_LOCALIZATION_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + } + ] + }, + { + "name": "General Commissioning", + "code": 48, + "mfgCode": null, + "define": "GENERAL_COMMISSIONING_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "ArmFailSafe", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "ArmFailSafeResponse", + "code": 1, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "SetRegulatoryConfig", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "SetRegulatoryConfigResponse", + "code": 3, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "CommissioningComplete", + "code": 4, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "CommissioningCompleteResponse", + "code": 5, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "Breadcrumb", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "BasicCommissioningInfo", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "BasicCommissioningInfo", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "RegulatoryConfig", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "RegulatoryLocationTypeEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "LocationCapability", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "RegulatoryLocationTypeEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "SupportsConcurrentConnection", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Network Commissioning", + "code": 49, + "mfgCode": null, + "define": "NETWORK_COMMISSIONING_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "ScanNetworks", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "ScanNetworksResponse", + "code": 1, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "AddOrUpdateWiFiNetwork", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "AddOrUpdateThreadNetwork", + "code": 3, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "RemoveNetwork", + "code": 4, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "NetworkConfigResponse", + "code": 5, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "ConnectNetwork", + "code": 6, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "ConnectNetworkResponse", + "code": 7, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "ReorderNetwork", + "code": 8, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "MaxNetworks", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "Networks", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ScanMaxTimeSeconds", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ConnectMaxTimeSeconds", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "InterfaceEnabled", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "LastNetworkingStatus", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "NetworkCommissioningStatusEnum", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "LastNetworkID", + "code": 6, + "mfgCode": null, + "side": "server", + "type": "octet_string", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "LastConnectErrorValue", + "code": 7, + "mfgCode": null, + "side": "server", + "type": "int32s", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "2", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "General Diagnostics", + "code": 51, + "mfgCode": null, + "define": "GENERAL_DIAGNOSTICS_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "TestEventTrigger", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "NetworkInterfaces", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "RebootCount", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "TestEventTriggersEnabled", + "code": 8, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Thread Network Diagnostics", + "code": 53, + "mfgCode": null, + "define": "THREAD_NETWORK_DIAGNOSTICS_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "Channel", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "RoutingRole", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "RoutingRoleEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "NetworkName", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "PanId", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ExtendedPanId", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "MeshLocalPrefix", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "octet_string", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "NeighborTable", + "code": 7, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "RouteTable", + "code": 8, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "PartitionId", + "code": 9, + "mfgCode": null, + "side": "server", + "type": "int32u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "Weighting", + "code": 10, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "DataVersion", + "code": 11, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "StableDataVersion", + "code": 12, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "LeaderRouterId", + "code": 13, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "SecurityPolicy", + "code": 59, + "mfgCode": null, + "side": "server", + "type": "SecurityPolicy", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ChannelPage0Mask", + "code": 60, + "mfgCode": null, + "side": "server", + "type": "octet_string", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "OperationalDatasetComponents", + "code": 61, + "mfgCode": null, + "side": "server", + "type": "OperationalDatasetComponents", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ActiveNetworkFaultsList", + "code": 62, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "WiFi Network Diagnostics", + "code": 54, + "mfgCode": null, + "define": "WIFI_NETWORK_DIAGNOSTICS_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "BSSID", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "octet_string", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "SecurityType", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "SecurityTypeEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "WiFiVersion", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "WiFiVersionEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "ChannelNumber", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "RSSI", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int8s", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x00", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Ethernet Network Diagnostics", + "code": 55, + "mfgCode": null, + "define": "ETHERNET_NETWORK_DIAGNOSTICS_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "ResetCounts", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "PHYRate", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "PHYRateEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FullDuplex", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x00", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "PacketRxCount", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "PacketTxCount", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "TxErrCount", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "CollisionCount", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "OverrunCount", + "code": 6, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "CarrierDetect", + "code": 7, + "mfgCode": null, + "side": "server", + "type": "boolean", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x00", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "TimeSinceReset", + "code": 8, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "3", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Administrator Commissioning", + "code": 60, + "mfgCode": null, + "define": "ADMINISTRATOR_COMMISSIONING_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "OpenCommissioningWindow", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "RevokeCommissioning", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "WindowStatus", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "CommissioningWindowStatusEnum", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AdminFabricIndex", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "fabric_idx", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AdminVendorId", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "vendor_id", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Operational Credentials", + "code": 62, + "mfgCode": null, + "define": "OPERATIONAL_CREDENTIALS_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "AttestationRequest", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "AttestationResponse", + "code": 1, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "CertificateChainRequest", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "CertificateChainResponse", + "code": 3, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "CSRRequest", + "code": 4, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "CSRResponse", + "code": 5, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "AddNOC", + "code": 6, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "UpdateNOC", + "code": 7, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "NOCResponse", + "code": 8, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "UpdateFabricLabel", + "code": 9, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "RemoveFabric", + "code": 10, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "AddTrustedRootCertificate", + "code": 11, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "NOCs", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "Fabrics", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "SupportedFabrics", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "CommissionedFabrics", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "TrustedRootCertificates", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "CurrentFabricIndex", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "int8u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Group Key Management", + "code": 63, + "mfgCode": null, + "define": "GROUP_KEY_MANAGEMENT_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "KeySetWrite", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "KeySetRead", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "KeySetReadResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "KeySetRemove", + "code": 3, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "KeySetReadAllIndices", + "code": 4, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "KeySetReadAllIndicesResponse", + "code": 5, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "GroupKeyMap", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "GroupTable", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + }, + { + "name": "MaxGroupsPerFabric", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "MaxGroupKeysPerFabric", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 0, + "maxInterval": 65344, + "reportableChange": 0 + } + ] + }, + { + "name": "Fixed Label", + "code": 64, + "mfgCode": null, + "define": "FIXED_LABEL_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "LabelList", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + } + ] + }, + { + "name": "User Label", + "code": 65, + "mfgCode": null, + "define": "USER_LABEL_CLUSTER", + "side": "server", + "enabled": 1, + "attributes": [ + { + "name": "LabelList", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + } + ] + }, + { + "name": "ICD Management", + "code": 70, + "mfgCode": null, + "define": "ICD_MANAGEMENT_CLUSTER", + "side": "server", + "enabled": 1, + "commands": [ + { + "name": "RegisterClient", + "code": 0, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "RegisterClientResponse", + "code": 1, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 + }, + { + "name": "UnregisterClient", + "code": 2, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + } + ], + "attributes": [ + { + "name": "IdleModeDuration", + "code": 0, + "mfgCode": null, + "side": "server", + "type": "int32u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "1", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ActiveModeDuration", + "code": 1, + "mfgCode": null, + "side": "server", + "type": "int32u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "300", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ActiveModeThreshold", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "300", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "RegisteredClients", + "code": 3, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ICDCounter", + "code": 4, + "mfgCode": null, + "side": "server", + "type": "int32u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClientsSupportedPerFabric", + "code": 5, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "2", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "UserActiveModeTriggerHint", + "code": 6, + "mfgCode": null, + "side": "server", + "type": "UserActiveModeTriggerBitmap", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "5", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "UserActiveModeTriggerInstruction", + "code": 7, + "mfgCode": null, + "side": "server", + "type": "char_string", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "This is a test", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "GeneratedCommandList", + "code": 65528, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AcceptedCommandList", + "code": 65529, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "EventList", + "code": 65530, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "AttributeList", + "code": 65531, + "mfgCode": null, + "side": "server", + "type": "array", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "FeatureMap", + "code": 65532, + "mfgCode": null, + "side": "server", + "type": "bitmap32", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0007", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, + { + "name": "ClusterRevision", + "code": 65533, + "mfgCode": null, + "side": "server", + "type": "int16u", + "included": 1, + "storageOption": "RAM", + "singleton": 0, + "bounded": 0, + "defaultValue": "2", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + } + ] + } + ] + } + ], + "endpoints": [ + { + "endpointTypeName": "MA-rootdevice", + "endpointTypeIndex": 0, + "profileId": 259, + "endpointId": 0, + "networkId": 0 + } + ], + "log": [] +} \ No newline at end of file diff --git a/scripts/build/build/targets.py b/scripts/build/build/targets.py index 3a29eed2ffcfc3..1736afc01f5f7a 100755 --- a/scripts/build/build/targets.py +++ b/scripts/build/build/targets.py @@ -136,6 +136,7 @@ def BuildHostTarget(): TargetPart('refrigerator', app=HostApp.REFRIGERATOR), TargetPart('rvc', app=HostApp.RVC), TargetPart('air-purifier', app=HostApp.AIR_PURIFIER), + TargetPart('lit-icd', app=HostApp.LIT_ICD) ] if (HostBoard.NATIVE.PlatformName() == 'darwin'): diff --git a/scripts/build/builders/host.py b/scripts/build/builders/host.py index 2a145906e54087..c7a40540319322 100644 --- a/scripts/build/builders/host.py +++ b/scripts/build/builders/host.py @@ -73,6 +73,7 @@ class HostApp(Enum): REFRIGERATOR = auto() RVC = auto() AIR_PURIFIER = auto() + LIT_ICD = auto() def ExamplePath(self): if self == HostApp.ALL_CLUSTERS: @@ -127,6 +128,8 @@ def ExamplePath(self): return 'rvc-app/linux' elif self == HostApp.AIR_PURIFIER: return 'air-purifier-app/linux' + elif self == HostApp.LIT_ICD: + return 'lit-icd-app/linux' else: raise Exception('Unknown app type: %r' % self) @@ -221,6 +224,9 @@ def OutputNames(self): elif self == HostApp.AIR_PURIFIER: yield 'air-purifier-app' yield 'air-purifier-app.map' + elif self == HostApp.LIT_ICD: + yield 'lit-icd-app' + yield 'lit-icd-app.map' else: raise Exception('Unknown app type: %r' % self) diff --git a/scripts/build/testdata/all_targets_linux_x64.txt b/scripts/build/testdata/all_targets_linux_x64.txt index b5f8ad99719433..e76f940460ad46 100644 --- a/scripts/build/testdata/all_targets_linux_x64.txt +++ b/scripts/build/testdata/all_targets_linux_x64.txt @@ -10,7 +10,7 @@ efr32-{brd4161a,brd4187c,brd4186c,brd4163a,brd4164a,brd4166a,brd4170a,brd4186a,b esp32-{m5stack,c3devkit,devkitc,qemu}-{all-clusters,all-clusters-minimal,ota-provider,ota-requestor,shell,light,lock,bridge,temperature-measurement,ota-requestor,tests}[-rpc][-ipv6only][-tracing] genio-lighting-app linux-fake-tests[-mbedtls][-boringssl][-asan][-tsan][-ubsan][-libfuzzer][-ossfuzz][-coverage][-dmalloc][-clang] -linux-{x64,arm64}-{rpc-console,all-clusters,all-clusters-minimal,chip-tool,thermostat,java-matter-controller,kotlin-matter-controller,minmdns,light,lock,shell,ota-provider,ota-requestor,simulated-app1,simulated-app2,python-bindings,tv-app,tv-casting-app,bridge,tests,chip-cert,address-resolve-tool,contact-sensor,dishwasher,refrigerator,rvc,air-purifier}[-nodeps][-platform-mdns][-minmdns-verbose][-libnl][-same-event-loop][-no-interactive][-ipv6only][-no-ble][-no-wifi][-no-thread][-mbedtls][-boringssl][-asan][-tsan][-ubsan][-libfuzzer][-ossfuzz][-coverage][-dmalloc][-clang][-test][-rpc][-with-ui] +linux-{x64,arm64}-{rpc-console,all-clusters,all-clusters-minimal,chip-tool,thermostat,java-matter-controller,kotlin-matter-controller,minmdns,light,lock,shell,ota-provider,ota-requestor,simulated-app1,simulated-app2,python-bindings,tv-app,tv-casting-app,bridge,tests,chip-cert,address-resolve-tool,contact-sensor,dishwasher,refrigerator,rvc,air-purifier,lit-icd}[-nodeps][-platform-mdns][-minmdns-verbose][-libnl][-same-event-loop][-no-interactive][-ipv6only][-no-ble][-no-wifi][-no-thread][-mbedtls][-boringssl][-asan][-tsan][-ubsan][-libfuzzer][-ossfuzz][-coverage][-dmalloc][-clang][-test][-rpc][-with-ui] linux-x64-efr32-test-runner[-clang] imx-{chip-tool,lighting-app,thermostat,all-clusters-app,all-clusters-minimal-app,ota-provider-app}[-release] infineon-psoc6-{lock,light,all-clusters,all-clusters-minimal}[-ota][-updateimage] From 4138a0ee21f821fff835dd6d22d79c124a88e5d3 Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Fri, 3 Nov 2023 17:52:53 -0400 Subject: [PATCH 02/11] Add shim for ApplicationLauncher::ApplicationLanucherStatusEnum (#30202) Co-authored-by: Andrei Litvin --- src/app/CompatEnumNames.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/CompatEnumNames.h b/src/app/CompatEnumNames.h index 0882b0aa27b712..abf9950cc8dba2 100644 --- a/src/app/CompatEnumNames.h +++ b/src/app/CompatEnumNames.h @@ -42,6 +42,11 @@ using OTAChangeReasonEnum = ChangeReasonEnum; using OTAUpdateStateEnum = UpdateStateEnum; } // namespace OtaSoftwareUpdateRequestor +namespace ApplicationLauncher { +// https://github.com/project-chip/connectedhomeip/pull/30134 renamed this +using ApplicationLauncherStatusEnum = StatusEnum; +} // namespace ApplicationLauncher + namespace Channel { using ChannelStatusEnum = StatusEnum; } // namespace Channel From ec329616bc71d8276307f01af1ae684390055999 Mon Sep 17 00:00:00 2001 From: Boris Zbarsky Date: Fri, 3 Nov 2023 18:15:48 -0400 Subject: [PATCH 03/11] Clean up MTRClusters/MTRBaseClusters a bit: (#29241) * Clean up MTRClusters/MTRBaseClusters a bit: 1) Introduce MTRGenericBaseCluster/MTRGenericCluster base classes. 2) Move the same-for-every-type initializer implementation to the base class. 3) Move the class-specific initializer declaration (needed to get availability right) to a category so we don't get complaints about incomplete implementation. * Address review comment. --- src/darwin/Framework/CHIP/MTRCluster.h | 19 + src/darwin/Framework/CHIP/MTRCluster.mm | 24 + .../Framework/CHIP/MTRCluster_Internal.h | 22 +- .../CHIP/templates/MTRBaseClusters-src.zapt | 12 - .../CHIP/templates/MTRBaseClusters.zapt | 22 +- .../templates/MTRBaseClusters_Internal.zapt | 11 +- .../CHIP/templates/MTRClusters-src.zapt | 15 +- .../Framework/CHIP/templates/MTRClusters.zapt | 41 +- .../CHIP/zap-generated/MTRBaseClusters.h | 1946 ++++++++++------- .../CHIP/zap-generated/MTRBaseClusters.mm | 1152 ---------- .../zap-generated/MTRBaseClusters_Internal.h | 385 +--- .../CHIP/zap-generated/MTRClusters.h | 1790 +++++++-------- .../CHIP/zap-generated/MTRClusters.mm | 1153 ---------- 13 files changed, 2111 insertions(+), 4481 deletions(-) diff --git a/src/darwin/Framework/CHIP/MTRCluster.h b/src/darwin/Framework/CHIP/MTRCluster.h index d8d0b5dbf26923..f4a6887b476aa4 100644 --- a/src/darwin/Framework/CHIP/MTRCluster.h +++ b/src/darwin/Framework/CHIP/MTRCluster.h @@ -29,6 +29,7 @@ typedef void (^MTRStatusCompletion)(NSError * _Nullable error); typedef void (^MTRSubscriptionEstablishedHandler)(void); @class MTRBaseDevice; +@class MTRDevice; NS_ASSUME_NONNULL_BEGIN @@ -46,6 +47,24 @@ NS_ASSUME_NONNULL_BEGIN @property (nonatomic, readonly) NSNumber * endpointID NS_REFINED_FOR_SWIFT MTR_NEWLY_AVAILABLE; @end +/** + * Base for all MTRBaseCluster* types. + */ +MTR_NEWLY_AVAILABLE +@interface MTRGenericBaseCluster : MTRCluster +@end + +/** + * Base for all MTRCluster* types. + */ +MTR_NEWLY_AVAILABLE +@interface MTRGenericCluster : MTRCluster +/** + * The device this cluster object is associated with. + */ +@property (nonatomic, strong, readonly) MTRDevice * device; +@end + /** * MTRWriteParams * This is used to control the behavior of cluster writes. diff --git a/src/darwin/Framework/CHIP/MTRCluster.mm b/src/darwin/Framework/CHIP/MTRCluster.mm index 55c36ec04dbd72..27324cde294b85 100644 --- a/src/darwin/Framework/CHIP/MTRCluster.mm +++ b/src/darwin/Framework/CHIP/MTRCluster.mm @@ -36,6 +36,30 @@ - (instancetype)initWithEndpointID:(NSNumber *)endpointID queue:(dispatch_queue_ @end +@implementation MTRGenericBaseCluster + +- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue +{ + if (self = [super initWithEndpointID:endpointID queue:queue]) { + _device = device; + } + return self; +} + +@end + +@implementation MTRGenericCluster + +- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue +{ + if (self = [super initWithEndpointID:endpointID queue:queue]) { + _device = device; + } + return self; +} + +@end + @implementation MTRWriteParams - (instancetype)init { diff --git a/src/darwin/Framework/CHIP/MTRCluster_Internal.h b/src/darwin/Framework/CHIP/MTRCluster_Internal.h index fa9ad17586027f..937c110a4ea171 100644 --- a/src/darwin/Framework/CHIP/MTRCluster_Internal.h +++ b/src/darwin/Framework/CHIP/MTRCluster_Internal.h @@ -17,11 +17,11 @@ #import -#import "MTRBaseDevice.h" -#import "MTRBaseDevice_Internal.h" -#import "MTRCluster.h" +#import +#import +#import -#import "zap-generated/MTRBaseClusters.h" +#import "MTRBaseDevice_Internal.h" #include #include @@ -35,6 +35,20 @@ NS_ASSUME_NONNULL_BEGIN - (instancetype)initWithEndpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue; @end +@interface MTRGenericBaseCluster () +- (instancetype)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue; + +@property (nonatomic, strong, readonly) MTRBaseDevice * device; +@end + +@interface MTRGenericCluster () +- (instancetype)initWithDevice:(MTRDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue; +@end + @interface MTRReadParams () /** * Copy state from this MTRReadParams to the ReadPreparaParams. diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt index 8097b929e06e9a..fb303d5589d2be 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters-src.zapt @@ -49,18 +49,6 @@ public: {{#if (isSupported (asUpperCamelCase name preserveAcronyms=true))}} @implementation MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - {{#zcl_commands}} {{#if (is_str_equal source 'client')}} {{! Takes two arguments: cluster name and command name, plus the ambient state where the command is "this" }} diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt index 52047a1fa2fbc6..edd4f05e4a27b4 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters.zapt @@ -17,15 +17,7 @@ NS_ASSUME_NONNULL_BEGIN * {{description}} */ {{availability (asUpperCamelCase name preserveAcronyms=true)}} -@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER {{availability (asUpperCamelCase name preserveAcronyms=true) minimalRelease="First major API revamp"}}; +@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRGenericBaseCluster {{#zcl_commands}} {{#if (is_str_equal source 'client')}} @@ -81,6 +73,18 @@ subscriptionEstablished:(MTRSubscriptionEstablishedHandler _Nullable)subscriptio - (instancetype)init NS_UNAVAILABLE; + (instancetype)new NS_UNAVAILABLE; +@end + +@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue {{availability (asUpperCamelCase name preserveAcronyms=true) minimalRelease="First major API revamp"}}; + @end {{/if}} diff --git a/src/darwin/Framework/CHIP/templates/MTRBaseClusters_Internal.zapt b/src/darwin/Framework/CHIP/templates/MTRBaseClusters_Internal.zapt index 9d40126f3a857d..c5790da1795a81 100644 --- a/src/darwin/Framework/CHIP/templates/MTRBaseClusters_Internal.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRBaseClusters_Internal.zapt @@ -5,12 +5,5 @@ #import "MTRBaseClusters.h" #import "MTRBaseDevice.h" -{{#zcl_clusters}} - -{{#if (isSupported (asUpperCamelCase name preserveAcronyms=true))}} -@interface MTRBaseCluster{{asUpperCamelCase name preserveAcronyms=true}} () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end -{{/if}} - -{{/zcl_clusters}} +// Nothing here for now, but leaving this file in place in case we need to add +// something. diff --git a/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt b/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt index 4a2c566785ef68..9cefaa1a510b13 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusters-src.zapt @@ -1,12 +1,11 @@ {{> header excludeZapComment=true}} #import -#import #import "MTRClusterConstants.h" -#import "MTRClusters_Internal.h" #import "MTRDevice_Internal.h" #import "MTRCluster_Internal.h" +#import "MTRClusters_Internal.h" #import "MTRStructsObjc.h" #import "MTRCommandPayloadsObjc.h" #import "MTRLogging_Internal.h" @@ -31,18 +30,6 @@ using chip::System::Clock::Seconds16; {{#if (isSupported (asUpperCamelCase name preserveAcronyms=true))}} @implementation MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - {{#zcl_commands}} {{! Takes two arguments: cluster name and command name, plus the ambient state where the command is "this" }} {{#*inline "commandImpl"}} diff --git a/src/darwin/Framework/CHIP/templates/MTRClusters.zapt b/src/darwin/Framework/CHIP/templates/MTRClusters.zapt index 17ef4f741dd6f8..c089804986d154 100644 --- a/src/darwin/Framework/CHIP/templates/MTRClusters.zapt +++ b/src/darwin/Framework/CHIP/templates/MTRClusters.zapt @@ -17,27 +17,7 @@ NS_ASSUME_NONNULL_BEGIN * {{description}} */ {{availability (asUpperCamelCase name preserveAcronyms=true)}} -@interface MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRCluster - -/** -{{#zcl_commands}} -{{#first}} - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. -{{/first}} -{{else}} - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. -{{/zcl_commands}} - */ -- (instancetype _Nullable)initWithDevice:(MTRDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER {{availability (asUpperCamelCase name preserveAcronyms=true) minimalRelease="First major API revamp"}}; - -/** - * The device this cluster object is associated with. - */ -@property (nonatomic, readonly) MTRDevice * device {{availability (asUpperCamelCase name preserveAcronyms=true) minimalRelease="Future"}}; +@interface MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} : MTRGenericCluster {{#zcl_commands}} {{#if (is_str_equal source 'client')}} @@ -84,6 +64,25 @@ NS_ASSUME_NONNULL_BEGIN @end +@interface MTRCluster{{asUpperCamelCase name preserveAcronyms=true}} (Availability) + +/** +{{#zcl_commands}} +{{#first}} + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. +{{/first}} +{{else}} + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. +{{/zcl_commands}} + */ +- (instancetype _Nullable)initWithDevice:(MTRDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue {{availability (asUpperCamelCase name preserveAcronyms=true) minimalRelease="First major API revamp"}}; + +@end + {{/if}} {{/zcl_clusters}} diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h index 5b5db7e2a62da0..bbe527dde793ff 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h @@ -28,15 +28,7 @@ NS_ASSUME_NONNULL_BEGIN * Attributes and commands for putting a device into Identification mode (e.g. flashing a light). */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterIdentify : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterIdentify : MTRGenericBaseCluster /** * Command Identify @@ -106,13 +98,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Groups - * - * Attributes and commands for group configuration and manipulation. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterGroups : MTRCluster +@interface MTRBaseClusterIdentify (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -120,7 +106,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Groups + * + * Attributes and commands for group configuration and manipulation. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterGroups : MTRGenericBaseCluster /** * Command AddGroup @@ -208,13 +204,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Scenes - * - * Attributes and commands for scene configuration and manipulation. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterScenes : MTRCluster +@interface MTRBaseClusterGroups (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -222,7 +212,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Scenes + * + * Attributes and commands for scene configuration and manipulation. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterScenes : MTRGenericBaseCluster /** * Command AddScene @@ -374,13 +374,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster On/Off - * - * Attributes and commands for switching devices between 'On' and 'Off' states. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterOnOff : MTRCluster +@interface MTRBaseClusterScenes (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -388,7 +382,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster On/Off + * + * Attributes and commands for switching devices between 'On' and 'Off' states. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterOnOff : MTRGenericBaseCluster /** * Command Off @@ -512,13 +516,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster On/off Switch Configuration - * - * Attributes and commands for configuring On/Off switching devices. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterOnOffSwitchConfiguration : MTRCluster +@interface MTRBaseClusterOnOff (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -526,7 +524,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster On/off Switch Configuration + * + * Attributes and commands for configuring On/Off switching devices. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterOnOffSwitchConfiguration : MTRGenericBaseCluster - (void)readAttributeSwitchTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeSwitchTypeWithParams:(MTRSubscribeParams *)params @@ -583,13 +591,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Level Control - * - * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterLevelControl : MTRCluster +@interface MTRBaseClusterOnOffSwitchConfiguration (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -597,7 +599,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Level Control + * + * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterLevelControl : MTRGenericBaseCluster /** * Command MoveToLevel @@ -794,13 +806,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Binary Input (Basic) - * - * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterBinaryInputBasic : MTRCluster +@interface MTRBaseClusterLevelControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -808,7 +814,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Binary Input (Basic) + * + * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterBinaryInputBasic : MTRGenericBaseCluster - (void)readAttributeActiveTextWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeActiveTextWithValue:(NSString * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -917,13 +933,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pulse Width Modulation - * - * Cluster to control pulse width modulation - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterPulseWidthModulation : MTRCluster +@interface MTRBaseClusterBinaryInputBasic (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -931,7 +941,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Pulse Width Modulation + * + * Cluster to control pulse width modulation + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterPulseWidthModulation : MTRGenericBaseCluster - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeGeneratedCommandListWithParams:(MTRSubscribeParams *)params @@ -974,13 +994,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Descriptor - * - * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterDescriptor : MTRCluster +@interface MTRBaseClusterPulseWidthModulation (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -988,7 +1002,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Descriptor + * + * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterDescriptor : MTRGenericBaseCluster - (void)readAttributeDeviceTypeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeDeviceTypeListWithParams:(MTRSubscribeParams *)params @@ -1061,13 +1085,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Binding - * - * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterBinding : MTRCluster +@interface MTRBaseClusterDescriptor (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -1075,7 +1093,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Binding + * + * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterBinding : MTRGenericBaseCluster - (void)readAttributeBindingWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeBindingWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1126,6 +1154,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end +@interface MTRBaseClusterBinding (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Access Control * @@ -1135,15 +1175,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) cluster instances. */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterAccessControl : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterAccessControl : MTRGenericBaseCluster - (void)readAttributeACLWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeACLWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1220,13 +1252,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Actions - * - * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterActions : MTRCluster +@interface MTRBaseClusterAccessControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -1234,7 +1260,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Actions + * + * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterActions : MTRGenericBaseCluster /** * Command InstantAction @@ -1368,6 +1404,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end +@interface MTRBaseClusterActions (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Basic Information * @@ -1376,15 +1424,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) which apply to the whole Node. Also allows setting user device information such as location. */ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterBasicInformation : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterBasicInformation : MTRGenericBaseCluster - (void)readAttributeDataModelRevisionWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeDataModelRevisionWithParams:(MTRSubscribeParams *)params @@ -1559,13 +1599,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster OTA Software Update Provider - * - * Provides an interface for providing OTA software updates - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterOTASoftwareUpdateProvider : MTRCluster +@interface MTRBaseClusterBasicInformation (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -1573,7 +1607,17 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster OTA Software Update Provider + * + * Provides an interface for providing OTA software updates + */ +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRBaseClusterOTASoftwareUpdateProvider : MTRGenericBaseCluster /** * Command QueryImage @@ -1635,13 +1679,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster OTA Software Update Requestor - * - * Provides an interface for downloading and applying OTA software updates - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterOTASoftwareUpdateRequestor : MTRCluster +@interface MTRBaseClusterOTASoftwareUpdateProvider (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -1649,7 +1687,17 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster OTA Software Update Requestor + * + * Provides an interface for downloading and applying OTA software updates + */ +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRBaseClusterOTASoftwareUpdateRequestor : MTRGenericBaseCluster /** * Command AnnounceOTAProvider @@ -1725,6 +1773,18 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end +@interface MTRBaseClusterOTASoftwareUpdateRequestor (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Localization Configuration * @@ -1734,15 +1794,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) they can be configured to use a user’s preferred language, units, etc */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterLocalizationConfiguration : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterLocalizationConfiguration : MTRGenericBaseCluster - (void)readAttributeActiveLocaleWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeActiveLocaleWithValue:(NSString * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1799,6 +1851,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end +@interface MTRBaseClusterLocalizationConfiguration (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Time Format Localization * @@ -1808,15 +1872,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) user’s preferred format. */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterTimeFormatLocalization : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterTimeFormatLocalization : MTRGenericBaseCluster - (void)readAttributeHourFormatWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeHourFormatWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1881,6 +1937,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end +@interface MTRBaseClusterTimeFormatLocalization (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Unit Localization * @@ -1890,15 +1958,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) mechanism by which they can be configured to use a user’s preferred unit. */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterUnitLocalization : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterUnitLocalization : MTRGenericBaseCluster - (void)readAttributeTemperatureUnitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeTemperatureUnitWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1949,13 +2009,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Power Source Configuration - * - * This cluster is used to describe the configuration and capabilities of a Device's power system. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterPowerSourceConfiguration : MTRCluster +@interface MTRBaseClusterUnitLocalization (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -1963,7 +2017,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Power Source Configuration + * + * This cluster is used to describe the configuration and capabilities of a Device's power system. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterPowerSourceConfiguration : MTRGenericBaseCluster - (void)readAttributeSourcesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeSourcesWithParams:(MTRSubscribeParams *)params @@ -2012,13 +2076,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Power Source - * - * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the Node. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterPowerSource : MTRCluster +@interface MTRBaseClusterPowerSourceConfiguration (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2026,7 +2084,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Power Source + * + * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the Node. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterPowerSource : MTRGenericBaseCluster - (void)readAttributeStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeStatusWithParams:(MTRSubscribeParams *)params @@ -2261,13 +2329,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster General Commissioning - * - * This cluster is used to manage global aspects of the Commissioning flow. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterGeneralCommissioning : MTRCluster +@interface MTRBaseClusterPowerSource (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2275,7 +2337,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster General Commissioning + * + * This cluster is used to manage global aspects of the Commissioning flow. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterGeneralCommissioning : MTRGenericBaseCluster /** * Command ArmFailSafe @@ -2371,13 +2443,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Network Commissioning - * - * Functionality to configure, enable, disable network credentials and access on a Matter device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterNetworkCommissioning : MTRCluster +@interface MTRBaseClusterGeneralCommissioning (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2385,7 +2451,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Network Commissioning + * + * Functionality to configure, enable, disable network credentials and access on a Matter device. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterNetworkCommissioning : MTRGenericBaseCluster /** * Command ScanNetworks @@ -2533,13 +2609,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Diagnostic Logs - * - * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterDiagnosticLogs : MTRCluster +@interface MTRBaseClusterNetworkCommissioning (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2547,7 +2617,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Diagnostic Logs + * + * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterDiagnosticLogs : MTRGenericBaseCluster /** * Command RetrieveLogsRequest @@ -2597,13 +2677,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster General Diagnostics - * - * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterGeneralDiagnostics : MTRCluster +@interface MTRBaseClusterDiagnosticLogs (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2611,7 +2685,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster General Diagnostics + * + * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterGeneralDiagnostics : MTRGenericBaseCluster /** * Command TestEventTrigger @@ -2723,13 +2807,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Software Diagnostics - * - * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterSoftwareDiagnostics : MTRCluster +@interface MTRBaseClusterGeneralDiagnostics (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2737,7 +2815,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Software Diagnostics + * + * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterSoftwareDiagnostics : MTRGenericBaseCluster /** * Command ResetWatermarks @@ -2813,13 +2901,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thread Network Diagnostics - * - * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterThreadNetworkDiagnostics : MTRCluster +@interface MTRBaseClusterSoftwareDiagnostics (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -2827,7 +2909,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Thread Network Diagnostics + * + * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterThreadNetworkDiagnostics : MTRGenericBaseCluster /** * Command ResetCounts @@ -3257,13 +3349,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster WiFi Network Diagnostics - * - * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterWiFiNetworkDiagnostics : MTRCluster +@interface MTRBaseClusterThreadNetworkDiagnostics (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -3271,7 +3357,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster WiFi Network Diagnostics + * + * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterWiFiNetworkDiagnostics : MTRGenericBaseCluster /** * Command ResetCounts @@ -3401,13 +3497,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Ethernet Network Diagnostics - * - * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterEthernetNetworkDiagnostics : MTRCluster +@interface MTRBaseClusterWiFiNetworkDiagnostics (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -3415,7 +3505,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Ethernet Network Diagnostics + * + * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterEthernetNetworkDiagnostics : MTRGenericBaseCluster /** * Command ResetCounts @@ -3521,13 +3621,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Time Synchronization - * - * Accurate time is required for a number of reasons, including scheduling, display and validating security materials. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterTimeSynchronization : MTRCluster +@interface MTRBaseClusterEthernetNetworkDiagnostics (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -3535,7 +3629,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Time Synchronization + * + * Accurate time is required for a number of reasons, including scheduling, display and validating security materials. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterTimeSynchronization : MTRGenericBaseCluster /** * Command SetUTCTime @@ -3687,6 +3791,18 @@ MTR_PROVISIONALLY_AVAILABLE @end +@interface MTRBaseClusterTimeSynchronization (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + /** * Cluster Bridged Device Basic Information * @@ -3696,15 +3812,7 @@ MTR_PROVISIONALLY_AVAILABLE such as the vendor name, the model name, or user-assigned name. */ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterBridgedDeviceBasicInformation : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterBridgedDeviceBasicInformation : MTRGenericBaseCluster - (void)readAttributeVendorNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeVendorNameWithParams:(MTRSubscribeParams *)params @@ -3845,6 +3953,18 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end +@interface MTRBaseClusterBridgedDeviceBasicInformation (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + /** * Cluster Switch * @@ -3853,15 +3973,7 @@ Two types of switch devices are supported: latching switch (e.g. rocker switch) Interactions with the switch device are exposed as attributes (for the latching switch) and as events (for both types of switches). An interested party MAY subscribe to these attributes/events and thus be informed of the interactions, and can perform actions based on this, for example by sending commands to perform an action such as controlling a light or a window shade. */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterSwitch : MTRCluster - -/** - * For all instance methods (reads, writes, commands) that take a completion, - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@interface MTRBaseClusterSwitch : MTRGenericBaseCluster - (void)readAttributeNumberOfPositionsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeNumberOfPositionsWithParams:(MTRSubscribeParams *)params @@ -3922,13 +4034,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Administrator Commissioning - * - * Commands to trigger a Node to allow a new Administrator to commission it. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterAdministratorCommissioning : MTRCluster +@interface MTRBaseClusterSwitch (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -3936,7 +4042,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Administrator Commissioning + * + * Commands to trigger a Node to allow a new Administrator to commission it. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterAdministratorCommissioning : MTRGenericBaseCluster /** * Command OpenCommissioningWindow @@ -4018,13 +4134,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Operational Credentials - * - * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated Fabrics. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterOperationalCredentials : MTRCluster +@interface MTRBaseClusterAdministratorCommissioning (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4032,7 +4142,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Operational Credentials + * + * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated Fabrics. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterOperationalCredentials : MTRGenericBaseCluster /** * Command AttestationRequest @@ -4160,13 +4280,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Group Key Management - * - * The Group Key Management Cluster is the mechanism by which group keys are managed. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterGroupKeyManagement : MTRCluster +@interface MTRBaseClusterOperationalCredentials (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4174,7 +4288,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Group Key Management + * + * The Group Key Management Cluster is the mechanism by which group keys are managed. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterGroupKeyManagement : MTRGenericBaseCluster /** * Command KeySetWrite @@ -4270,14 +4394,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Fixed Label - * - * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only -labels. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterFixedLabel : MTRCluster +@interface MTRBaseClusterGroupKeyManagement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4285,7 +4402,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Fixed Label + * + * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only +labels. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterFixedLabel : MTRGenericBaseCluster - (void)readAttributeLabelListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeLabelListWithParams:(MTRSubscribeParams *)params @@ -4334,13 +4462,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster User Label - * - * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterUserLabel : MTRCluster +@interface MTRBaseClusterFixedLabel (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4348,7 +4470,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster User Label + * + * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterUserLabel : MTRGenericBaseCluster - (void)readAttributeLabelListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeLabelListWithValue:(NSArray * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -4399,13 +4531,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Boolean State - * - * This cluster provides an interface to a boolean state called StateValue. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterBooleanState : MTRCluster +@interface MTRBaseClusterUserLabel (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4413,7 +4539,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Boolean State + * + * This cluster provides an interface to a boolean state called StateValue. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterBooleanState : MTRGenericBaseCluster - (void)readAttributeStateValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeStateValueWithParams:(MTRSubscribeParams *)params @@ -4462,13 +4598,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster ICD Management - * - * Allows servers to ensure that listed clients are notified when a server is available for communication. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterICDManagement : MTRCluster +@interface MTRBaseClusterBooleanState (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4476,7 +4606,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster ICD Management + * + * Allows servers to ensure that listed clients are notified when a server is available for communication. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterICDManagement : MTRGenericBaseCluster /** * Command RegisterClient @@ -4588,13 +4728,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Mode Select - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterModeSelect : MTRCluster +@interface MTRBaseClusterICDManagement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4602,7 +4736,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Mode Select + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterModeSelect : MTRGenericBaseCluster /** * Command ChangeToMode @@ -4692,13 +4836,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Laundry Washer Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterLaundryWasherMode : MTRCluster +@interface MTRBaseClusterModeSelect (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4706,7 +4844,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Laundry Washer Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterLaundryWasherMode : MTRGenericBaseCluster /** * Command ChangeToMode @@ -4785,13 +4933,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Refrigerator And Temperature Controlled Cabinet Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRefrigeratorAndTemperatureControlledCabinetMode : MTRCluster +@interface MTRBaseClusterLaundryWasherMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4799,7 +4941,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Refrigerator And Temperature Controlled Cabinet Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRefrigeratorAndTemperatureControlledCabinetMode : MTRGenericBaseCluster /** * Command ChangeToMode @@ -4878,13 +5030,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Laundry Washer Controls - * - * This cluster supports remotely monitoring and controling the different typs of functionality available to a washing device, such as a washing machine. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterLaundryWasherControls : MTRCluster +@interface MTRBaseClusterRefrigeratorAndTemperatureControlledCabinetMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4892,7 +5038,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Laundry Washer Controls + * + * This cluster supports remotely monitoring and controling the different typs of functionality available to a washing device, such as a washing machine. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterLaundryWasherControls : MTRGenericBaseCluster - (void)readAttributeSpinSpeedsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeSpinSpeedsWithParams:(MTRSubscribeParams *)params @@ -4963,13 +5119,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Run Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRVCRunMode : MTRCluster +@interface MTRBaseClusterLaundryWasherControls (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -4977,7 +5127,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster RVC Run Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRVCRunMode : MTRGenericBaseCluster /** * Command ChangeToMode @@ -5048,13 +5208,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Clean Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRVCCleanMode : MTRCluster +@interface MTRBaseClusterRVCRunMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5062,7 +5216,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster RVC Clean Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRVCCleanMode : MTRGenericBaseCluster /** * Command ChangeToMode @@ -5133,13 +5297,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Temperature Control - * - * Attributes and commands for configuring the temperature control, and reporting temperature. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterTemperatureControl : MTRCluster +@interface MTRBaseClusterRVCCleanMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5147,7 +5305,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Temperature Control + * + * Attributes and commands for configuring the temperature control, and reporting temperature. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterTemperatureControl : MTRGenericBaseCluster /** * Command SetTemperature @@ -5233,13 +5401,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Refrigerator Alarm - * - * Attributes and commands for configuring the Refrigerator alarm. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRefrigeratorAlarm : MTRCluster +@interface MTRBaseClusterTemperatureControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5247,7 +5409,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Refrigerator Alarm + * + * Attributes and commands for configuring the Refrigerator alarm. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRefrigeratorAlarm : MTRGenericBaseCluster - (void)readAttributeMaskWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMaskWithParams:(MTRSubscribeParams *)params @@ -5308,13 +5480,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Dishwasher Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterDishwasherMode : MTRCluster +@interface MTRBaseClusterRefrigeratorAlarm (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5322,7 +5488,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Dishwasher Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterDishwasherMode : MTRGenericBaseCluster /** * Command ChangeToMode @@ -5401,13 +5577,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Air Quality - * - * Attributes for reporting air quality classification - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterAirQuality : MTRCluster +@interface MTRBaseClusterDishwasherMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5415,7 +5585,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Air Quality + * + * Attributes for reporting air quality classification + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterAirQuality : MTRGenericBaseCluster - (void)readAttributeAirQualityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeAirQualityWithParams:(MTRSubscribeParams *)params @@ -5464,13 +5644,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Smoke CO Alarm - * - * This cluster provides an interface for observing and managing the state of smoke and CO alarms. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterSmokeCOAlarm : MTRCluster +@interface MTRBaseClusterAirQuality (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5478,7 +5652,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Smoke CO Alarm + * + * This cluster provides an interface for observing and managing the state of smoke and CO alarms. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterSmokeCOAlarm : MTRGenericBaseCluster /** * Command SelfTestRequest @@ -5610,13 +5794,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Dishwasher Alarm - * - * Attributes and commands for configuring the Dishwasher alarm. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterDishwasherAlarm : MTRCluster +@interface MTRBaseClusterSmokeCOAlarm (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5624,7 +5802,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Dishwasher Alarm + * + * Attributes and commands for configuring the Dishwasher alarm. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterDishwasherAlarm : MTRGenericBaseCluster /** * Command Reset @@ -5704,13 +5892,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Microwave Oven Mode - * - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterMicrowaveOvenMode : MTRCluster +@interface MTRBaseClusterDishwasherAlarm (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5718,7 +5900,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Microwave Oven Mode + * + * Attributes and commands for selecting a mode from a list of supported options. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterMicrowaveOvenMode : MTRGenericBaseCluster - (void)readAttributeSupportedModesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeSupportedModesWithParams:(MTRSubscribeParams *)params @@ -5773,13 +5965,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Microwave Oven Control - * - * Attributes and commands for configuring the microwave oven control, and reporting cooking stats. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterMicrowaveOvenControl : MTRCluster +@interface MTRBaseClusterMicrowaveOvenMode (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5787,7 +5973,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Microwave Oven Control + * + * Attributes and commands for configuring the microwave oven control, and reporting cooking stats. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterMicrowaveOvenControl : MTRGenericBaseCluster /** * Command SetCookingParameters @@ -5873,13 +6069,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Operational State - * - * This cluster supports remotely monitoring and, where supported, changing the operational state of any device where a state machine is a part of the operation. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterOperationalState : MTRCluster +@interface MTRBaseClusterMicrowaveOvenControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -5887,7 +6077,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Operational State + * + * This cluster supports remotely monitoring and, where supported, changing the operational state of any device where a state machine is a part of the operation. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterOperationalState : MTRGenericBaseCluster /** * Command Pause @@ -5999,13 +6199,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Operational State - * - * This cluster supports remotely monitoring and, where supported, changing the operational state of a Robotic Vacuum. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRVCOperationalState : MTRCluster +@interface MTRBaseClusterOperationalState (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -6013,7 +6207,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster RVC Operational State + * + * This cluster supports remotely monitoring and, where supported, changing the operational state of a Robotic Vacuum. + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRVCOperationalState : MTRGenericBaseCluster /** * Command Pause @@ -6125,13 +6329,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster HEPA Filter Monitoring - * - * Attributes and commands for monitoring HEPA filters in a device - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterHEPAFilterMonitoring : MTRCluster +@interface MTRBaseClusterRVCOperationalState (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -6139,7 +6337,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster HEPA Filter Monitoring + * + * Attributes and commands for monitoring HEPA filters in a device + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterHEPAFilterMonitoring : MTRGenericBaseCluster /** * Command ResetCondition @@ -6229,13 +6437,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Activated Carbon Filter Monitoring - * - * Attributes and commands for monitoring activated carbon filters in a device - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterActivatedCarbonFilterMonitoring : MTRCluster +@interface MTRBaseClusterHEPAFilterMonitoring (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -6243,7 +6445,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Activated Carbon Filter Monitoring + * + * Attributes and commands for monitoring activated carbon filters in a device + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterActivatedCarbonFilterMonitoring : MTRGenericBaseCluster /** * Command ResetCondition @@ -6333,13 +6545,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Door Lock - * - * An interface to a generic way to secure a door - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterDoorLock : MTRCluster +@interface MTRBaseClusterActivatedCarbonFilterMonitoring (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -6347,7 +6553,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Door Lock + * + * An interface to a generic way to secure a door + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterDoorLock : MTRGenericBaseCluster /** * Command LockDoor @@ -6757,13 +6973,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Window Covering - * - * Provides an interface for controlling and adjusting automatic window coverings. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterWindowCovering : MTRCluster +@interface MTRBaseClusterDoorLock (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -6771,7 +6981,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Window Covering + * + * Provides an interface for controlling and adjusting automatic window coverings. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterWindowCovering : MTRGenericBaseCluster /** * Command UpOrOpen @@ -6997,13 +7217,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Barrier Control - * - * This cluster provides control of a barrier (garage door). - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterBarrierControl : MTRCluster +@interface MTRBaseClusterWindowCovering (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -7011,7 +7225,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Barrier Control + * + * This cluster provides control of a barrier (garage door). + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterBarrierControl : MTRGenericBaseCluster /** * Command BarrierControlGoToPercent @@ -7141,13 +7365,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pump Configuration and Control - * - * An interface for configuring and controlling pumps. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterPumpConfigurationAndControl : MTRCluster +@interface MTRBaseClusterBarrierControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -7155,7 +7373,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Pump Configuration and Control + * + * An interface for configuring and controlling pumps. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterPumpConfigurationAndControl : MTRGenericBaseCluster - (void)readAttributeMaxPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMaxPressureWithParams:(MTRSubscribeParams *)params @@ -7344,13 +7572,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thermostat - * - * An interface for configuring and controlling the functionality of a thermostat. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterThermostat : MTRCluster +@interface MTRBaseClusterPumpConfigurationAndControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -7358,7 +7580,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Thermostat + * + * An interface for configuring and controlling the functionality of a thermostat. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterThermostat : MTRGenericBaseCluster /** * Command SetpointRaiseLower @@ -7776,13 +8008,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Fan Control - * - * An interface for controlling a fan in a heating/cooling system. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterFanControl : MTRCluster +@interface MTRBaseClusterThermostat (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -7790,7 +8016,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Fan Control + * + * An interface for controlling a fan in a heating/cooling system. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterFanControl : MTRGenericBaseCluster /** * Command Step @@ -7926,21 +8162,25 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thermostat User Interface Configuration - * - * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterThermostatUserInterfaceConfiguration : MTRCluster +@interface MTRBaseClusterFanControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, * the completion will be called on the provided queue. */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Thermostat User Interface Configuration + * + * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterThermostatUserInterfaceConfiguration : MTRGenericBaseCluster - (void)readAttributeTemperatureDisplayModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeTemperatureDisplayModeWithValue:(NSNumber * _Nonnull)value completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -8007,13 +8247,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Color Control - * - * Attributes and commands for controlling the color properties of a color-capable light. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterColorControl : MTRCluster +@interface MTRBaseClusterThermostatUserInterfaceConfiguration (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8021,7 +8255,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Color Control + * + * Attributes and commands for controlling the color properties of a color-capable light. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterColorControl : MTRGenericBaseCluster /** * Command MoveToHue @@ -8517,13 +8761,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Ballast Configuration - * - * Attributes and commands for configuring a lighting ballast. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterBallastConfiguration : MTRCluster +@interface MTRBaseClusterColorControl (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8531,7 +8769,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Ballast Configuration + * + * Attributes and commands for configuring a lighting ballast. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterBallastConfiguration : MTRGenericBaseCluster - (void)readAttributePhysicalMinLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributePhysicalMinLevelWithParams:(MTRSubscribeParams *)params @@ -8678,13 +8926,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Illuminance Measurement - * - * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterIlluminanceMeasurement : MTRCluster +@interface MTRBaseClusterBallastConfiguration (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8692,7 +8934,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Illuminance Measurement + * + * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterIlluminanceMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -8765,13 +9017,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Temperature Measurement - * - * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterTemperatureMeasurement : MTRCluster +@interface MTRBaseClusterIlluminanceMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8779,7 +9025,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Temperature Measurement + * + * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterTemperatureMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -8846,13 +9102,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pressure Measurement - * - * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterPressureMeasurement : MTRCluster +@interface MTRBaseClusterTemperatureMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8860,7 +9110,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Pressure Measurement + * + * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterPressureMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -8957,13 +9217,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Flow Measurement - * - * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterFlowMeasurement : MTRCluster +@interface MTRBaseClusterPressureMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -8971,7 +9225,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Flow Measurement + * + * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterFlowMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9038,13 +9302,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Relative Humidity Measurement - * - * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterRelativeHumidityMeasurement : MTRCluster +@interface MTRBaseClusterFlowMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9052,7 +9310,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Relative Humidity Measurement + * + * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterRelativeHumidityMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9119,13 +9387,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Occupancy Sensing - * - * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterOccupancySensing : MTRCluster +@interface MTRBaseClusterRelativeHumidityMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9133,7 +9395,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Occupancy Sensing + * + * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterOccupancySensing : MTRGenericBaseCluster - (void)readAttributeOccupancyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeOccupancyWithParams:(MTRSubscribeParams *)params @@ -9266,13 +9538,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Carbon Monoxide Concentration Measurement - * - * Attributes for reporting carbon monoxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterCarbonMonoxideConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterOccupancySensing (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9280,7 +9546,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Carbon Monoxide Concentration Measurement + * + * Attributes for reporting carbon monoxide concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterCarbonMonoxideConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9389,13 +9665,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Carbon Dioxide Concentration Measurement - * - * Attributes for reporting carbon dioxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterCarbonDioxideConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterCarbonMonoxideConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9403,7 +9673,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Carbon Dioxide Concentration Measurement + * + * Attributes for reporting carbon dioxide concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterCarbonDioxideConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9512,13 +9792,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Nitrogen Dioxide Concentration Measurement - * - * Attributes for reporting nitrogen dioxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterNitrogenDioxideConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterCarbonDioxideConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9526,7 +9800,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Nitrogen Dioxide Concentration Measurement + * + * Attributes for reporting nitrogen dioxide concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterNitrogenDioxideConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9635,13 +9919,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Ozone Concentration Measurement - * - * Attributes for reporting ozone concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterOzoneConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterNitrogenDioxideConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9649,7 +9927,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Ozone Concentration Measurement + * + * Attributes for reporting ozone concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterOzoneConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9758,13 +10046,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM2.5 Concentration Measurement - * - * Attributes for reporting PM2.5 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterPM25ConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterOzoneConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9772,7 +10054,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster PM2.5 Concentration Measurement + * + * Attributes for reporting PM2.5 concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterPM25ConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -9881,13 +10173,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Formaldehyde Concentration Measurement - * - * Attributes for reporting formaldehyde concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterFormaldehydeConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterPM25ConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -9895,7 +10181,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Formaldehyde Concentration Measurement + * + * Attributes for reporting formaldehyde concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterFormaldehydeConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -10004,13 +10300,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM1 Concentration Measurement - * - * Attributes for reporting PM1 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterPM1ConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterFormaldehydeConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10018,7 +10308,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster PM1 Concentration Measurement + * + * Attributes for reporting PM1 concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterPM1ConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -10127,13 +10427,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM10 Concentration Measurement - * - * Attributes for reporting PM10 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterPM10ConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterPM1ConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10141,7 +10435,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster PM10 Concentration Measurement + * + * Attributes for reporting PM10 concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterPM10ConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -10250,21 +10554,25 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Total Volatile Organic Compounds Concentration Measurement - * - * Attributes for reporting total volatile organic compounds concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterTotalVolatileOrganicCompoundsConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterPM10ConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, * the completion will be called on the provided queue. */ -- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Total Volatile Organic Compounds Concentration Measurement + * + * Attributes for reporting total volatile organic compounds concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterTotalVolatileOrganicCompoundsConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -10373,13 +10681,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Radon Concentration Measurement - * - * Attributes for reporting radon concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterRadonConcentrationMeasurement : MTRCluster +@interface MTRBaseClusterTotalVolatileOrganicCompoundsConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10387,7 +10689,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Radon Concentration Measurement + * + * Attributes for reporting radon concentration measurements + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterRadonConcentrationMeasurement : MTRGenericBaseCluster - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)subscribeAttributeMeasuredValueWithParams:(MTRSubscribeParams *)params @@ -10496,13 +10808,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Wake on LAN - * - * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterWakeOnLAN : MTRCluster +@interface MTRBaseClusterRadonConcentrationMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10510,7 +10816,17 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + +/** + * Cluster Wake on LAN + * + * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. + */ +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRBaseClusterWakeOnLAN : MTRGenericBaseCluster - (void)readAttributeMACAddressWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeMACAddressWithParams:(MTRSubscribeParams *)params @@ -10559,13 +10875,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Channel - * - * This cluster provides an interface for controlling the current Channel on a device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterChannel : MTRCluster +@interface MTRBaseClusterWakeOnLAN (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10573,7 +10883,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Channel + * + * This cluster provides an interface for controlling the current Channel on a device. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterChannel : MTRGenericBaseCluster /** * Command ChangeChannel @@ -10653,13 +10973,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Target Navigator - * - * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterTargetNavigator : MTRCluster +@interface MTRBaseClusterChannel (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10667,7 +10981,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Target Navigator + * + * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterTargetNavigator : MTRGenericBaseCluster /** * Command NavigateTarget @@ -10729,13 +11053,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Media Playback - * - * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterMediaPlayback : MTRCluster +@interface MTRBaseClusterTargetNavigator (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10743,7 +11061,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Media Playback + * + * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterMediaPlayback : MTRGenericBaseCluster /** * Command Play @@ -10911,13 +11239,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Media Input - * - * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterMediaInput : MTRCluster +@interface MTRBaseClusterMediaPlayback (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -10925,7 +11247,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Media Input + * + * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterMediaInput : MTRGenericBaseCluster /** * Command SelectInput @@ -11009,13 +11341,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Low Power - * - * This cluster provides an interface for managing low power mode on a device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterLowPower : MTRCluster +@interface MTRBaseClusterMediaInput (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11023,7 +11349,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Low Power + * + * This cluster provides an interface for managing low power mode on a device. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterLowPower : MTRGenericBaseCluster /** * Command Sleep @@ -11075,13 +11411,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Keypad Input - * - * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterKeypadInput : MTRCluster +@interface MTRBaseClusterLowPower (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11089,7 +11419,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Keypad Input + * + * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterKeypadInput : MTRGenericBaseCluster /** * Command SendKey @@ -11139,13 +11479,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Content Launcher - * - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterContentLauncher : MTRCluster +@interface MTRBaseClusterKeypadInput (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11153,7 +11487,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Content Launcher + * + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterContentLauncher : MTRGenericBaseCluster /** * Command LaunchContent @@ -11223,13 +11567,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Audio Output - * - * This cluster provides an interface for controlling the Output on a media device such as a TV. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterAudioOutput : MTRCluster +@interface MTRBaseClusterContentLauncher (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11237,7 +11575,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Audio Output + * + * This cluster provides an interface for controlling the Output on a media device such as a TV. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterAudioOutput : MTRGenericBaseCluster /** * Command SelectOutput @@ -11305,13 +11653,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Application Launcher - * - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterApplicationLauncher : MTRCluster +@interface MTRBaseClusterAudioOutput (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11319,7 +11661,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Application Launcher + * + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterApplicationLauncher : MTRGenericBaseCluster /** * Command LaunchApp @@ -11395,13 +11747,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Application Basic - * - * This cluster provides information about an application running on a TV or media player device which is represented as an endpoint. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterApplicationBasic : MTRCluster +@interface MTRBaseClusterApplicationLauncher (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11409,7 +11755,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Application Basic + * + * This cluster provides information about an application running on a TV or media player device which is represented as an endpoint. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterApplicationBasic : MTRGenericBaseCluster - (void)readAttributeVendorNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeVendorNameWithParams:(MTRSubscribeParams *)params @@ -11500,13 +11856,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Account Login - * - * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App running on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make the user account on the Content App match the user account on the Client. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterAccountLogin : MTRCluster +@interface MTRBaseClusterApplicationBasic (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11514,7 +11864,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Account Login + * + * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App running on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make the user account on the Content App match the user account on the Client. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterAccountLogin : MTRGenericBaseCluster /** * Command GetSetupPIN @@ -11578,13 +11938,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Electrical Measurement - * - * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need to provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRBaseClusterElectricalMeasurement : MTRCluster +@interface MTRBaseClusterAccountLogin (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -11592,7 +11946,17 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Electrical Measurement + * + * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need to provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. + */ +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRBaseClusterElectricalMeasurement : MTRGenericBaseCluster /** * Command GetProfileInfoCommand @@ -12434,13 +12798,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Unit Testing - * - * The Test Cluster is meant to validate the generated code - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRBaseClusterUnitTesting : MTRCluster +@interface MTRBaseClusterElectricalMeasurement (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -12448,7 +12806,17 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Unit Testing + * + * The Test Cluster is meant to validate the generated code + */ +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRBaseClusterUnitTesting : MTRGenericBaseCluster /** * Command Test @@ -13311,13 +13679,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Sample MEI - * - * The Sample MEI cluster showcases a cluster manufacturer extensions - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRBaseClusterSampleMEI : MTRCluster +@interface MTRBaseClusterUnitTesting (Availability) /** * For all instance methods (reads, writes, commands) that take a completion, @@ -13325,7 +13687,17 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end + +/** + * Cluster Sample MEI + * + * The Sample MEI cluster showcases a cluster manufacturer extensions + */ +MTR_PROVISIONALLY_AVAILABLE +@interface MTRBaseClusterSampleMEI : MTRGenericBaseCluster /** * Command Ping @@ -13391,6 +13763,18 @@ MTR_PROVISIONALLY_AVAILABLE @end +@interface MTRBaseClusterSampleMEI (Availability) + +/** + * For all instance methods (reads, writes, commands) that take a completion, + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRBaseDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + MTR_DEPRECATED("Please use MTRBaseClusterBasicInformation", ios(16.1, 16.4), macos(13.0, 13.3), watchos(9.1, 9.4), tvos(16.1, 16.4)) @interface MTRBaseClusterBasic : MTRBaseClusterBasicInformation @end diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm index 390b5042da3c6b..f30f7792eb7f72 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm @@ -62,18 +62,6 @@ static void OnSuccessFn(void * context) // NOLINTBEGIN(clang-analyzer-cplusplus.NewDeleteLeaks): Linter is unable to locate the delete on these objects. @implementation MTRBaseClusterIdentify -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -718,18 +706,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterGroups -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params completion:(void (^)(MTRGroupsClusterAddGroupResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -1403,18 +1379,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterScenes -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params completion:(void (^)(MTRScenesClusterAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -2638,18 +2602,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOnOff -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)offWithCompletion:(MTRStatusCompletion)completion { [self offWithParams:nil completion:completion]; @@ -3732,18 +3684,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOnOffSwitchConfiguration -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeSwitchTypeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = OnOffSwitchConfiguration::Attributes::SwitchType::TypeInfo; @@ -4328,18 +4268,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterLevelControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -6280,18 +6208,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBinaryInputBasic -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeActiveTextWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = BinaryInputBasic::Attributes::ActiveText::TypeInfo; @@ -7553,18 +7469,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterPulseWidthModulation -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeGeneratedCommandListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = PulseWidthModulation::Attributes::GeneratedCommandList::TypeInfo; @@ -7785,18 +7689,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterDescriptor -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeDeviceTypeListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Descriptor::Attributes::DeviceTypeList::TypeInfo; @@ -8523,18 +8415,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBinding -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeBindingWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Binding::Attributes::Binding::TypeInfo; @@ -9085,18 +8965,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterAccessControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeACLWithParams:(MTRReadParams * _Nullable)params completion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = AccessControl::Attributes::Acl::TypeInfo; @@ -10046,18 +9914,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterActions -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -11027,18 +10883,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBasicInformation -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)mfgSpecificPingWithCompletion:(MTRStatusCompletion)completion { [self mfgSpecificPingWithParams:nil completion:completion]; @@ -13051,18 +12895,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOTASoftwareUpdateProvider -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -13567,18 +13399,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOTASoftwareUpdateRequestor -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)announceOTAProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOTAProviderParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -14362,18 +14182,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterLocalizationConfiguration -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeActiveLocaleWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = LocalizationConfiguration::Attributes::ActiveLocale::TypeInfo; @@ -14958,18 +14766,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterTimeFormatLocalization -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeHourFormatWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = TimeFormatLocalization::Attributes::HourFormat::TypeInfo; @@ -15661,18 +15457,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterUnitLocalization -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeTemperatureUnitWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = UnitLocalization::Attributes::TemperatureUnit::TypeInfo; @@ -16186,18 +15970,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterPowerSourceConfiguration -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeSourcesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = PowerSourceConfiguration::Attributes::Sources::TypeInfo; @@ -16675,18 +16447,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterPowerSource -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeStatusWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = PowerSource::Attributes::Status::TypeInfo; @@ -19330,18 +19090,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterGeneralCommissioning -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams *)params completion:(void (^)(MTRGeneralCommissioningClusterArmFailSafeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -20245,18 +19993,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterNetworkCommissioning -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)scanNetworksWithParams:(MTRNetworkCommissioningClusterScanNetworksParams * _Nullable)params completion:(void (^)(MTRNetworkCommissioningClusterScanNetworksResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -21569,18 +21305,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterDiagnosticLogs -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsRequestParams *)params completion:(void (^)(MTRDiagnosticLogsClusterRetrieveLogsResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -22021,18 +21745,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterGeneralDiagnostics -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -23137,18 +22849,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterSoftwareDiagnostics -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetWatermarksWithCompletion:(MTRStatusCompletion)completion { [self resetWatermarksWithParams:nil completion:completion]; @@ -23878,18 +23578,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterThreadNetworkDiagnostics -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil completion:completion]; @@ -28808,18 +28496,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterWiFiNetworkDiagnostics -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil completion:completion]; @@ -30188,18 +29864,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterEthernetNetworkDiagnostics -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithCompletion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil completion:completion]; @@ -31284,18 +30948,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterTimeSynchronization -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setUTCTimeWithParams:(MTRTimeSynchronizationClusterSetUTCTimeParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -32105,18 +31757,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterBridgedDeviceBasicInformation -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeVendorNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = BridgedDeviceBasicInformation::Attributes::VendorName::TypeInfo; @@ -33663,18 +33303,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterSwitch -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeNumberOfPositionsWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Switch::Attributes::NumberOfPositions::TypeInfo; @@ -34294,18 +33922,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterAdministratorCommissioning -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenCommissioningWindowParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -35031,18 +34647,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOperationalCredentials -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)attestationRequestWithParams:(MTROperationalCredentialsClusterAttestationRequestParams *)params completion:(void (^)(MTROperationalCredentialsClusterAttestationResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -36130,18 +35734,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterGroupKeyManagement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -37019,18 +36611,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterFixedLabel -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeLabelListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = FixedLabel::Attributes::LabelList::TypeInfo; @@ -37508,18 +37088,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterUserLabel -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeLabelListWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = UserLabel::Attributes::LabelList::TypeInfo; @@ -38055,18 +37623,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBooleanState -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeStateValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = BooleanState::Attributes::StateValue::TypeInfo; @@ -38544,18 +38100,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterICDManagement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)registerClientWithParams:(MTRICDManagementClusterRegisterClientParams *)params completion:(void (^)(MTRICDManagementClusterRegisterClientResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -39141,18 +38685,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterModeSelect -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -40098,18 +39630,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterLaundryWasherMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRLaundryWasherModeClusterChangeToModeParams *)params completion:(void (^)(MTRLaundryWasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -40565,18 +40085,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRefrigeratorAndTemperatureControlledCabinetMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeParams *)params completion:(void (^)(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -41032,18 +40540,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterLaundryWasherControls -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeSpinSpeedsWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = LaundryWasherControls::Attributes::SpinSpeeds::TypeInfo; @@ -41469,18 +40965,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRVCRunMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRVCRunModeClusterChangeToModeParams *)params completion:(void (^)(MTRRVCRunModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -41867,18 +41351,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRVCCleanMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRVCCleanModeClusterChangeToModeParams *)params completion:(void (^)(MTRRVCCleanModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -42265,18 +41737,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterTemperatureControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setTemperatureWithParams:(MTRTemperatureControlClusterSetTemperatureParams * _Nullable)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -42738,18 +42198,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRefrigeratorAlarm -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMaskWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = RefrigeratorAlarm::Attributes::Mask::TypeInfo; @@ -43078,18 +42526,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterDishwasherMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRDishwasherModeClusterChangeToModeParams *)params completion:(void (^)(MTRDishwasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -43545,18 +42981,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterAirQuality -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeAirQualityWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = AirQuality::Attributes::AirQuality::TypeInfo; @@ -43813,18 +43237,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterSmokeCOAlarm -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selfTestRequestWithCompletion:(MTRStatusCompletion)completion { [self selfTestRequestWithParams:nil completion:completion]; @@ -44570,18 +43982,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterDishwasherAlarm -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetWithParams:(MTRDishwasherAlarmClusterResetParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -44995,18 +44395,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterMicrowaveOvenMode -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeSupportedModesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = MicrowaveOvenMode::Attributes::SupportedModes::TypeInfo; @@ -45299,18 +44687,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterMicrowaveOvenControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setCookingParametersWithParams:(MTRMicrowaveOvenControlClusterSetCookingParametersParams * _Nullable)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -45760,18 +45136,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterOperationalState -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pauseWithCompletion:(void (^)(MTROperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion { [self pauseWithParams:nil completion:completion]; @@ -46321,18 +45685,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRVCOperationalState -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pauseWithCompletion:(void (^)(MTRRVCOperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion { [self pauseWithParams:nil completion:completion]; @@ -46882,18 +46234,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterHEPAFilterMonitoring -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetConditionWithCompletion:(MTRStatusCompletion)completion { [self resetConditionWithParams:nil completion:completion]; @@ -47392,18 +46732,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterActivatedCarbonFilterMonitoring -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetConditionWithCompletion:(MTRStatusCompletion)completion { [self resetConditionWithParams:nil completion:completion]; @@ -47902,18 +47230,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterDoorLock -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -52114,18 +51430,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterWindowCovering -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)upOrOpenWithCompletion:(MTRStatusCompletion)completion { [self upOrOpenWithParams:nil completion:completion]; @@ -54359,18 +53663,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBarrierControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierControlGoToPercentParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -55771,18 +55063,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterPumpConfigurationAndControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMaxPressureWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = PumpConfigurationAndControl::Attributes::MaxPressure::TypeInfo; @@ -57976,18 +57256,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterThermostat -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -62989,18 +62257,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterFanControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)stepWithParams:(MTRFanControlClusterStepParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -64503,18 +63759,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterThermostatUserInterfaceConfiguration -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeTemperatureDisplayModeWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = ThermostatUserInterfaceConfiguration::Attributes::TemperatureDisplayMode::TypeInfo; @@ -65242,18 +64486,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterColorControl -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -70393,18 +69625,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterBallastConfiguration -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributePhysicalMinLevelWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = BallastConfiguration::Attributes::PhysicalMinLevel::TypeInfo; @@ -72190,18 +71410,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterIlluminanceMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = IlluminanceMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -72963,18 +72171,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterTemperatureMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = TemperatureMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -73665,18 +72861,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterPressureMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = PressureMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -74722,18 +73906,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterFlowMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = FlowMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -75424,18 +74596,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterRelativeHumidityMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = RelativeHumidityMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -76126,18 +75286,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterOccupancySensing -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeOccupancyWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = OccupancySensing::Attributes::Occupancy::TypeInfo; @@ -77720,18 +76868,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterCarbonMonoxideConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = CarbonMonoxideConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -78348,18 +77484,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterCarbonDioxideConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = CarbonDioxideConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -78976,18 +78100,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterNitrogenDioxideConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = NitrogenDioxideConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -79604,18 +78716,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterOzoneConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = OzoneConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -80232,18 +79332,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterPM25ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Pm25ConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -80860,18 +79948,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterFormaldehydeConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = FormaldehydeConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -81488,18 +80564,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterPM1ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Pm1ConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -82116,18 +81180,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterPM10ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = Pm10ConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -82744,18 +81796,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterTotalVolatileOrganicCompoundsConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = TotalVolatileOrganicCompoundsConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -83372,18 +82412,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterRadonConcentrationMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMeasuredValueWithCompletion:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = RadonConcentrationMeasurement::Attributes::MeasuredValue::TypeInfo; @@ -84000,18 +83028,6 @@ + (void)readAttributeClusterRevisionWithClusterStateCache:(MTRClusterStateCacheC @implementation MTRBaseClusterWakeOnLAN -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeMACAddressWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = WakeOnLan::Attributes::MACAddress::TypeInfo; @@ -84492,18 +83508,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterChannel -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params completion:(void (^)(MTRChannelClusterChangeChannelResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -85215,18 +84219,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterTargetNavigator -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams *)params completion:(void (^)(MTRTargetNavigatorClusterNavigateTargetResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -85809,18 +84801,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterMediaPlayback -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)playWithCompletion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { [self playWithParams:nil completion:completion]; @@ -87142,18 +86122,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterMediaInput -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -87836,18 +86804,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterLowPower -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)sleepWithCompletion:(MTRStatusCompletion)completion { [self sleepWithParams:nil completion:completion]; @@ -88293,18 +87249,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterKeypadInput -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params completion:(void (^)(MTRKeypadInputClusterSendKeyResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -88745,18 +87689,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterContentLauncher -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *)params completion:(void (^)(MTRContentLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -89407,18 +88339,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterAudioOutput -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -90027,18 +88947,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterApplicationLauncher -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams * _Nullable)params completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -90731,18 +89639,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterApplicationBasic -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)readAttributeVendorNameWithCompletion:(void (^)(NSString * _Nullable value, NSError * _Nullable error))completion { using TypeInfo = ApplicationBasic::Attributes::VendorName::TypeInfo; @@ -91717,18 +90613,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterAccountLogin -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params completion:(void (^)(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -92244,18 +91128,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterElectricalMeasurement -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)getProfileInfoCommandWithCompletion:(MTRStatusCompletion)completion { [self getProfileInfoCommandWithParams:nil completion:completion]; @@ -102106,18 +100978,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterUnitTesting -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)testWithCompletion:(MTRStatusCompletion)completion { [self testWithParams:nil completion:completion]; @@ -112554,18 +111414,6 @@ - (nullable instancetype)initWithDevice:(MTRBaseDevice *)device @implementation MTRBaseClusterSampleMEI -- (instancetype)initWithDevice:(MTRBaseDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pingWithCompletion:(MTRStatusCompletion)completion { [self pingWithParams:nil completion:completion]; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_Internal.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_Internal.h index b5853b9f0b8f74..7528fbc95fdfd0 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_Internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters_Internal.h @@ -20,386 +20,5 @@ #import "MTRBaseClusters.h" #import "MTRBaseDevice.h" -@interface MTRBaseClusterIdentify () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterGroups () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterScenes () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOnOff () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOnOffSwitchConfiguration () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterLevelControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBinaryInputBasic () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPulseWidthModulation () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterDescriptor () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBinding () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterAccessControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterActions () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBasicInformation () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOTASoftwareUpdateProvider () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOTASoftwareUpdateRequestor () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterLocalizationConfiguration () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTimeFormatLocalization () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterUnitLocalization () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPowerSourceConfiguration () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPowerSource () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterGeneralCommissioning () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterNetworkCommissioning () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterDiagnosticLogs () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterGeneralDiagnostics () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterSoftwareDiagnostics () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterThreadNetworkDiagnostics () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterWiFiNetworkDiagnostics () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterEthernetNetworkDiagnostics () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTimeSynchronization () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBridgedDeviceBasicInformation () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterSwitch () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterAdministratorCommissioning () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOperationalCredentials () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterGroupKeyManagement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterFixedLabel () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterUserLabel () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBooleanState () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterICDManagement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterModeSelect () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterLaundryWasherMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRefrigeratorAndTemperatureControlledCabinetMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterLaundryWasherControls () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRVCRunMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRVCCleanMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTemperatureControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRefrigeratorAlarm () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterDishwasherMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterAirQuality () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterSmokeCOAlarm () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterDishwasherAlarm () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterMicrowaveOvenMode () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterMicrowaveOvenControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOperationalState () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRVCOperationalState () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterHEPAFilterMonitoring () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterActivatedCarbonFilterMonitoring () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterDoorLock () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterWindowCovering () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBarrierControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPumpConfigurationAndControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterThermostat () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterFanControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterThermostatUserInterfaceConfiguration () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterColorControl () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterBallastConfiguration () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterIlluminanceMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTemperatureMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPressureMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterFlowMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRelativeHumidityMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOccupancySensing () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterCarbonMonoxideConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterCarbonDioxideConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterNitrogenDioxideConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterOzoneConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPM25ConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterFormaldehydeConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPM1ConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterPM10ConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTotalVolatileOrganicCompoundsConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterRadonConcentrationMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterWakeOnLAN () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterChannel () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterTargetNavigator () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterMediaPlayback () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterMediaInput () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterLowPower () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterKeypadInput () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterContentLauncher () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterAudioOutput () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterApplicationLauncher () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterApplicationBasic () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterAccountLogin () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterElectricalMeasurement () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterUnitTesting () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end - -@interface MTRBaseClusterSampleMEI () -@property (nonatomic, strong, readonly) MTRBaseDevice * device; -@end +// Nothing here for now, but leaving this file in place in case we need to add +// something. diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h index 19bdd9d688f301..9b58b2c32f3376 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h @@ -28,20 +28,7 @@ NS_ASSUME_NONNULL_BEGIN * Attributes and commands for putting a device into Identification mode (e.g. flashing a light). */ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterIdentify : MTRCluster - -/** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - -/** - * The device this cluster object is associated with. - */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +@interface MTRClusterIdentify : MTRGenericCluster - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)triggerEffectWithParams:(MTRIdentifyClusterTriggerEffectParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -69,12 +56,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Groups - * Attributes and commands for group configuration and manipulation. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterGroups : MTRCluster +@interface MTRClusterIdentify (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -82,12 +64,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Groups + * Attributes and commands for group configuration and manipulation. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterGroups : MTRGenericCluster - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGroupsClusterAddGroupResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)viewGroupWithParams:(MTRGroupsClusterViewGroupParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGroupsClusterViewGroupResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -117,12 +103,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Scenes - * Attributes and commands for scene configuration and manipulation. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterScenes : MTRCluster +@interface MTRClusterGroups (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -130,12 +111,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Scenes + * Attributes and commands for scene configuration and manipulation. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterScenes : MTRGenericCluster - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRScenesClusterAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)viewSceneWithParams:(MTRScenesClusterViewSceneParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRScenesClusterViewSceneResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -181,12 +166,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster On/Off - * Attributes and commands for switching devices between 'On' and 'Off' states. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterOnOff : MTRCluster +@interface MTRClusterScenes (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -194,12 +174,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster On/Off + * Attributes and commands for switching devices between 'On' and 'Off' states. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterOnOff : MTRGenericCluster - (void)offWithParams:(MTROnOffClusterOffParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)offWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -249,25 +233,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster On/off Switch Configuration - * Attributes and commands for configuring On/Off switching devices. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterOnOffSwitchConfiguration : MTRCluster +@interface MTRClusterOnOff (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster On/off Switch Configuration + * Attributes and commands for configuring On/Off switching devices. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterOnOffSwitchConfiguration : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeSwitchTypeWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -292,25 +275,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Level Control - * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterLevelControl : MTRCluster +@interface MTRClusterOnOffSwitchConfiguration (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Level Control + * Attributes and commands for controlling devices that can be set to a level between fully 'On' and fully 'Off.' */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterLevelControl : MTRGenericCluster - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)moveWithParams:(MTRLevelControlClusterMoveParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -381,25 +363,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Binary Input (Basic) - * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterBinaryInputBasic : MTRCluster +@interface MTRClusterLevelControl (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Binary Input (Basic) + * An interface for reading the value of a binary measurement and accessing various characteristics of that measurement. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterBinaryInputBasic : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeActiveTextWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeActiveTextWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -448,12 +429,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pulse Width Modulation - * Cluster to control pulse width modulation - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterPulseWidthModulation : MTRCluster +@interface MTRClusterBinaryInputBasic (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -461,12 +437,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Pulse Width Modulation + * Cluster to control pulse width modulation */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterPulseWidthModulation : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeGeneratedCommandListWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -485,12 +465,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Descriptor - * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterDescriptor : MTRCluster +@interface MTRClusterPulseWidthModulation (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -498,12 +473,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Descriptor + * The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterDescriptor : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeDeviceTypeListWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -532,12 +511,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Binding - * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterBinding : MTRCluster +@interface MTRClusterDescriptor (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -545,12 +519,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Binding + * The Binding Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for supporting the binding table. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterBinding : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeBindingWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeBindingWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -573,15 +551,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Access Control - * The Access Control Cluster exposes a data model view of a - Node's Access Control List (ACL), which codifies the rules used to manage - and enforce Access Control for the Node's endpoints and their associated - cluster instances. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterAccessControl : MTRCluster +@interface MTRClusterBinding (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -589,12 +559,19 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Access Control + * The Access Control Cluster exposes a data model view of a + Node's Access Control List (ACL), which codifies the rules used to manage + and enforce Access Control for the Node's endpoints and their associated + cluster instances. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterAccessControl : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeACLWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)writeAttributeACLWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -627,25 +604,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Actions - * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterActions : MTRCluster +@interface MTRClusterAccessControl (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Actions + * This cluster provides a standardized way for a Node (typically a Bridge, but could be any Node) to expose action information. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterActions : MTRGenericCluster - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)instantActionWithTransitionWithParams:(MTRActionsClusterInstantActionWithTransitionParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -683,14 +659,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Basic Information - * This cluster provides attributes and events for determining basic information about Nodes, which supports both - Commissioning and operational determination of Node characteristics, such as Vendor ID, Product ID and serial number, - which apply to the whole Node. Also allows setting user device information such as location. - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterBasicInformation : MTRCluster +@interface MTRClusterActions (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -698,12 +667,18 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Basic Information + * This cluster provides attributes and events for determining basic information about Nodes, which supports both + Commissioning and operational determination of Node characteristics, such as Vendor ID, Product ID and serial number, + which apply to the whole Node. Also allows setting user device information such as location. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterBasicInformation : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeDataModelRevisionWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -770,12 +745,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster OTA Software Update Provider - * Provides an interface for providing OTA software updates - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterOTASoftwareUpdateProvider : MTRCluster +@interface MTRClusterBasicInformation (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -783,12 +753,16 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster OTA Software Update Provider + * Provides an interface for providing OTA software updates */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterOTASoftwareUpdateProvider : MTRGenericCluster - (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)applyUpdateRequestWithParams:(MTROTASoftwareUpdateProviderClusterApplyUpdateRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROTASoftwareUpdateProviderClusterApplyUpdateResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -811,12 +785,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster OTA Software Update Requestor - * Provides an interface for downloading and applying OTA software updates - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterOTASoftwareUpdateRequestor : MTRCluster +@interface MTRClusterOTASoftwareUpdateProvider (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -824,12 +793,16 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster OTA Software Update Requestor + * Provides an interface for downloading and applying OTA software updates */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterOTASoftwareUpdateRequestor : MTRGenericCluster - (void)announceOTAProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOTAProviderParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -860,28 +833,27 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Localization Configuration - * Nodes should be expected to be deployed to any and all regions of the world. These global regions - may have differing common languages, units of measurements, and numerical formatting - standards. As such, Nodes that visually or audibly convey information need a mechanism by which - they can be configured to use a user’s preferred language, units, etc - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterLocalizationConfiguration : MTRCluster +@interface MTRClusterOTASoftwareUpdateRequestor (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Localization Configuration + * Nodes should be expected to be deployed to any and all regions of the world. These global regions + may have differing common languages, units of measurements, and numerical formatting + standards. As such, Nodes that visually or audibly convey information need a mechanism by which + they can be configured to use a user’s preferred language, units, etc */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterLocalizationConfiguration : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeActiveLocaleWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeActiveLocaleWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -906,15 +878,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Time Format Localization - * Nodes should be expected to be deployed to any and all regions of the world. These global regions - may have differing preferences for how dates and times are conveyed. As such, Nodes that visually - or audibly convey time information need a mechanism by which they can be configured to use a - user’s preferred format. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterTimeFormatLocalization : MTRCluster +@interface MTRClusterLocalizationConfiguration (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -922,12 +886,19 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Time Format Localization + * Nodes should be expected to be deployed to any and all regions of the world. These global regions + may have differing preferences for how dates and times are conveyed. As such, Nodes that visually + or audibly convey time information need a mechanism by which they can be configured to use a + user’s preferred format. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterTimeFormatLocalization : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeHourFormatWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeHourFormatWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -956,15 +927,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Unit Localization - * Nodes should be expected to be deployed to any and all regions of the world. These global regions - may have differing preferences for the units in which values are conveyed in communication to a - user. As such, Nodes that visually or audibly convey measurable values to the user need a - mechanism by which they can be configured to use a user’s preferred unit. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterUnitLocalization : MTRCluster +@interface MTRClusterTimeFormatLocalization (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -972,12 +935,19 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Unit Localization + * Nodes should be expected to be deployed to any and all regions of the world. These global regions + may have differing preferences for the units in which values are conveyed in communication to a + user. As such, Nodes that visually or audibly convey measurable values to the user need a + mechanism by which they can be configured to use a user’s preferred unit. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterUnitLocalization : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeTemperatureUnitWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeTemperatureUnitWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -1000,12 +970,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Power Source Configuration - * This cluster is used to describe the configuration and capabilities of a Device's power system. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterPowerSourceConfiguration : MTRCluster +@interface MTRClusterUnitLocalization (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -1013,12 +978,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Power Source Configuration + * This cluster is used to describe the configuration and capabilities of a Device's power system. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterPowerSourceConfiguration : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeSourcesWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -1039,12 +1008,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Power Source - * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the Node. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterPowerSource : MTRCluster +@interface MTRClusterPowerSourceConfiguration (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -1052,12 +1016,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Power Source + * This cluster is used to describe the configuration and capabilities of a physical power source that provides power to the Node. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterPowerSource : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeStatusWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -1140,25 +1108,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end +@interface MTRClusterPowerSource (Availability) + /** - * Cluster General Commissioning - * This cluster is used to manage global aspects of the Commissioning flow. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterGeneralCommissioning : MTRCluster +- (instancetype _Nullable)initWithDevice:(MTRDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); -/** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. - */ -- (instancetype _Nullable)initWithDevice:(MTRDevice *)device - endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +@end /** - * The device this cluster object is associated with. + * Cluster General Commissioning + * This cluster is used to manage global aspects of the Commissioning flow. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterGeneralCommissioning : MTRGenericCluster - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralCommissioningClusterArmFailSafeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)setRegulatoryConfigWithParams:(MTRGeneralCommissioningClusterSetRegulatoryConfigParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralCommissioningClusterSetRegulatoryConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1195,12 +1162,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Network Commissioning - * Functionality to configure, enable, disable network credentials and access on a Matter device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterNetworkCommissioning : MTRCluster +@interface MTRClusterGeneralCommissioning (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1208,12 +1170,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Network Commissioning + * Functionality to configure, enable, disable network credentials and access on a Matter device. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterNetworkCommissioning : MTRGenericCluster - (void)scanNetworksWithParams:(MTRNetworkCommissioningClusterScanNetworksParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRNetworkCommissioningClusterScanNetworksResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)addOrUpdateWiFiNetworkWithParams:(MTRNetworkCommissioningClusterAddOrUpdateWiFiNetworkParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRNetworkCommissioningClusterNetworkConfigResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1263,12 +1229,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Diagnostic Logs - * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterDiagnosticLogs : MTRCluster +@interface MTRClusterNetworkCommissioning (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1276,12 +1237,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Diagnostic Logs + * The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterDiagnosticLogs : MTRGenericCluster - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRDiagnosticLogsClusterRetrieveLogsResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1302,12 +1267,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster General Diagnostics - * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterGeneralDiagnostics : MTRCluster +@interface MTRClusterDiagnosticLogs (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1315,12 +1275,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster General Diagnostics + * The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterGeneralDiagnostics : MTRGenericCluster - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)timeSnapshotWithParams:(MTRGeneralDiagnosticsClusterTimeSnapshotParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -1362,12 +1326,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Software Diagnostics - * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterSoftwareDiagnostics : MTRCluster +@interface MTRClusterGeneralDiagnostics (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1375,12 +1334,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Software Diagnostics + * The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterSoftwareDiagnostics : MTRGenericCluster - (void)resetWatermarksWithParams:(MTRSoftwareDiagnosticsClusterResetWatermarksParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)resetWatermarksWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -1411,12 +1374,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thread Network Diagnostics - * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterThreadNetworkDiagnostics : MTRCluster +@interface MTRClusterSoftwareDiagnostics (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1424,12 +1382,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Thread Network Diagnostics + * The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterThreadNetworkDiagnostics : MTRGenericCluster - (void)resetCountsWithParams:(MTRThreadNetworkDiagnosticsClusterResetCountsParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)resetCountsWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -1578,12 +1540,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster WiFi Network Diagnostics - * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterWiFiNetworkDiagnostics : MTRCluster +@interface MTRClusterThreadNetworkDiagnostics (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1591,12 +1548,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster WiFi Network Diagnostics + * The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterWiFiNetworkDiagnostics : MTRGenericCluster - (void)resetCountsWithParams:(MTRWiFiNetworkDiagnosticsClusterResetCountsParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)resetCountsWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -1645,12 +1606,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Ethernet Network Diagnostics - * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterEthernetNetworkDiagnostics : MTRCluster +@interface MTRClusterWiFiNetworkDiagnostics (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1658,12 +1614,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Ethernet Network Diagnostics + * The Ethernet Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterEthernetNetworkDiagnostics : MTRGenericCluster - (void)resetCountsWithParams:(MTREthernetNetworkDiagnosticsClusterResetCountsParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)resetCountsWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -1704,12 +1664,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Time Synchronization - * Accurate time is required for a number of reasons, including scheduling, display and validating security materials. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterTimeSynchronization : MTRCluster +@interface MTRClusterEthernetNetworkDiagnostics (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1717,12 +1672,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Time Synchronization + * Accurate time is required for a number of reasons, including scheduling, display and validating security materials. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterTimeSynchronization : MTRGenericCluster - (void)setUTCTimeWithParams:(MTRTimeSynchronizationClusterSetUTCTimeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)setTrustedTimeSourceWithParams:(MTRTimeSynchronizationClusterSetTrustedTimeSourceParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -1773,28 +1732,27 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Bridged Device Basic Information - * This Cluster serves two purposes towards a Node communicating with a Bridge: indicate that the functionality on - the Endpoint where it is placed (and its Parts) is bridged from a non-CHIP technology; and provide a centralized - collection of attributes that the Node MAY collect to aid in conveying information regarding the Bridged Device to a user, - such as the vendor name, the model name, or user-assigned name. - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterBridgedDeviceBasicInformation : MTRCluster +@interface MTRClusterTimeSynchronization (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Bridged Device Basic Information + * This Cluster serves two purposes towards a Node communicating with a Bridge: indicate that the functionality on + the Endpoint where it is placed (and its Parts) is bridged from a non-CHIP technology; and provide a centralized + collection of attributes that the Node MAY collect to aid in conveying information regarding the Bridged Device to a user, + such as the vendor name, the model name, or user-assigned name. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterBridgedDeviceBasicInformation : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeVendorNameWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1847,14 +1805,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Switch - * This cluster exposes interactions with a switch device, for the purpose of using those interactions by other devices. -Two types of switch devices are supported: latching switch (e.g. rocker switch) and momentary switch (e.g. push button), distinguished with their feature flags. -Interactions with the switch device are exposed as attributes (for the latching switch) and as events (for both types of switches). An interested party MAY subscribe to these attributes/events and thus be informed of the interactions, and can perform actions based on this, for example by sending commands to perform an action such as controlling a light or a window shade. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterSwitch : MTRCluster +@interface MTRClusterBridgedDeviceBasicInformation (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -1862,12 +1813,18 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Switch + * This cluster exposes interactions with a switch device, for the purpose of using those interactions by other devices. +Two types of switch devices are supported: latching switch (e.g. rocker switch) and momentary switch (e.g. push button), distinguished with their feature flags. +Interactions with the switch device are exposed as attributes (for the latching switch) and as events (for both types of switches). An interested party MAY subscribe to these attributes/events and thus be informed of the interactions, and can perform actions based on this, for example by sending commands to perform an action such as controlling a light or a window shade. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterSwitch : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeNumberOfPositionsWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -1892,25 +1849,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Administrator Commissioning - * Commands to trigger a Node to allow a new Administrator to commission it. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterAdministratorCommissioning : MTRCluster +@interface MTRClusterSwitch (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Administrator Commissioning + * Commands to trigger a Node to allow a new Administrator to commission it. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterAdministratorCommissioning : MTRGenericCluster - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenCommissioningWindowParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)openBasicCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenBasicCommissioningWindowParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1941,12 +1897,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Operational Credentials - * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated Fabrics. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterOperationalCredentials : MTRCluster +@interface MTRClusterAdministratorCommissioning (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -1954,12 +1905,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Operational Credentials + * This cluster is used to add or remove Operational Credentials on a Commissionee or Node, as well as manage the associated Fabrics. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterOperationalCredentials : MTRGenericCluster - (void)attestationRequestWithParams:(MTROperationalCredentialsClusterAttestationRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROperationalCredentialsClusterAttestationResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)certificateChainRequestWithParams:(MTROperationalCredentialsClusterCertificateChainRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROperationalCredentialsClusterCertificateChainResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -1999,12 +1954,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Group Key Management - * The Group Key Management Cluster is the mechanism by which group keys are managed. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterGroupKeyManagement : MTRCluster +@interface MTRClusterOperationalCredentials (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2012,12 +1962,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Group Key Management + * The Group Key Management Cluster is the mechanism by which group keys are managed. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterGroupKeyManagement : MTRGenericCluster - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)keySetReadWithParams:(MTRGroupKeyManagementClusterKeySetReadParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGroupKeyManagementClusterKeySetReadResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -2053,26 +2007,25 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Fixed Label - * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only -labels. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterFixedLabel : MTRCluster +@interface MTRClusterGroupKeyManagement (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Fixed Label + * The Fixed Label Cluster provides a feature for the device to tag an endpoint with zero or more read only +labels. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterFixedLabel : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeLabelListWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -2093,12 +2046,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster User Label - * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterUserLabel : MTRCluster +@interface MTRClusterFixedLabel (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -2106,12 +2054,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster User Label + * The User Label Cluster provides a feature to tag an endpoint with zero or more labels. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterUserLabel : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeLabelListWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeLabelListWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -2134,12 +2086,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Boolean State - * This cluster provides an interface to a boolean state called StateValue. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterBooleanState : MTRCluster +@interface MTRClusterUserLabel (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -2147,12 +2094,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Boolean State + * This cluster provides an interface to a boolean state called StateValue. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterBooleanState : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeStateValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -2173,25 +2124,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster ICD Management - * Allows servers to ensure that listed clients are notified when a server is available for communication. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterICDManagement : MTRCluster +@interface MTRClusterBooleanState (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster ICD Management + * Allows servers to ensure that listed clients are notified when a server is available for communication. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterICDManagement : MTRGenericCluster - (void)registerClientWithParams:(MTRICDManagementClusterRegisterClientParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRICDManagementClusterRegisterClientResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)unregisterClientWithParams:(MTRICDManagementClusterUnregisterClientParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -2232,12 +2182,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Mode Select - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterModeSelect : MTRCluster +@interface MTRClusterICDManagement (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2245,12 +2190,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Mode Select + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterModeSelect : MTRGenericCluster - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -2287,12 +2236,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Laundry Washer Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterLaundryWasherMode : MTRCluster +@interface MTRClusterModeSelect (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2300,12 +2244,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Laundry Washer Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterLaundryWasherMode : MTRGenericCluster - (void)changeToModeWithParams:(MTRLaundryWasherModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRLaundryWasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -2338,12 +2286,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Refrigerator And Temperature Controlled Cabinet Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRefrigeratorAndTemperatureControlledCabinetMode : MTRCluster +@interface MTRClusterLaundryWasherMode (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2351,12 +2294,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Refrigerator And Temperature Controlled Cabinet Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRefrigeratorAndTemperatureControlledCabinetMode : MTRGenericCluster - (void)changeToModeWithParams:(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -2389,25 +2336,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Laundry Washer Controls - * This cluster supports remotely monitoring and controling the different typs of functionality available to a washing device, such as a washing machine. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterLaundryWasherControls : MTRCluster +@interface MTRClusterRefrigeratorAndTemperatureControlledCabinetMode (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Laundry Washer Controls + * This cluster supports remotely monitoring and controling the different typs of functionality available to a washing device, such as a washing machine. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterLaundryWasherControls : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeSpinSpeedsWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -2438,25 +2384,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Run Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRVCRunMode : MTRCluster +@interface MTRClusterLaundryWasherControls (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster RVC Run Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRVCRunMode : MTRGenericCluster - (void)changeToModeWithParams:(MTRRVCRunModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCRunModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -2485,12 +2430,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Clean Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRVCCleanMode : MTRCluster +@interface MTRClusterRVCRunMode (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2498,12 +2438,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster RVC Clean Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRVCCleanMode : MTRGenericCluster - (void)changeToModeWithParams:(MTRRVCCleanModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCCleanModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -2532,12 +2476,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Temperature Control - * Attributes and commands for configuring the temperature control, and reporting temperature. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterTemperatureControl : MTRCluster +@interface MTRClusterRVCCleanMode (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2545,12 +2484,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Temperature Control + * Attributes and commands for configuring the temperature control, and reporting temperature. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterTemperatureControl : MTRGenericCluster - (void)setTemperatureWithParams:(MTRTemperatureControlClusterSetTemperatureParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -2583,25 +2526,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Refrigerator Alarm - * Attributes and commands for configuring the Refrigerator alarm. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRefrigeratorAlarm : MTRCluster +@interface MTRClusterTemperatureControl (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Refrigerator Alarm + * Attributes and commands for configuring the Refrigerator alarm. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRefrigeratorAlarm : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMaskWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -2626,25 +2568,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Dishwasher Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterDishwasherMode : MTRCluster +@interface MTRClusterRefrigeratorAlarm (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Dishwasher Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterDishwasherMode : MTRGenericCluster - (void)changeToModeWithParams:(MTRDishwasherModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRDishwasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; @@ -2677,25 +2618,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Air Quality - * Attributes for reporting air quality classification - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterAirQuality : MTRCluster +@interface MTRClusterDishwasherMode (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Air Quality + * Attributes for reporting air quality classification */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterAirQuality : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeAirQualityWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -2716,25 +2656,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Smoke CO Alarm - * This cluster provides an interface for observing and managing the state of smoke and CO alarms. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterSmokeCOAlarm : MTRCluster +@interface MTRClusterAirQuality (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Smoke CO Alarm + * This cluster provides an interface for observing and managing the state of smoke and CO alarms. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterSmokeCOAlarm : MTRGenericCluster - (void)selfTestRequestWithParams:(MTRSmokeCOAlarmClusterSelfTestRequestParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)selfTestRequestWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -2785,12 +2724,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Dishwasher Alarm - * Attributes and commands for configuring the Dishwasher alarm. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterDishwasherAlarm : MTRCluster +@interface MTRClusterSmokeCOAlarm (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2798,12 +2732,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Dishwasher Alarm + * Attributes and commands for configuring the Dishwasher alarm. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterDishwasherAlarm : MTRGenericCluster - (void)resetWithParams:(MTRDishwasherAlarmClusterResetParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)modifyEnabledAlarmsWithParams:(MTRDishwasherAlarmClusterModifyEnabledAlarmsParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -2833,25 +2771,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Microwave Oven Mode - * Attributes and commands for selecting a mode from a list of supported options. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterMicrowaveOvenMode : MTRCluster +@interface MTRClusterDishwasherAlarm (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Microwave Oven Mode + * Attributes and commands for selecting a mode from a list of supported options. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterMicrowaveOvenMode : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeSupportedModesWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -2874,25 +2811,24 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Microwave Oven Control - * Attributes and commands for configuring the microwave oven control, and reporting cooking stats. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterMicrowaveOvenControl : MTRCluster +@interface MTRClusterMicrowaveOvenMode (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Microwave Oven Control + * Attributes and commands for configuring the microwave oven control, and reporting cooking stats. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterMicrowaveOvenControl : MTRGenericCluster - (void)setCookingParametersWithParams:(MTRMicrowaveOvenControlClusterSetCookingParametersParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)addMoreTimeWithParams:(MTRMicrowaveOvenControlClusterAddMoreTimeParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -2924,12 +2860,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Operational State - * This cluster supports remotely monitoring and, where supported, changing the operational state of any device where a state machine is a part of the operation. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterOperationalState : MTRCluster +@interface MTRClusterMicrowaveOvenControl (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2937,12 +2868,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Operational State + * This cluster supports remotely monitoring and, where supported, changing the operational state of any device where a state machine is a part of the operation. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterOperationalState : MTRGenericCluster - (void)pauseWithParams:(MTROperationalStateClusterPauseParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)pauseWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion @@ -2986,12 +2921,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster RVC Operational State - * This cluster supports remotely monitoring and, where supported, changing the operational state of a Robotic Vacuum. - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRVCOperationalState : MTRCluster +@interface MTRClusterOperationalState (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -2999,12 +2929,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster RVC Operational State + * This cluster supports remotely monitoring and, where supported, changing the operational state of a Robotic Vacuum. */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRVCOperationalState : MTRGenericCluster - (void)pauseWithParams:(MTRRVCOperationalStateClusterPauseParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCOperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; - (void)pauseWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCOperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion @@ -3048,12 +2982,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster HEPA Filter Monitoring - * Attributes and commands for monitoring HEPA filters in a device - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterHEPAFilterMonitoring : MTRCluster +@interface MTRClusterRVCOperationalState (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3061,12 +2990,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster HEPA Filter Monitoring + * Attributes and commands for monitoring HEPA filters in a device */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterHEPAFilterMonitoring : MTRGenericCluster - (void)resetConditionWithParams:(MTRHEPAFilterMonitoringClusterResetConditionParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)resetConditionWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -3103,12 +3036,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Activated Carbon Filter Monitoring - * Attributes and commands for monitoring activated carbon filters in a device - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterActivatedCarbonFilterMonitoring : MTRCluster +@interface MTRClusterHEPAFilterMonitoring (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3116,12 +3044,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Activated Carbon Filter Monitoring + * Attributes and commands for monitoring activated carbon filters in a device */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterActivatedCarbonFilterMonitoring : MTRGenericCluster - (void)resetConditionWithParams:(MTRActivatedCarbonFilterMonitoringClusterResetConditionParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)resetConditionWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -3158,12 +3090,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Door Lock - * An interface to a generic way to secure a door - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterDoorLock : MTRCluster +@interface MTRClusterActivatedCarbonFilterMonitoring (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3171,12 +3098,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Door Lock + * An interface to a generic way to secure a door */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterDoorLock : MTRGenericCluster - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)unlockDoorWithParams:(MTRDoorLockClusterUnlockDoorParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -3323,12 +3254,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Window Covering - * Provides an interface for controlling and adjusting automatic window coverings. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterWindowCovering : MTRCluster +@interface MTRClusterDoorLock (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3336,12 +3262,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Window Covering + * Provides an interface for controlling and adjusting automatic window coverings. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterWindowCovering : MTRGenericCluster - (void)upOrOpenWithParams:(MTRWindowCoveringClusterUpOrOpenParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)upOrOpenWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -3420,12 +3350,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Barrier Control - * This cluster provides control of a barrier (garage door). - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterBarrierControl : MTRCluster +@interface MTRClusterWindowCovering (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3433,12 +3358,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Barrier Control + * This cluster provides control of a barrier (garage door). */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterBarrierControl : MTRGenericCluster - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierControlGoToPercentParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)barrierControlStopWithParams:(MTRBarrierControlClusterBarrierControlStopParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -3494,25 +3423,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pump Configuration and Control - * An interface for configuring and controlling pumps. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterPumpConfigurationAndControl : MTRCluster +@interface MTRClusterBarrierControl (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Pump Configuration and Control + * An interface for configuring and controlling pumps. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterPumpConfigurationAndControl : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMaxPressureWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -3585,25 +3513,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thermostat - * An interface for configuring and controlling the functionality of a thermostat. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterThermostat : MTRCluster +@interface MTRClusterPumpConfigurationAndControl (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Thermostat + * An interface for configuring and controlling the functionality of a thermostat. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterThermostat : MTRGenericCluster - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)setWeeklyScheduleWithParams:(MTRThermostatClusterSetWeeklyScheduleParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -3781,12 +3708,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Fan Control - * An interface for controlling a fan in a heating/cooling system. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterFanControl : MTRCluster +@interface MTRClusterThermostat (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -3794,12 +3716,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Fan Control + * An interface for controlling a fan in a heating/cooling system. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterFanControl : MTRGenericCluster - (void)stepWithParams:(MTRFanControlClusterStepParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; @@ -3858,25 +3784,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Thermostat User Interface Configuration - * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterThermostatUserInterfaceConfiguration : MTRCluster +@interface MTRClusterFanControl (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Thermostat User Interface Configuration + * An interface for configuring the user interface of a thermostat (which may be remote from the thermostat). */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterThermostatUserInterfaceConfiguration : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeTemperatureDisplayModeWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - (void)writeAttributeTemperatureDisplayModeWithValue:(NSDictionary *)dataValueDictionary expectedValueInterval:(NSNumber *)expectedValueIntervalMs MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -3907,25 +3832,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Color Control - * Attributes and commands for controlling the color properties of a color-capable light. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterColorControl : MTRCluster +@interface MTRClusterThermostatUserInterfaceConfiguration (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Color Control + * Attributes and commands for controlling the color properties of a color-capable light. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterColorControl : MTRGenericCluster - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)moveHueWithParams:(MTRColorControlClusterMoveHueParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -4094,25 +4018,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Ballast Configuration - * Attributes and commands for configuring a lighting ballast. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterBallastConfiguration : MTRCluster +@interface MTRClusterColorControl (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Ballast Configuration + * Attributes and commands for configuring a lighting ballast. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterBallastConfiguration : MTRGenericCluster - (NSDictionary * _Nullable)readAttributePhysicalMinLevelWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4179,12 +4102,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Illuminance Measurement - * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterIlluminanceMeasurement : MTRCluster +@interface MTRClusterBallastConfiguration (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4192,12 +4110,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Illuminance Measurement + * Attributes and commands for configuring the measurement of illuminance, and reporting illuminance measurements. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterIlluminanceMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4226,12 +4148,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Temperature Measurement - * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterTemperatureMeasurement : MTRCluster +@interface MTRClusterIlluminanceMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4239,12 +4156,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Temperature Measurement + * Attributes and commands for configuring the measurement of temperature, and reporting temperature measurements. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterTemperatureMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4271,12 +4192,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Pressure Measurement - * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterPressureMeasurement : MTRCluster +@interface MTRClusterTemperatureMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4284,12 +4200,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Pressure Measurement + * Attributes and commands for configuring the measurement of pressure, and reporting pressure measurements. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterPressureMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4326,12 +4246,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Flow Measurement - * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterFlowMeasurement : MTRCluster +@interface MTRClusterPressureMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4339,12 +4254,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Flow Measurement + * Attributes and commands for configuring the measurement of flow, and reporting flow measurements. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterFlowMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4371,12 +4290,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Relative Humidity Measurement - * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterRelativeHumidityMeasurement : MTRCluster +@interface MTRClusterFlowMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4384,12 +4298,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Relative Humidity Measurement + * Attributes and commands for configuring the measurement of relative humidity, and reporting relative humidity measurements. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterRelativeHumidityMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4416,12 +4334,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Occupancy Sensing - * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterOccupancySensing : MTRCluster +@interface MTRClusterRelativeHumidityMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4429,12 +4342,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Occupancy Sensing + * Attributes and commands for configuring occupancy sensing, and reporting occupancy status. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterOccupancySensing : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeOccupancyWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -4495,12 +4412,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Carbon Monoxide Concentration Measurement - * Attributes for reporting carbon monoxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterCarbonMonoxideConcentrationMeasurement : MTRCluster +@interface MTRClusterOccupancySensing (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4508,12 +4420,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Carbon Monoxide Concentration Measurement + * Attributes for reporting carbon monoxide concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterCarbonMonoxideConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4554,12 +4470,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Carbon Dioxide Concentration Measurement - * Attributes for reporting carbon dioxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterCarbonDioxideConcentrationMeasurement : MTRCluster +@interface MTRClusterCarbonMonoxideConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4567,12 +4478,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Carbon Dioxide Concentration Measurement + * Attributes for reporting carbon dioxide concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterCarbonDioxideConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4613,12 +4528,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Nitrogen Dioxide Concentration Measurement - * Attributes for reporting nitrogen dioxide concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterNitrogenDioxideConcentrationMeasurement : MTRCluster +@interface MTRClusterCarbonDioxideConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4626,12 +4536,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Nitrogen Dioxide Concentration Measurement + * Attributes for reporting nitrogen dioxide concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterNitrogenDioxideConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4672,12 +4586,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Ozone Concentration Measurement - * Attributes for reporting ozone concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterOzoneConcentrationMeasurement : MTRCluster +@interface MTRClusterNitrogenDioxideConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4685,12 +4594,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Ozone Concentration Measurement + * Attributes for reporting ozone concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterOzoneConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4731,12 +4644,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM2.5 Concentration Measurement - * Attributes for reporting PM2.5 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterPM25ConcentrationMeasurement : MTRCluster +@interface MTRClusterOzoneConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4744,12 +4652,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster PM2.5 Concentration Measurement + * Attributes for reporting PM2.5 concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterPM25ConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4790,12 +4702,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Formaldehyde Concentration Measurement - * Attributes for reporting formaldehyde concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterFormaldehydeConcentrationMeasurement : MTRCluster +@interface MTRClusterPM25ConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4803,12 +4710,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Formaldehyde Concentration Measurement + * Attributes for reporting formaldehyde concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterFormaldehydeConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4849,12 +4760,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM1 Concentration Measurement - * Attributes for reporting PM1 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterPM1ConcentrationMeasurement : MTRCluster +@interface MTRClusterFormaldehydeConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4862,12 +4768,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster PM1 Concentration Measurement + * Attributes for reporting PM1 concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterPM1ConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4908,12 +4818,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster PM10 Concentration Measurement - * Attributes for reporting PM10 concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterPM10ConcentrationMeasurement : MTRCluster +@interface MTRClusterPM1ConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4921,12 +4826,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster PM10 Concentration Measurement + * Attributes for reporting PM10 concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterPM10ConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -4967,12 +4876,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Total Volatile Organic Compounds Concentration Measurement - * Attributes for reporting total volatile organic compounds concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterTotalVolatileOrganicCompoundsConcentrationMeasurement : MTRCluster +@interface MTRClusterPM10ConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -4980,12 +4884,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Total Volatile Organic Compounds Concentration Measurement + * Attributes for reporting total volatile organic compounds concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterTotalVolatileOrganicCompoundsConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -5026,12 +4934,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Radon Concentration Measurement - * Attributes for reporting radon concentration measurements - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterRadonConcentrationMeasurement : MTRCluster +@interface MTRClusterTotalVolatileOrganicCompoundsConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -5039,12 +4942,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Radon Concentration Measurement + * Attributes for reporting radon concentration measurements */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterRadonConcentrationMeasurement : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params MTR_PROVISIONALLY_AVAILABLE; @@ -5085,12 +4992,7 @@ MTR_PROVISIONALLY_AVAILABLE @end -/** - * Cluster Wake on LAN - * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterWakeOnLAN : MTRCluster +@interface MTRClusterRadonConcentrationMeasurement (Availability) /** * The queue is currently unused, but may be used in the future for calling completions @@ -5098,12 +5000,16 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end /** - * The device this cluster object is associated with. + * Cluster Wake on LAN + * This cluster provides an interface for managing low power mode on a device that supports the Wake On LAN protocol. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterWakeOnLAN : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeMACAddressWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5124,25 +5030,24 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Channel - * This cluster provides an interface for controlling the current Channel on a device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterChannel : MTRCluster +@interface MTRClusterWakeOnLAN (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Channel + * This cluster provides an interface for controlling the current Channel on a device. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterChannel : MTRGenericCluster - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRChannelClusterChangeChannelResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)changeChannelByNumberWithParams:(MTRChannelClusterChangeChannelByNumberParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5171,12 +5076,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Target Navigator - * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterTargetNavigator : MTRCluster +@interface MTRClusterChannel (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5184,12 +5084,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Target Navigator + * This cluster provides an interface for UX navigation within a set of targets on a device or endpoint. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterTargetNavigator : MTRGenericCluster - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRTargetNavigatorClusterNavigateTargetResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5214,12 +5118,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Media Playback - * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterMediaPlayback : MTRCluster +@interface MTRClusterTargetNavigator (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5227,12 +5126,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Media Playback + * This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterMediaPlayback : MTRGenericCluster - (void)playWithParams:(MTRMediaPlaybackClusterPlayParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)playWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion @@ -5293,12 +5196,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Media Input - * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterMediaInput : MTRCluster +@interface MTRClusterMediaPlayback (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5306,12 +5204,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Media Input + * This cluster provides an interface for controlling the Input Selector on a media device such as a TV. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterMediaInput : MTRGenericCluster - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)showInputStatusWithParams:(MTRMediaInputClusterShowInputStatusParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5343,12 +5245,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Low Power - * This cluster provides an interface for managing low power mode on a device. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterLowPower : MTRCluster +@interface MTRClusterMediaInput (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5356,12 +5253,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Low Power + * This cluster provides an interface for managing low power mode on a device. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterLowPower : MTRGenericCluster - (void)sleepWithParams:(MTRLowPowerClusterSleepParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)sleepWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -5384,12 +5285,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Keypad Input - * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterKeypadInput : MTRCluster +@interface MTRClusterLowPower (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5397,12 +5293,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Keypad Input + * This cluster provides an interface for controlling a device like a TV using action commands such as UP, DOWN, and SELECT. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterKeypadInput : MTRGenericCluster - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRKeypadInputClusterSendKeyResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5423,12 +5323,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Content Launcher - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterContentLauncher : MTRCluster +@interface MTRClusterKeypadInput (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5436,12 +5331,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Content Launcher + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterContentLauncher : MTRGenericCluster - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRContentLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)launchURLWithParams:(MTRContentLauncherClusterLaunchURLParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRContentLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5469,12 +5368,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Audio Output - * This cluster provides an interface for controlling the Output on a media device such as a TV. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterAudioOutput : MTRCluster +@interface MTRClusterContentLauncher (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5482,12 +5376,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Audio Output + * This cluster provides an interface for controlling the Output on a media device such as a TV. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterAudioOutput : MTRGenericCluster - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)renameOutputWithParams:(MTRAudioOutputClusterRenameOutputParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5513,12 +5411,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Application Launcher - * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterApplicationLauncher : MTRCluster +@interface MTRClusterAudioOutput (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5526,12 +5419,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Application Launcher + * This cluster provides an interface for launching content on a media player device such as a TV or Speaker. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterApplicationLauncher : MTRGenericCluster - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)stopAppWithParams:(MTRApplicationLauncherClusterStopAppParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5560,25 +5457,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Application Basic - * This cluster provides information about an application running on a TV or media player device which is represented as an endpoint. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterApplicationBasic : MTRCluster +@interface MTRClusterApplicationLauncher (Availability) /** - * The queue is currently unused, but may be used in the future for calling completions - * for command invocations if commands are added to this cluster. + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Application Basic + * This cluster provides information about an application running on a TV or media player device which is represented as an endpoint. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterApplicationBasic : MTRGenericCluster - (NSDictionary * _Nullable)readAttributeVendorNameWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); @@ -5613,25 +5509,24 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Account Login - * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App running on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make the user account on the Content App match the user account on the Client. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterAccountLogin : MTRCluster +@interface MTRClusterApplicationBasic (Availability) /** - * For all instance methods that take a completion (i.e. command invocations), - * the completion will be called on the provided queue. + * The queue is currently unused, but may be used in the future for calling completions + * for command invocations if commands are added to this cluster. */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Account Login + * This cluster provides commands that facilitate user account login on a Content App or a node. For example, a Content App running on a Video Player device, which is represented as an endpoint (see [TV Architecture]), can use this cluster to help make the user account on the Content App match the user account on the Client. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterAccountLogin : MTRGenericCluster - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)loginWithParams:(MTRAccountLoginClusterLoginParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); @@ -5656,12 +5551,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Electrical Measurement - * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need to provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. - */ -MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) -@interface MTRClusterElectricalMeasurement : MTRCluster +@interface MTRClusterAccountLogin (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5669,12 +5559,16 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Electrical Measurement + * Attributes related to the electrical properties of a device. This cluster is used by power outlets and other devices that need to provide instantaneous data as opposed to metrology data which should be retrieved from the metering cluster.. */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) +@interface MTRClusterElectricalMeasurement : MTRGenericCluster - (void)getProfileInfoCommandWithParams:(MTRElectricalMeasurementClusterGetProfileInfoCommandParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)getProfileInfoCommandWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -5970,12 +5864,7 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @end -/** - * Cluster Unit Testing - * The Test Cluster is meant to validate the generated code - */ -MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) -@interface MTRClusterUnitTesting : MTRCluster +@interface MTRClusterElectricalMeasurement (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -5983,12 +5872,16 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Unit Testing + * The Test Cluster is meant to validate the generated code */ -@property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; +MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) +@interface MTRClusterUnitTesting : MTRGenericCluster - (void)testWithParams:(MTRUnitTestingClusterTestParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)testWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -6368,12 +6261,7 @@ MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) @end -/** - * Cluster Sample MEI - * The Sample MEI cluster showcases a cluster manufacturer extensions - */ -MTR_PROVISIONALLY_AVAILABLE -@interface MTRClusterSampleMEI : MTRCluster +@interface MTRClusterUnitTesting (Availability) /** * For all instance methods that take a completion (i.e. command invocations), @@ -6381,12 +6269,16 @@ MTR_PROVISIONALLY_AVAILABLE */ - (instancetype _Nullable)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID - queue:(dispatch_queue_t)queue NS_DESIGNATED_INITIALIZER MTR_PROVISIONALLY_AVAILABLE; + queue:(dispatch_queue_t)queue MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); + +@end /** - * The device this cluster object is associated with. + * Cluster Sample MEI + * The Sample MEI cluster showcases a cluster manufacturer extensions */ -@property (nonatomic, readonly) MTRDevice * device MTR_PROVISIONALLY_AVAILABLE; +MTR_PROVISIONALLY_AVAILABLE +@interface MTRClusterSampleMEI : MTRGenericCluster - (void)pingWithParams:(MTRSampleMEIClusterPingParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_PROVISIONALLY_AVAILABLE; - (void)pingWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion @@ -6414,6 +6306,18 @@ MTR_PROVISIONALLY_AVAILABLE @end +@interface MTRClusterSampleMEI (Availability) + +/** + * For all instance methods that take a completion (i.e. command invocations), + * the completion will be called on the provided queue. + */ +- (instancetype _Nullable)initWithDevice:(MTRDevice *)device + endpointID:(NSNumber *)endpointID + queue:(dispatch_queue_t)queue MTR_PROVISIONALLY_AVAILABLE; + +@end + MTR_DEPRECATED("Please use MTRClusterBasicInformation", ios(16.1, 16.4), macos(13.0, 13.3), watchos(9.1, 9.4), tvos(16.1, 16.4)) @interface MTRClusterBasic : MTRClusterBasicInformation @end diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm index 1684d5a86f5095..bf69082cf83584 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm @@ -16,7 +16,6 @@ */ #import -#import #import "MTRClusterConstants.h" #import "MTRCluster_Internal.h" @@ -44,18 +43,6 @@ // NOLINTBEGIN(clang-analyzer-cplusplus.NewDeleteLeaks): Linter is unable to locate the delete on these objects. @implementation MTRClusterIdentify -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)identifyWithParams:(MTRIdentifyClusterIdentifyParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -184,18 +171,6 @@ - (void)triggerEffectWithParams:(MTRIdentifyClusterTriggerEffectParams *)params @implementation MTRClusterGroups -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)addGroupWithParams:(MTRGroupsClusterAddGroupParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGroupsClusterAddGroupResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -456,18 +431,6 @@ - (void)addGroupIfIdentifyingWithParams:(MTRGroupsClusterAddGroupIfIdentifyingPa @implementation MTRClusterScenes -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)addSceneWithParams:(MTRScenesClusterAddSceneParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRScenesClusterAddSceneResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -898,18 +861,6 @@ - (void)copySceneWithParams:(MTRScenesClusterCopySceneParams *)params expectedVa @implementation MTRClusterOnOff -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)offWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self offWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -1235,18 +1186,6 @@ - (void)onWithTimedOffWithParams:(MTROnOffClusterOnWithTimedOffParams *)params e @implementation MTRClusterOnOffSwitchConfiguration -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeSwitchTypeWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeOnOffSwitchConfigurationID) attributeID:@(MTRAttributeIDTypeClusterOnOffSwitchConfigurationAttributeSwitchTypeID) params:params]; @@ -1311,18 +1250,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterLevelControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)moveToLevelWithParams:(MTRLevelControlClusterMoveToLevelParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -1801,18 +1728,6 @@ - (void)moveToClosestFrequencyWithParams:(MTRLevelControlClusterMoveToClosestFre @implementation MTRClusterBinaryInputBasic -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeActiveTextWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeBinaryInputBasicID) attributeID:@(MTRAttributeIDTypeClusterBinaryInputBasicAttributeActiveTextID) params:params]; @@ -1967,18 +1882,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterPulseWidthModulation -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeGeneratedCommandListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePulseWidthModulationID) attributeID:@(MTRAttributeIDTypeClusterPulseWidthModulationAttributeGeneratedCommandListID) params:params]; @@ -2013,18 +1916,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterDescriptor -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeDeviceTypeListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeDescriptorID) attributeID:@(MTRAttributeIDTypeClusterDescriptorAttributeDeviceTypeListID) params:params]; @@ -2097,18 +1988,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterBinding -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeBindingWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeBindingID) attributeID:@(MTRAttributeIDTypeClusterBindingAttributeBindingID) params:params]; @@ -2168,18 +2047,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterAccessControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeACLWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeAccessControlID) attributeID:@(MTRAttributeIDTypeClusterAccessControlAttributeACLID) params:params]; @@ -2282,18 +2149,6 @@ - (void)writeAttributeAclWithValue:(NSDictionary *)dataValueDict @implementation MTRClusterActions -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)instantActionWithParams:(MTRActionsClusterInstantActionParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -2736,18 +2591,6 @@ - (void)disableActionWithDurationWithParams:(MTRActionsClusterDisableActionWithD @implementation MTRClusterBasicInformation -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)mfgSpecificPingWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self mfgSpecificPingWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -2971,18 +2814,6 @@ - (void)mfgSpecificPingWithExpectedValues:(NSArray @implementation MTRClusterOTASoftwareUpdateProvider -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)queryImageWithParams:(MTROTASoftwareUpdateProviderClusterQueryImageParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROTASoftwareUpdateProviderClusterQueryImageResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -3130,18 +2961,6 @@ - (void)notifyUpdateAppliedWithParams:(MTROtaSoftwareUpdateProviderClusterNotify @implementation MTRClusterOTASoftwareUpdateRequestor -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)announceOTAProviderWithParams:(MTROTASoftwareUpdateRequestorClusterAnnounceOTAProviderParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -3262,18 +3081,6 @@ - (void)writeAttributeDefaultOtaProvidersWithValue:(NSDictionary @implementation MTRClusterLocalizationConfiguration -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeActiveLocaleWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeLocalizationConfigurationID) attributeID:@(MTRAttributeIDTypeClusterLocalizationConfigurationAttributeActiveLocaleID) params:params]; @@ -3338,18 +3145,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterTimeFormatLocalization -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeHourFormatWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeTimeFormatLocalizationID) attributeID:@(MTRAttributeIDTypeClusterTimeFormatLocalizationAttributeHourFormatID) params:params]; @@ -3430,18 +3225,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterUnitLocalization -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeTemperatureUnitWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeUnitLocalizationID) attributeID:@(MTRAttributeIDTypeClusterUnitLocalizationAttributeTemperatureUnitID) params:params]; @@ -3501,18 +3284,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterPowerSourceConfiguration -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeSourcesWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePowerSourceConfigurationID) attributeID:@(MTRAttributeIDTypeClusterPowerSourceConfigurationAttributeSourcesID) params:params]; @@ -3561,18 +3332,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterPowerSource -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeStatusWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePowerSourceID) attributeID:@(MTRAttributeIDTypeClusterPowerSourceAttributeStatusID) params:params]; @@ -3776,18 +3535,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterGeneralCommissioning -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)armFailSafeWithParams:(MTRGeneralCommissioningClusterArmFailSafeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralCommissioningClusterArmFailSafeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -3980,18 +3727,6 @@ - (void)commissioningCompleteWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRNetworkCommissioningClusterScanNetworksResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -4311,18 +4046,6 @@ - (void)reorderNetworkWithParams:(MTRNetworkCommissioningClusterReorderNetworkPa @implementation MTRClusterDiagnosticLogs -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsRequestParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRDiagnosticLogsClusterRetrieveLogsResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -4401,18 +4124,6 @@ - (void)retrieveLogsRequestWithParams:(MTRDiagnosticLogsClusterRetrieveLogsReque @implementation MTRClusterGeneralDiagnostics -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -4568,18 +4279,6 @@ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTrigger @implementation MTRClusterSoftwareDiagnostics -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetWatermarksWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetWatermarksWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -4683,18 +4382,6 @@ - (void)resetWatermarksWithExpectedValues:(NSArray @implementation MTRClusterThreadNetworkDiagnostics -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -5101,18 +4788,6 @@ - (void)resetCountsWithExpectedValues:(NSArray *> * @implementation MTRClusterWiFiNetworkDiagnostics -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -5269,18 +4944,6 @@ - (void)resetCountsWithExpectedValues:(NSArray *> * @implementation MTRClusterEthernetNetworkDiagnostics -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetCountsWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetCountsWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -5409,18 +5072,6 @@ - (void)resetCountsWithExpectedValues:(NSArray *> * @implementation MTRClusterTimeSynchronization -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setUTCTimeWithParams:(MTRTimeSynchronizationClusterSetUTCTimeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -5655,18 +5306,6 @@ - (void)setDefaultNTPWithParams:(MTRTimeSynchronizationClusterSetDefaultNTPParam @implementation MTRClusterBridgedDeviceBasicInformation -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeVendorNameWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeBridgedDeviceBasicInformationID) attributeID:@(MTRAttributeIDTypeClusterBridgedDeviceBasicInformationAttributeVendorNameID) params:params]; @@ -5803,18 +5442,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterSwitch -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeNumberOfPositionsWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeSwitchID) attributeID:@(MTRAttributeIDTypeClusterSwitchAttributeNumberOfPositionsID) params:params]; @@ -5873,18 +5500,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterAdministratorCommissioning -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)openCommissioningWindowWithParams:(MTRAdministratorCommissioningClusterOpenCommissioningWindowParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -6056,18 +5671,6 @@ - (void)revokeCommissioningWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTROperationalCredentialsClusterAttestationResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -6418,18 +6021,6 @@ - (void)addTrustedRootCertificateWithParams:(MTROperationalCredentialsClusterAdd @implementation MTRClusterGroupKeyManagement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)keySetWriteWithParams:(MTRGroupKeyManagementClusterKeySetWriteParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -6642,18 +6233,6 @@ - (void)keySetReadAllIndicesWithParams:(MTRGroupKeyManagementClusterKeySetReadAl @implementation MTRClusterFixedLabel -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeLabelListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeFixedLabelID) attributeID:@(MTRAttributeIDTypeClusterFixedLabelAttributeLabelListID) params:params]; @@ -6702,18 +6281,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterUserLabel -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeLabelListWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeUserLabelID) attributeID:@(MTRAttributeIDTypeClusterUserLabelAttributeLabelListID) params:params]; @@ -6773,18 +6340,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterBooleanState -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeStateValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeBooleanStateID) attributeID:@(MTRAttributeIDTypeClusterBooleanStateAttributeStateValueID) params:params]; @@ -6833,18 +6388,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterICDManagement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)registerClientWithParams:(MTRICDManagementClusterRegisterClientParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRICDManagementClusterRegisterClientResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7004,18 +6547,6 @@ - (void)stayActiveRequestWithParams:(MTRICDManagementClusterStayActiveRequestPar @implementation MTRClusterModeSelect -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -7143,18 +6674,6 @@ - (void)changeToModeWithParams:(MTRModeSelectClusterChangeToModeParams *)params @implementation MTRClusterLaundryWasherMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRLaundryWasherModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRLaundryWasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7258,18 +6777,6 @@ - (void)writeAttributeOnModeWithValue:(NSDictionary *)dataValueD @implementation MTRClusterRefrigeratorAndTemperatureControlledCabinetMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRefrigeratorAndTemperatureControlledCabinetModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7373,18 +6880,6 @@ - (void)writeAttributeOnModeWithValue:(NSDictionary *)dataValueD @implementation MTRClusterLaundryWasherControls -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeSpinSpeedsWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeLaundryWasherControlsID) attributeID:@(MTRAttributeIDTypeClusterLaundryWasherControlsAttributeSpinSpeedsID) params:params]; @@ -7461,18 +6956,6 @@ - (void)writeAttributeNumberOfRinsesWithValue:(NSDictionary *)da @implementation MTRClusterRVCRunMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRVCRunModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCRunModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7560,18 +7043,6 @@ - (void)writeAttributeOnModeWithValue:(NSDictionary *)dataValueD @implementation MTRClusterRVCCleanMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRRVCCleanModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRRVCCleanModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7659,18 +7130,6 @@ - (void)writeAttributeOnModeWithValue:(NSDictionary *)dataValueD @implementation MTRClusterTemperatureControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setTemperatureWithParams:(MTRTemperatureControlClusterSetTemperatureParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -7762,18 +7221,6 @@ - (void)setTemperatureWithParams:(MTRTemperatureControlClusterSetTemperaturePara @implementation MTRClusterRefrigeratorAlarm -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMaskWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeRefrigeratorAlarmID) attributeID:@(MTRAttributeIDTypeClusterRefrigeratorAlarmAttributeMaskID) params:params]; @@ -7823,18 +7270,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterDishwasherMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeToModeWithParams:(MTRDishwasherModeClusterChangeToModeParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRDishwasherModeClusterChangeToModeResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -7938,18 +7373,6 @@ - (void)writeAttributeOnModeWithValue:(NSDictionary *)dataValueD @implementation MTRClusterAirQuality -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeAirQualityWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeAirQualityID) attributeID:@(MTRAttributeIDTypeClusterAirQualityAttributeAirQualityID) params:params]; @@ -7989,18 +7412,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterSmokeCOAlarm -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selfTestRequestWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self selfTestRequestWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -8142,18 +7553,6 @@ - (void)writeAttributeSmokeSensitivityLevelWithValue:(NSDictionary *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -8262,18 +7661,6 @@ - (void)modifyEnabledAlarmsWithParams:(MTRDishwasherAlarmClusterModifyEnabledAla @implementation MTRClusterMicrowaveOvenMode -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeSupportedModesWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeMicrowaveOvenModeID) attributeID:@(MTRAttributeIDTypeClusterMicrowaveOvenModeAttributeSupportedModesID) params:params]; @@ -8318,18 +7705,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterMicrowaveOvenControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setCookingParametersWithParams:(MTRMicrowaveOvenControlClusterSetCookingParametersParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -8443,18 +7818,6 @@ - (void)addMoreTimeWithParams:(MTRMicrowaveOvenControlClusterAddMoreTimeParams * @implementation MTRClusterOperationalState -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pauseWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTROperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion { [self pauseWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -8643,18 +8006,6 @@ - (void)resumeWithParams:(MTROperationalStateClusterResumeParams * _Nullable)par @implementation MTRClusterRVCOperationalState -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pauseWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRRVCOperationalStateClusterOperationalCommandResponseParams * _Nullable data, NSError * _Nullable error))completion { [self pauseWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -8843,18 +8194,6 @@ - (void)resumeWithParams:(MTRRVCOperationalStateClusterResumeParams * _Nullable) @implementation MTRClusterHEPAFilterMonitoring -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetConditionWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetConditionWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -8961,18 +8300,6 @@ - (void)writeAttributeLastChangedTimeWithValue:(NSDictionary *)d @implementation MTRClusterActivatedCarbonFilterMonitoring -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)resetConditionWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self resetConditionWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -9079,18 +8406,6 @@ - (void)writeAttributeLastChangedTimeWithValue:(NSDictionary *)d @implementation MTRClusterDoorLock -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)lockDoorWithParams:(MTRDoorLockClusterLockDoorParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -10157,18 +9472,6 @@ - (void)clearCredentialWithParams:(MTRDoorLockClusterClearCredentialParams *)par @implementation MTRClusterWindowCovering -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)upOrOpenWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self upOrOpenWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -10581,18 +9884,6 @@ - (void)goToTiltPercentageWithParams:(MTRWindowCoveringClusterGoToTiltPercentage @implementation MTRClusterBarrierControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)barrierControlGoToPercentWithParams:(MTRBarrierControlClusterBarrierControlGoToPercentParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -10824,18 +10115,6 @@ - (void)barrierControlStopWithExpectedValues:(NSArray * _Nullable)readAttributeMaxPressureWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePumpConfigurationAndControlID) attributeID:@(MTRAttributeIDTypeClusterPumpConfigurationAndControlAttributeMaxPressureID) params:params]; @@ -11038,18 +10317,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterThermostat -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)setpointRaiseLowerWithParams:(MTRThermostatClusterSetpointRaiseLowerParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -11774,18 +11041,6 @@ - (void)clearWeeklyScheduleWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -11993,18 +11248,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterThermostatUserInterfaceConfiguration -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeTemperatureDisplayModeWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeThermostatUserInterfaceConfigurationID) attributeID:@(MTRAttributeIDTypeClusterThermostatUserInterfaceConfigurationAttributeTemperatureDisplayModeID) params:params]; @@ -12096,18 +11339,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterColorControl -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)moveToHueWithParams:(MTRColorControlClusterMoveToHueParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -13162,18 +12393,6 @@ - (void)stepColorTemperatureWithParams:(MTRColorControlClusterStepColorTemperatu @implementation MTRClusterBallastConfiguration -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributePhysicalMinLevelWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeBallastConfigurationID) attributeID:@(MTRAttributeIDTypeClusterBallastConfigurationAttributePhysicalMinLevelID) params:params]; @@ -13409,18 +12628,6 @@ - (void)writeAttributeIntrinsicBalanceFactorWithValue:(NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeIlluminanceMeasurementID) attributeID:@(MTRAttributeIDTypeClusterIlluminanceMeasurementAttributeMeasuredValueID) params:params]; @@ -13489,18 +12696,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterTemperatureMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeTemperatureMeasurementID) attributeID:@(MTRAttributeIDTypeClusterTemperatureMeasurementAttributeMeasuredValueID) params:params]; @@ -13564,18 +12759,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterPressureMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePressureMeasurementID) attributeID:@(MTRAttributeIDTypeClusterPressureMeasurementAttributeMeasuredValueID) params:params]; @@ -13664,18 +12847,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterFlowMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeFlowMeasurementID) attributeID:@(MTRAttributeIDTypeClusterFlowMeasurementAttributeMeasuredValueID) params:params]; @@ -13739,18 +12910,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterRelativeHumidityMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeRelativeHumidityMeasurementID) attributeID:@(MTRAttributeIDTypeClusterRelativeHumidityMeasurementAttributeMeasuredValueID) params:params]; @@ -13814,18 +12973,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterOccupancySensing -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeOccupancyWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeOccupancySensingID) attributeID:@(MTRAttributeIDTypeClusterOccupancySensingAttributeOccupancyID) params:params]; @@ -14064,18 +13211,6 @@ - (void)writeAttributePirUnoccupiedToOccupiedThresholdWithValue:(NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeCarbonMonoxideConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterCarbonMonoxideConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14165,18 +13300,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterCarbonDioxideConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeCarbonDioxideConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterCarbonDioxideConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14266,18 +13389,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterNitrogenDioxideConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeNitrogenDioxideConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterNitrogenDioxideConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14367,18 +13478,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterOzoneConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeOzoneConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterOzoneConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14468,18 +13567,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterPM25ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePM25ConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterPM25ConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14569,18 +13656,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterFormaldehydeConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeFormaldehydeConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterFormaldehydeConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14670,18 +13745,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterPM1ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePM1ConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterPM1ConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14771,18 +13834,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterPM10ConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypePM10ConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterPM10ConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14872,18 +13923,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterTotalVolatileOrganicCompoundsConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeTotalVolatileOrganicCompoundsConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterTotalVolatileOrganicCompoundsConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -14973,18 +14012,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterRadonConcentrationMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMeasuredValueWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeRadonConcentrationMeasurementID) attributeID:@(MTRAttributeIDTypeClusterRadonConcentrationMeasurementAttributeMeasuredValueID) params:params]; @@ -15074,18 +14101,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpoi @implementation MTRClusterWakeOnLAN -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeMACAddressWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeWakeOnLANID) attributeID:@(MTRAttributeIDTypeClusterWakeOnLANAttributeMACAddressID) params:params]; @@ -15136,18 +14151,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterChannel -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)changeChannelWithParams:(MTRChannelClusterChangeChannelParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRChannelClusterChangeChannelResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -15305,18 +14308,6 @@ - (void)skipChannelWithParams:(MTRChannelClusterSkipChannelParams *)params expec @implementation MTRClusterTargetNavigator -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRTargetNavigatorClusterNavigateTargetResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -15405,18 +14396,6 @@ - (void)navigateTargetWithParams:(MTRTargetNavigatorClusterNavigateTargetParams @implementation MTRClusterMediaPlayback -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)playWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRMediaPlaybackClusterPlaybackResponseParams * _Nullable data, NSError * _Nullable error))completion { [self playWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -15944,18 +14923,6 @@ - (void)seekWithParams:(MTRMediaPlaybackClusterSeekParams *)params expectedValue @implementation MTRClusterMediaInput -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selectInputWithParams:(MTRMediaInputClusterSelectInputParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -16153,18 +15120,6 @@ - (void)renameInputWithParams:(MTRMediaInputClusterRenameInputParams *)params ex @implementation MTRClusterLowPower -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)sleepWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self sleepWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -16248,18 +15203,6 @@ - (void)sleepWithExpectedValues:(NSArray *> * _Null @implementation MTRClusterKeypadInput -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRKeypadInputClusterSendKeyResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -16338,18 +15281,6 @@ - (void)sendKeyWithParams:(MTRKeypadInputClusterSendKeyParams *)params expectedV @implementation MTRClusterContentLauncher -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)launchContentWithParams:(MTRContentLauncherClusterLaunchContentParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRContentLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -16484,18 +15415,6 @@ - (void)launchURLWithParams:(MTRContentLauncherClusterLaunchURLParams *)params e @implementation MTRClusterAudioOutput -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)selectOutputWithParams:(MTRAudioOutputClusterSelectOutputParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { if (params == nil) { @@ -16613,18 +15532,6 @@ - (void)renameOutputWithParams:(MTRAudioOutputClusterRenameOutputParams *)params @implementation MTRClusterApplicationLauncher -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)launchAppWithParams:(MTRApplicationLauncherClusterLaunchAppParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRApplicationLauncherClusterLauncherResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -16794,18 +15701,6 @@ - (void)hideAppWithParams:(MTRApplicationLauncherClusterHideAppParams * _Nullabl @implementation MTRClusterApplicationBasic -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (NSDictionary * _Nullable)readAttributeVendorNameWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeApplicationBasicID) attributeID:@(MTRAttributeIDTypeClusterApplicationBasicAttributeVendorNameID) params:params]; @@ -16889,18 +15784,6 @@ - (instancetype)initWithDevice:(MTRDevice *)device endpoint:(uint16_t)endpoint q @implementation MTRClusterAccountLogin -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)getSetupPINWithParams:(MTRAccountLoginClusterGetSetupPINParams *)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRAccountLoginClusterGetSetupPINResponseParams * _Nullable data, NSError * _Nullable error))completion { if (params == nil) { @@ -17060,18 +15943,6 @@ - (void)logoutWithExpectedValues:(NSArray *> * _Nul @implementation MTRClusterElectricalMeasurement -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)getProfileInfoCommandWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self getProfileInfoCommandWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -17915,18 +16786,6 @@ - (void)getMeasurementProfileCommandWithParams:(MTRElectricalMeasurementClusterG @implementation MTRClusterUnitTesting -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)testWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self testWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; @@ -20085,18 +18944,6 @@ - (void)testEmitTestFabricScopedEventRequestWithParams:(MTRTestClusterClusterTes @implementation MTRClusterSampleMEI -- (instancetype)initWithDevice:(MTRDevice *)device endpointID:(NSNumber *)endpointID queue:(dispatch_queue_t)queue -{ - if (self = [super initWithEndpointID:endpointID queue:queue]) { - if (device == nil) { - return nil; - } - - _device = device; - } - return self; -} - - (void)pingWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(MTRStatusCompletion)completion { [self pingWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; From c797cb1b3a18097d1a20246de83c4a2fd863bcef Mon Sep 17 00:00:00 2001 From: Boris Zbarsky Date: Fri, 3 Nov 2023 18:15:58 -0400 Subject: [PATCH 04/11] Enable Darwin per-controller storage by default. (#30215) Fixes the parameters bits to allow later adding XPC parameters. --- .github/workflows/darwin.yaml | 4 ++-- src/darwin/Framework/CHIP/MTRDefines.h | 2 +- .../Framework/CHIP/MTRDeviceController.h | 4 ++-- .../Framework/CHIP/MTRDeviceController.mm | 15 +++++++++++++-- .../CHIP/MTRDeviceControllerParameters.h | 19 +++++++++++++++++-- .../CHIP/MTRDeviceControllerStartupParams.mm | 9 ++++++++- ...TRDeviceControllerStartupParams_Internal.h | 5 +++++ 7 files changed, 48 insertions(+), 10 deletions(-) diff --git a/.github/workflows/darwin.yaml b/.github/workflows/darwin.yaml index 8b7e44ef82ee00..04648f4da135ee 100644 --- a/.github/workflows/darwin.yaml +++ b/.github/workflows/darwin.yaml @@ -111,8 +111,8 @@ jobs: # -enableUndefinedBehaviorSanitizer instruments the code in Matter.framework, # but to instrument the code in the underlying libCHIP we need to pass CHIP_IS_UBSAN=YES TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO GCC_PREPROCESSOR_DEFINITIONS='${inherited} MTR_NO_AVAILABILITY=1'> >(tee /tmp/darwin/framework-tests/darwin-tests-asan.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-err.log >&2) - # And the same thing, but with MTR_PER_CONTROLLER_STORAGE_ENABLED turned on. - TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO GCC_PREPROCESSOR_DEFINITIONS='${inherited} MTR_NO_AVAILABILITY=1 MTR_PER_CONTROLLER_STORAGE_ENABLED=1' > >(tee /tmp/darwin/framework-tests/darwin-tests-asan-controller-storage.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-controller-storage-err.log >&2) + # And the same thing, but with MTR_PER_CONTROLLER_STORAGE_ENABLED turned off, so we test that it does not break for now. + TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO GCC_PREPROCESSOR_DEFINITIONS='${inherited} MTR_NO_AVAILABILITY=1 MTR_PER_CONTROLLER_STORAGE_ENABLED=0' > >(tee /tmp/darwin/framework-tests/darwin-tests-asan-controller-storage.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-controller-storage-err.log >&2) # And the same thing, but with MTR_ENABLE_PROVISIONAL also turned on. TEST_RUNNER_ASAN_OPTIONS=__CURRENT_VALUE__:detect_stack_use_after_return=1 xcodebuild test -target "Matter" -scheme "Matter Framework Tests" -sdk macosx -enableAddressSanitizer YES -enableUndefinedBehaviorSanitizer YES OTHER_CFLAGS='${inherited} -Werror -Wconversion' CHIP_IS_UBSAN=YES CHIP_IS_BLE=NO GCC_PREPROCESSOR_DEFINITIONS='${inherited} MTR_NO_AVAILABILITY=1 MTR_PER_CONTROLLER_STORAGE_ENABLED=1 MTR_ENABLE_PROVISIONAL=1' > >(tee /tmp/darwin/framework-tests/darwin-tests-asan-provisional.log) 2> >(tee /tmp/darwin/framework-tests/darwin-tests-asan-provisional-err.log >&2) # And the same thing, but with MTR_NO_AVAILABILITY not turned on. This requires -Wno-unguarded-availability-new to avoid availability errors. diff --git a/src/darwin/Framework/CHIP/MTRDefines.h b/src/darwin/Framework/CHIP/MTRDefines.h index add06898ec9080..97d918297327d5 100644 --- a/src/darwin/Framework/CHIP/MTRDefines.h +++ b/src/darwin/Framework/CHIP/MTRDefines.h @@ -71,7 +71,7 @@ #endif #ifndef MTR_PER_CONTROLLER_STORAGE_ENABLED -#define MTR_PER_CONTROLLER_STORAGE_ENABLED 0 +#define MTR_PER_CONTROLLER_STORAGE_ENABLED 1 #endif #pragma mark - Types diff --git a/src/darwin/Framework/CHIP/MTRDeviceController.h b/src/darwin/Framework/CHIP/MTRDeviceController.h index d4e79f594181a3..e830f024d8d155 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceController.h +++ b/src/darwin/Framework/CHIP/MTRDeviceController.h @@ -24,7 +24,7 @@ @class MTRBaseDevice; #if MTR_PER_CONTROLLER_STORAGE_ENABLED -@class MTRDeviceControllerParameters; +@class MTRDeviceControllerAbstractParameters; #endif // MTR_PER_CONTROLLER_STORAGE_ENABLED NS_ASSUME_NONNULL_BEGIN @@ -58,7 +58,7 @@ typedef void (^MTRDeviceConnectionCallback)(MTRBaseDevice * _Nullable device, NS * Once this returns non-nil, it's the caller's resposibility to call shutdown * on the controller to avoid leaking it. */ -- (nullable instancetype)initWithParameters:(MTRDeviceControllerParameters *)parameters +- (nullable instancetype)initWithParameters:(MTRDeviceControllerAbstractParameters *)parameters error:(NSError * __autoreleasing *)error MTR_NEWLY_AVAILABLE; #endif // MTR_PER_CONTROLLER_STORAGE_ENABLED diff --git a/src/darwin/Framework/CHIP/MTRDeviceController.mm b/src/darwin/Framework/CHIP/MTRDeviceController.mm index d4c5903c93077d..94b9a49173a49d 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceController.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceController.mm @@ -127,8 +127,17 @@ @interface MTRDeviceController () { @implementation MTRDeviceController -- (nullable instancetype)initWithParameters:(MTRDeviceControllerParameters *)parameters error:(NSError * __autoreleasing *)error +- (nullable instancetype)initWithParameters:(MTRDeviceControllerAbstractParameters *)parameters error:(NSError * __autoreleasing *)error { + if (![parameters isKindOfClass:MTRDeviceControllerParameters.class]) { + MTR_LOG_ERROR("Unsupported type of MTRDeviceControllerAbstractParameters: %@", parameters); + + if (error) { + *error = [MTRError errorForCHIPErrorCode:CHIP_ERROR_INVALID_ARGUMENT]; + } + return nil; + } + __auto_type * factory = [MTRDeviceControllerFactory sharedInstance]; if (!factory.isRunning) { auto * params = [[MTRDeviceControllerFactoryParams alloc] initWithoutStorage]; @@ -138,7 +147,9 @@ - (nullable instancetype)initWithParameters:(MTRDeviceControllerParameters *)par } } - return [factory initializeController:self withParameters:parameters error:error]; + auto * parametersForFactory = static_cast(parameters); + + return [factory initializeController:self withParameters:parametersForFactory error:error]; } - (instancetype)initWithFactory:(MTRDeviceControllerFactory *)factory diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerParameters.h b/src/darwin/Framework/CHIP/MTRDeviceControllerParameters.h index bcbea7902b6083..b9c72d5598f92b 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerParameters.h +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerParameters.h @@ -28,14 +28,29 @@ NS_ASSUME_NONNULL_BEGIN +/** + * Parameters that can be used to initialize an MTRDeviceController. Specific + * interfaces inheriting from this one should be used to actually do the + * initialization. + */ #if !MTR_PER_CONTROLLER_STORAGE_ENABLED MTR_HIDDEN #endif MTR_NEWLY_AVAILABLE -@interface MTRDeviceControllerParameters : NSObject - +@interface MTRDeviceControllerAbstractParameters : NSObject - (instancetype)init NS_UNAVAILABLE; + (instancetype)new NS_UNAVAILABLE; +@end + +/** + * Parameters that can be used to initialize an MTRDeviceController which + * has a node identity. + */ +#if !MTR_PER_CONTROLLER_STORAGE_ENABLED +MTR_HIDDEN +#endif +MTR_NEWLY_AVAILABLE +@interface MTRDeviceControllerParameters : MTRDeviceControllerAbstractParameters /** * The Product Attestation Authority certificates that are trusted to sign diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm index 8ad185198b5330..74a9681ca3e619 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.mm @@ -251,6 +251,13 @@ - (instancetype)initWithOperationalKeypair:(id)operationalKeypair @end +@implementation MTRDeviceControllerAbstractParameters +- (instancetype)_initInternal +{ + return [super init]; +} +@end + @implementation MTRDeviceControllerParameters - (instancetype)initWithStorageDelegate:(id)storageDelegate storageDelegateQueue:(dispatch_queue_t)storageDelegateQueue @@ -262,7 +269,7 @@ - (instancetype)initWithStorageDelegate:(id) intermediateCertificate:(MTRCertificateDERBytes _Nullable)intermediateCertificate rootCertificate:(MTRCertificateDERBytes)rootCertificate { - if (!(self = [super init])) { + if (!(self = [super _initInternal])) { return nil; } diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams_Internal.h b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams_Internal.h index 2850fc78258486..71e6a74f5688f3 100644 --- a/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams_Internal.h +++ b/src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams_Internal.h @@ -52,6 +52,11 @@ NS_ASSUME_NONNULL_BEGIN - (instancetype)initWithParams:(MTRDeviceControllerStartupParams *)params; @end +@interface MTRDeviceControllerAbstractParameters () +// Allow init from our subclasses. +- (instancetype)_initInternal; +@end + @interface MTRDeviceControllerParameters () - (instancetype)initWithStorageDelegate:(id)storageDelegate From b82bea21749dfbf6c837c668bc2d1bac2df9da94 Mon Sep 17 00:00:00 2001 From: manjunath-grl <102359958+manjunath-grl@users.noreply.github.com> Date: Sat, 4 Nov 2023 12:14:52 +0530 Subject: [PATCH 05/11] Semi-automated testcases Nov 03 (#30197) * Manual-->Semi-automated testcases TC-CNET-4.1 TC-CNET-4.2 TC-CNET-4.3 TC-CNET-4.4 TC-CNET-4.5 TC-CNET-4.6 TC-CNET-4.9 TC-CNET-4.10 TC-CNET-4.11 TC-CNET-4.15 TC-CNET-4.16 TC-CNET-4.22 * Restyled by whitespace * Modified Darwin ciTests.json disabled CNET-4.3 * Modifed ciTests.json file --------- Co-authored-by: Restyled.io --- .../certification/Test_TC_CNET_4_1.yaml | 289 +++++----- .../certification/Test_TC_CNET_4_10.yaml | 445 +++++++------- .../certification/Test_TC_CNET_4_11.yaml | 543 ++++++++++-------- .../certification/Test_TC_CNET_4_15.yaml | 164 ++++-- .../certification/Test_TC_CNET_4_16.yaml | 171 +++--- .../certification/Test_TC_CNET_4_2.yaml | 317 +++++----- .../certification/Test_TC_CNET_4_22.yaml | 314 +++++----- .../certification/Test_TC_CNET_4_3.yaml | 243 ++++---- .../certification/Test_TC_CNET_4_4.yaml | 314 ++++------ .../certification/Test_TC_CNET_4_5.yaml | 118 ++-- .../certification/Test_TC_CNET_4_6.yaml | 126 ++-- .../certification/Test_TC_CNET_4_9.yaml | 445 +++++++------- 12 files changed, 1772 insertions(+), 1717 deletions(-) diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_1.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_1.yaml index b4d15c1bc8a879..ce3979c6f5b09a 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_1.yaml @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.1. [TC-CNET-4.1] [WiFi] Verification for attributes check [DUT-Server] @@ -21,197 +20,169 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" endpoint: 0 + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:47524C50726976617465" tests: - - label: "Preconditions" - verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 4. TH can communicate with the DUT - disabled: true - - label: "Step 1: Factory reset the DUT" verification: | - - disabled: true - + Reset Devices to factory defaults + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Factory Reset the DUT and enter 'y' after success" + - name: "expectedValue" + value: "y" + + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 - label: "Step 2: Commission TH and DUT over BLE to setup the Wi-Fi" verification: | - - disabled: true + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after successfull Commission" + - name: "expectedValue" + value: "y" - label: "Step 3: TH reads Descriptor Cluster from the DUT with EP0 TH reads ServerList from the DUT" - verification: | - ./chip-tool descriptor read server-list 1 0 - - Via the TH (chip-tool), verify that the server list has value as 49. - - [1654250292.680821][5262:5267] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001D Attribute 0x0000_0001 DataVersion: 812190876 - [1654250292.681079][5262:5267] CHIP:TOO: server list: 26 entries - [1654250292.681196][5262:5267] CHIP:TOO: [1]: 3 - [1654250292.681264][5262:5267] CHIP:TOO: [2]: 4 - [1654250292.681327][5262:5267] CHIP:TOO: [3]: 29 - [1654250292.681389][5262:5267] CHIP:TOO: [4]: 30 - [1654250292.681450][5262:5267] CHIP:TOO: [5]: 31 - [1654250292.681525][5262:5267] CHIP:TOO: [6]: 40 - [1654250292.681578][5262:5267] CHIP:TOO: [7]: 42 - [1654250292.681629][5262:5267] CHIP:TOO: [8]: 43 - [1654250292.681680][5262:5267] CHIP:TOO: [9]: 44 - [1654250292.681731][5262:5267] CHIP:TOO: [10]: 45 - [1654250292.681782][5262:5267] CHIP:TOO: [11]: 46 - [1654250292.681833][5262:5267] CHIP:TOO: [12]: 47 - [1654250292.681911][5262:5267] CHIP:TOO: [13]: 48 - [1654250292.681977][5262:5267] CHIP:TOO: [14]: 49 - [1654250292.682038][5262:5267] CHIP:TOO: [15]: 50 - [1654250292.682100][5262:5267] CHIP:TOO: [16]: 51 - [1654250292.682160][5262:5267] CHIP:TOO: [17]: 52 - [1654250292.682220][5262:5267] CHIP:TOO: [18]: 53 - [1654250292.682281][5262:5267] CHIP:TOO: [19]: 54 - [1654250292.682342][5262:5267] CHIP:TOO: [20]: 55 - [1654250292.682404][5262:5267] CHIP:TOO: [21]: 60 - [1654250292.682467][5262:5267] CHIP:TOO: [22]: 62 - [1654250292.682528][5262:5267] CHIP:TOO: [23]: 63 - [1654250292.682590][5262:5267] CHIP:TOO: [24]: 64 - [1654250292.682651][5262:5267] CHIP:TOO: [25]: 65 - [1654250292.682714][5262:5267] CHIP:TOO: [26]: 1029 - disabled: true + cluster: "Descriptor" + command: "readAttribute" + attribute: "ServerList" + response: + constraints: + type: list + contains: [49] - label: "Step 4: TH reads FeatureMap attribute from the DUT" - verification: | - ./chip-tool networkcommissioning read feature-map 1 0 - - Via the TH (chip-tool), verify that FeatureMap attribute value as 1 for WiFiNetworkInterface. - - [1653473169.784344][29771:29776] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFC DataVersion: 1600858167 - [1653473169.784413][29771:29776] CHIP:TOO: FeatureMap: 1 - [1653473169.784516][29771:29776] CHIP:EM: Sending Standalone Ack for MessageCounter:3349837 on exchange 7603i - disabled: true - - - label: "Step 5: TH reads the MaxNetworks attribute from the DUT" - PICS: CNET.S.A0000 - verification: | - ./chip-tool networkcommissioning read max-networks 1 0 - - Via the TH (chip-tool), Verify the MaxNetworks attribute that contains value in the range of 1 to 255. - - [1653473181.407542][29777:29782] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0000 DataVersion: 1600858167 - [1653473181.407621][29777:29782] CHIP:TOO: MaxNetworks: 1 - [1653473181.407725][29777:29782] CHIP:EM: Sending Standalone Ack for MessageCounter:15199397 on exchange 5841i - disabled: true + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - label: - "Step 6: TH saves the MaxNetworks attribute value as - 'MaxNetworksValue' for future use" - verification: | - - disabled: true + "Step 5 & 6: TH reads the MaxNetworks attribute from the DUT. TH saves + the MaxNetworks attribute value as 'MaxNetworksValue' for future use" + PICS: CNET.S.A0000 + command: "readAttribute" + attribute: "MaxNetworks" + response: + saveAs: MaxNetworksValue + constraints: + type: int8u + minValue: 1 + maxValue: 255 - label: "Step 7: TH reads the Networks attribute list from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should the type of octstr with a length range of 1 to 32. - -that the connected status is in tthe type of bool value as TRUE. - - [1654250379.881780][5309:5314] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 3741733376 - [1654250379.881974][5309:5314] CHIP:TOO: Networks: 1 entries - [1654250379.882123][5309:5314] CHIP:TOO: [1]: { - [1654250379.882196][5309:5314] CHIP:TOO: NetworkID: 47524C50726976617465 - [1654250379.882257][5309:5314] CHIP:TOO: Connected: TRUE - [1654250379.882312][5309:5314] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 8: TH reads ScanMaxTimeSeconds attribute from the DUT" PICS: CNET.S.A0002 - verification: | - ./chip-tool networkcommissioning read scan-max-time-seconds 1 0 - - Via the TH (chip-tool), Verify the ScanMaxTimeSeconds attribute that contains value in the range of 1 to 255 secs. - - [1653473784.850830][29813:29818] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0002 DataVersion: 1600858167 - [1653473784.850916][29813:29818] CHIP:TOO: ScanMaxTimeSeconds: 10 - [1653473784.851029][29813:29818] CHIP:EM: Sending Standalone Ack for MessageCounter:16671548 on exchange 37205i - disabled: true - - - label: "Step 9: TH reads ConnectMaxTimeSeconds Attribute from the DUT" + command: "readAttribute" + attribute: "ScanMaxTimeSeconds" + response: + constraints: + type: int8u + minValue: 1 + maxValue: 255 + + - label: "Step 9: TH reads ConnectMaxTimeSeconds attribute from the DUT" PICS: CNET.S.A0003 - verification: | - ./chip-tool networkcommissioning read connect-max-time-seconds 1 0 - - Via the TH (chip-tool), Verify the ConnectMaxTimeSeconds attribute that contains value in the range of 1 to 255 secs. - - [1653473821.367214][29821:29826] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0003 DataVersion: 1600858167 - [1653473821.367283][29821:29826] CHIP:TOO: ConnectMaxTimeSeconds: 20 - [1653473821.367379][29821:29826] CHIP:EM: Sending Standalone Ack for MessageCounter:187119 on exchange 50022i - disabled: true + command: "readAttribute" + attribute: "ConnectMaxTimeSeconds" + response: + constraints: + type: int8u + minValue: 1 + maxValue: 255 - label: "Step 10: TH reads InterfaceEnabled attribute from the DUT" PICS: CNET.S.A0004 - verification: | - ./chip-tool networkcommissioning read interface-enabled 1 0 - - Via the TH (chip-tool), Verify the InterfaceEnabled attribute that contains bool value as True. - - [1653473893.275901][29834:29839] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0004 DataVersion: 1600858167 - [1653473893.275964][29834:29839] CHIP:TOO: InterfaceEnabled: TRUE - [1653473893.276084][29834:29839] CHIP:EM: Sending Standalone Ack for MessageCounter:13157245 on exchange 55578i - disabled: true + command: "readAttribute" + attribute: "InterfaceEnabled" + response: + value: true + constraints: + type: boolean - label: "Step 11: TH reads LastNetworkingStatus attribute from the DUT" PICS: CNET.S.A0005 - verification: | - ./chip-tool networkcommissioning read last-networking-status 1 0 - - Via the TH (chip-tool), Verify the LastNetworkingStatus attribute that contains value as 0 that mentions success. - - [1653473918.484769][29840:29845] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0005 DataVersion: 1600858167 - [1653473918.484843][29840:29845] CHIP:TOO: LastNetworkingStatus: 0 - [1653473918.484940][29840:29845] CHIP:EM: Sending Standalone Ack for MessageCounter:10161085 on exchange 18769 - disabled: true + command: "readAttribute" + attribute: "LastNetworkingStatus" + response: + value: 0 + constraints: + type: NetworkCommissioningStatusEnum - label: - "Step 12: TH reads the LastNetworkID attribute from the DUT TH reads + "Step 12a: TH reads the LastNetworkID attribute from the DUT. TH reads the Networks attribute from the DUT" PICS: CNET.S.A0006 - verification: | - ./chip-tool networkcommissioning read last-network-id 1 0 - - Via the TH (chip-tool), Verify: - -that the LastNetworkID attribute that contains NetworkID that should be the type of octstr with a length range 1 to 32. - -if the Networks attribute list is Empty, then LastNetworkID attribute value is null. - - [1653474059.383553][27286:27291] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006 DataVersion: 1912591449 - [1653474059.383618][27286:27291] CHIP:TOO: LastNetworkID: 47524C50726976617465 - [1653474059.383723][27286:27291] CHIP:EM: Sending Standalone Ack for MessageCounter:6975079 on exchange 34674i - - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify the lastnetworkID is present in the NetworkID in the entries of Network. - - [1654250379.881780][5309:5314] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 3741733376 - [1654250379.881974][5309:5314] CHIP:TOO: Networks: 1 entries - [1654250379.882123][5309:5314] CHIP:TOO: [1]: { - [1654250379.882196][5309:5314] CHIP:TOO: NetworkID: 47524C50726976617465 - [1654250379.882257][5309:5314] CHIP:TOO: Connected: TRUE - [1654250379.882312][5309:5314] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "LastNetworkID" + response: + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + constraints: + type: octet_string + minLength: 1 + maxLength: 32 + + - label: "Step 12b: TH reads the Networks attribute list from the DUT" + PICS: CNET.S.A0001 + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 13: TH reads the LastConnectErrorValue attribute from the DUT" PICS: CNET.S.A0007 - verification: | - ./chip-tool networkcommissioning read last-connect-error-value 1 0 - - Via the TH (chip-tool), Verify the LastConnectErrorValue attribute that contains value as null. - - [1653474102.061746][29860:29865] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0007 DataVersion: 1600858167 - [1653474102.061812][29860:29865] CHIP:TOO: LastConnectErrorValue: null - [1653474102.061934][29860:29865] CHIP:EM: Sending Standalone Ack for MessageCounter:5193529 on exchange 29546i - disabled: true + command: "readAttribute" + attribute: "LastConnectErrorValue" + response: + value: null + constraints: + type: int32s diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_10.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_10.yaml index 0bdd84f83d5ab7..1320f1f2c1d8a3 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_10.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_10.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.8. [TC-CNET-4.10] [Thread] Verification for RemoveNetwork Command @@ -22,298 +21,304 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_THREAD endpoint: 0 + PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET: + type: octet_string + defaultValue: "hex:1111111122222222" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on Thread network " verification: | - 1. DUT supports CNET.S.F01(TH) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_THREAD with FeatureMap attribute of 2 - 3. DUT is commissioned on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 4. TH can communicate with the DUT on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - disabled: true + ./chip-tool pairing ble-thread 0x12344321 + + [1698660637.937566][6429:6431] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698660637.937644][6429:6431] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698660637.937705][6429:6431] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698660637.937750][6429:6431] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698660637.937812][6429:6431] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698660637.937863][6429:6431] CHIP:DIS: Closing all BLE connections + [1698660637.937911][6429:6431] CHIP:IN: Clearing BLE pending packets. + [1698660637.938582][6429:6431] CHIP:BLE: Auto-closing end point's BLE connection. + [1698660637.938645][6429:6431] CHIP:DL: Closing BLE GATT connection (con 0xffff9c034bb0) + [1698660637.938805][6429:6430] CHIP:DL: BluezDisconnect peer=F7:D4:24:D2:4A:1F + [1698660638.365208][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: MarkForEviction Type:1 LSID:62220 + [1698660638.365311][6429:6431] CHIP:SC: SecureSession[0xffff9400f900, LSID:62220]: State change 'kActive' --> 'kPendingEviction' + [1698660638.365440][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: Released - Type:1 LSID:62220 + [1698660638.365529][6429:6431] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698660638.365598][6429:6431] CHIP:TOO: Device commissioning completed with success + [1698660638.365873][6429:6431] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 2 + constraints: + type: bitmap32 - label: "Step 1: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 1 62 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. - - [1650391404.723087][10042:10047] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1650391404.723164][10042:10047] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1650391404.723269][10042:10047] CHIP:TOO: ArmFailSafeResponse: { - [1650391404.723342][10042:10047] CHIP:TOO: errorCode: 0 - [1650391404.723381][10042:10047] CHIP:TOO: debugText: - [1650391404.723419][10042:10047] CHIP:TOO: } - [1650391404.723479][10042:10047] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 2: TH1 reads Networks attribute from the DUT and save the number of entries as 'NumNetworks'" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should be as PIXIT.CNET .THREAD_1 ST_OPERA TIONALDA TASET. - -that the connected status should be the type of bool value as TRUE. - - [1657790578.359665][5247:5252] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 2276799582 - [1657790578.359820][5247:5252] CHIP:TOO: Networks: 1 entries - [1657790578.359925][5247:5252] CHIP:TOO: [1]: { - [1657790578.359992][5247:5252] CHIP:TOO: NetworkID: 1850171990782922 - [1657790578.360049][5247:5252] CHIP:TOO: Connected: TRUE - [1657790578.360103][5247:5252] CHIP:TOO: } - [1657790578.360277][5247:5252] CHIP:EM: Sending Standalone Ack for MessageCounter:195491393 on exchange 23374i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + saveAs: NumNetworks + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] - label: "Step 3: TH finds the index of the Networks list entry with NetworkID field value PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and saves it as 'Userth_netidx'" verification: | - - disabled: true + TH finds the index of the Networks list entry with NetworkID + field value PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and saves it as + 'Userth_netidx' + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 4: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:1850171990782922 62 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1657790635.532308][5254:5259] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1657790635.532395][5254:5259] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1657790635.532528][5254:5259] CHIP:TOO: NetworkConfigResponse: { - [1657790635.532617][5254:5259] CHIP:TOO: networkingStatus: 0 - [1657790635.532671][5254:5259] CHIP:TOO: networkIndex: 0 - [1657790635.532718][5254:5259] CHIP:TOO: } - [1657790635.532794][5254:5259] CHIP:DMG: ICR moving to [AwaitingDe] - [1657790635.532886][5254:5259] CHIP:EM: Sending Standalone Ack for MessageCounter:162806082 on exchange 55401i - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 5: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify that the Networks attribute list has empty(0 entries). - - [1657625584.426746][2703:2708] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 1201757611 - [1657625584.427014][2703:2708] CHIP:TOO: Networks: 0 entries - [1657625584.427238][2703:2708] CHIP:EM: Sending Standalone Ack for MessageCounter:71370645 on exchange 9137i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + type: list + excludes: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] - label: "Step 6: TH reads LastNetworkingStatus attribute from the DUT" PICS: CNET.S.A0005 - verification: | - ./chip-tool networkcommissioning read last-networking-status 1 0 - - Via the TH (chip-tool), Verify the LastNetworkingStatus attribute that contains value as 0 that mentions success. - - [1657625631.550171][2710:2715] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0005 DataVersion: 1201757611 - [1657625631.550337][2710:2715] CHIP:TOO: LastNetworkingStatus: 0 - [1657625631.550495][2710:2715] CHIP:EM: Sending Standalone Ack for MessageCounter:45041626 on exchange 48206i - disabled: true + command: "readAttribute" + attribute: "LastNetworkingStatus" + response: + value: 0 + constraints: + type: NetworkCommissioningStatusEnum - label: "Step 7: TH reads LastNetworkID attribute from the DUT" PICS: CNET.S.A0006 - verification: | - ./chip-tool networkcommissioning read last-network-id 1 0 - - Via the TH (chip-tool), Verify that the LastNetworkID has PIXIT.CNET.THRE AD_1ST_OPERATI ONALDATASET. - - [1657625691.050998][2718:2724] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006 DataVersion: 1201757611 - [1657625691.051142][2718:2724] CHIP:TOO: LastNetworkID: 1850171990782922 - [1657625691.051317][2718:2724] CHIP:EM: Sending Standalone Ack for MessageCounter:151340993 on exchange 26558i - disabled: true + command: "readAttribute" + attribute: "LastNetworkID" + response: + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - label: "Step 8: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657625860.742472][2739:2744] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2669958173 - [1657625860.742607][2739:2744] CHIP:TOO: Breadcrumb: 1 - [1657625860.742764][2739:2744] CHIP:EM: Sending Standalone Ack for MessageCounter:246118803 on exchange 50195i - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 - label: "Step 9: TH sends ConnectNetwork command to the DUT with NetworkID field set to the extended PAN ID of PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 2" + timedInteractionTimeoutMs: 5000 PICS: CNET.S.C04.Rsp && CNET.S.C06.Rsp - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:1850171990782922 1 0 --Breadcrumb 2 - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains networkingStatus value as 3(NetworkIdNotFound). - - [1657625912.836563][2747:2752] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0007 - [1657625912.836768][2747:2752] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0007 - [1657625912.836933][2747:2752] CHIP:TOO: ConnectNetworkResponse: { - [1657625912.837012][2747:2752] CHIP:TOO: networkingStatus: 3 - [1657625912.837075][2747:2752] CHIP:TOO: errorValue: 0 - [1657625912.837131][2747:2752] CHIP:TOO: } - [1657625912.837220][2747:2752] CHIP:DMG: ICR moving to [AwaitingDe] - [1657625912.837330][2747:2752] CHIP:EM: Sending Standalone Ack for MessageCounter:259218125 on exchange 18569i - disabled: true + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 2 + response: + values: + - name: "NetworkingStatus" + value: 3 + - name: "ErrorValue" + constraints: + type: int32s - label: "Step 10: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657781070.617341][4823:4828] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2383846386 - [1657781070.617458][4823:4828] CHIP:TOO: Breadcrumb: 1 - [1657781070.617656][4823:4828] CHIP:EM: Sending Standalone Ack for MessageCounter:198695370 on exchange 43070i - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 - label: "Step 11: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 0" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 0 0 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 0 secs to the TH. - - [1657626058.290176][2767:2772] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657626058.290276][2767:2772] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657626058.290399][2767:2772] CHIP:TOO: ArmFailSafeResponse: { - [1657626058.290501][2767:2772] CHIP:TOO: errorCode: 0 - [1657626058.290560][2767:2772] CHIP:TOO: debugText: - [1657626058.290613][2767:2772] CHIP:TOO: } - [1657626058.290699][2767:2772] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true - - - label: "Step 12: TH reads Networks attribute from the DUT" + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 0 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" + + - label: "Step 12: TH reads Networks attribute from the DUT'" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should be as PIXIT.CNET .THREAD_1 ST_OPERA TIONALDA TASET. - -that the connected status should be the type of bool value as TRUE. - - [1657790810.454838][5308:5313] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 2276799582 - [1657790810.454996][5308:5313] CHIP:TOO: Networks: 1 entries - [1657790810.455100][5308:5313] CHIP:TOO: [1]: { - [1657790810.455168][5308:5313] CHIP:TOO: NetworkID: 1850171990782922 - [1657790810.455225][5308:5313] CHIP:TOO: Connected: TRUE - [1657790810.455280][5308:5313] CHIP:TOO: } - [1657790810.455479][5308:5313] CHIP:EM: Sending Standalone Ack for MessageCounter:256297954 on exchange 23059i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] - label: "Step 13: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 1 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. - - [1657626161.611078][2780:2785] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657626161.611183][2780:2785] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657626161.611310][2780:2785] CHIP:TOO: ArmFailSafeResponse: { - [1657626161.611412][2780:2785] CHIP:TOO: errorCode: 0 - [1657626161.611471][2780:2785] CHIP:TOO: debugText: - [1657626161.611525][2780:2785] CHIP:TOO: } - [1657626161.611613][2780:2785] CHIP:DMG: ICR moving to [AwaitingDe] - [1657626161.611722][2780:2785] CHIP:EM: Sending Standalone Ack for MessageCounter:216998470 on exchange 11517i - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 14: TH sends RemoveNetwork Command to the DUT with NetworkID field set to extended PAN ID of PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:1850171990782922 32 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1657791030.761976][5336:5341] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1657791030.762070][5336:5341] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1657791030.762217][5336:5341] CHIP:TOO: NetworkConfigResponse: { - [1657791030.762314][5336:5341] CHIP:TOO: networkingStatus: 0 - [1657791030.762375][5336:5341] CHIP:TOO: networkIndex: 0 - [1657791030.762427][5336:5341] CHIP:TOO: } - [1657791030.762511][5336:5341] CHIP:DMG: ICR moving to [AwaitingDe] - [1657791030.762608][5336:5341] CHIP:EM: Sending Standalone Ack for MessageCounter:266194732 on exchange 7795i - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 15: TH sends the CommissioningComplete command to the DUT" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning commissioning-complete 1 0 - - Via the TH (chip-tool), Verify the DUT sends CommissioningComplete command and the errorCode field is 0(OK). - - [1657626243.485752][2795:2801] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 - [1657626243.485947][2795:2801] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0005 - [1657626243.486108][2795:2801] CHIP:TOO: CommissioningCompleteResponse: { - [1657626243.486232][2795:2801] CHIP:TOO: errorCode: 0 - [1657626243.486293][2795:2801] CHIP:TOO: debugText: - [1657626243.486368][2795:2801] CHIP:TOO: } - [1657626243.486455][2795:2801] CHIP:DMG: ICR moving to [AwaitingDe] - [1657626243.486572][2795:2801] CHIP:EM: Sending Standalone Ack for MessageCounter:8090042 on exchange 53943i - disabled: true + cluster: "General Commissioning" + command: "CommissioningComplete" + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 16: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 0 to ensure the CommissioningComplete call properly persisted the failsafe context. This call should have no effect if Commissioning Complete call is handled correctly" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 0 0 62 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 0 secs to the TH. - - - [1657626274.218994][2802:2807] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657626274.219096][2802:2807] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657626274.219220][2802:2807] CHIP:TOO: ArmFailSafeResponse: { - [1657626274.219322][2802:2807] CHIP:TOO: errorCode: 0 - [1657626274.219381][2802:2807] CHIP:TOO: debugText: - [1657626274.219436][2802:2807] CHIP:TOO: } - [1657626274.219522][2802:2807] CHIP:DMG: ICR moving to [AwaitingDe] - [1657626274.219632][2802:2807] CHIP:EM: Sending Standalone Ack for MessageCounter:52231112 on exchange 13160i - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 0 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 17: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify that the Networks attribute list has empty(0 entries). - - [1657626300.861344][2808:2813] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 1201757611 - [1657626300.861492][2808:2813] CHIP:TOO: Networks: 0 entries - [1657626300.861678][2808:2813] CHIP:EM: Sending Standalone Ack for MessageCounter:89835226 on exchange 41681i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + type: list + excludes: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_11.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_11.yaml index 64d6cacf5c05c1..3b67d6c9955190 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_11.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_11.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.9. [TC-CNET-4.11] [WiFi] Verification for ConnectNetwork Command @@ -22,86 +21,122 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_WIFI endpoint: 0 -tests: - - label: "Preconditions" - verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 4. TH can connect to two valid Wi-Fi access points: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID - disabled: true + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:47524C50726976617465" + PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:7A6967626565686F6D65" + PIXIT.CNET.WIFI_2ND_ACCESSPOINT_CREDENTIALS: + type: octet_string + defaultValue: "hex:70617373776f7264313233" - - label: "Commission TH and DUT over BLE to setup the Wi-Fi" +tests: + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on WiFi network" verification: | - - disabled: true + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - label: "Step 1: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 1 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. - - [1653479952.284160][30473:30478] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1653479952.284231][30473:30478] CHIP:TOO: ArmFailSafeResponse: { - [1653479952.284273][30473:30478] CHIP:TOO: errorCode: 0 - [1653479952.284297][30473:30478] CHIP:TOO: debugText: - [1653479952.284322][30473:30478] CHIP:TOO: } - [1653479952.284361][30473:30478] CHIP:DMG: ICR moving to [AwaitingDe] - [1653479952.284425][30473:30478] CHIP:EM: Sending Standalone Ack for MessageCounter:9947639 on exchange 30687i - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 2: TH reads Networks attribute from the DUT and saves the number of entries as 'NumNetworks'" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that contains value as PIXIT.CNET.WIFI_1ST_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as TRUE. - - [1657733068.835240][7475:7480] CHIP:TOO: Networks: 1 entries - [1657733068.835354][7475:7480] CHIP:TOO: [1]: { - [1657733068.835434][7475:7480] CHIP:TOO: NetworkID: 47524C50726976617465 - [1657733068.835487][7475:7480] CHIP:TOO: Connected: TRUE - [1657733068.835535][7475:7480] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + saveAs: NumNetworks + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 3: TH finds the index of the Networks list entry with NetworkID for PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and saves it as 'Userwifi_netidx'" verification: | - - disabled: true + TH finds the index of the Networks list entry with NetworkID for PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and saves it as 'Userwifi_netidx' + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.A0001 + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 4: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1657290079.168208][2668:2673] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1657290079.168273][2668:2673] CHIP:TOO: NetworkConfigResponse: { - [1657290079.168311][2668:2673] CHIP:TOO: networkingStatus: 0 - [1657290079.168338][2668:2673] CHIP:TOO: networkIndex: 0 - [1657290079.168362][2668:2673] CHIP:TOO: } - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 5: TH sends AddOrUpdateWiFiNetwork command to the DUT with SSID @@ -109,121 +144,125 @@ tests: set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_CREDENTIALS and Breadcrumb field set to 1" PICS: CNET.S.C02.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning add-or-update-wi-fi-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning add-or-update-wi-fi-network hex:536265655F4D6F746F Sunsuraj 1 0 --Breadcrumb 1 ( second network) - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1657288838.207746][2455:2460] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1657288838.207816][2455:2460] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1657288838.207935][2455:2460] CHIP:TOO: NetworkConfigResponse: { - [1657288838.207990][2455:2460] CHIP:TOO: networkingStatus: 0 - [1657288838.208030][2455:2460] CHIP:TOO: networkIndex: 0 - [1657288838.208068][2455:2460] CHIP:TOO: } - disabled: true + command: "AddOrUpdateWiFiNetwork" + arguments: + values: + - name: "SSID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Credentials" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_CREDENTIALS + - name: "breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 + - name: "DebugText" + constraints: + maxLength: 512 - label: "Step 6: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that contains value as PIXIT.CNET.WIFI_2ND_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as FALSE. - - [1657733345.351745][7595:7600] CHIP:TOO: Networks: 1 entries - [1657733345.351888][7595:7600] CHIP:TOO: [1]: { - [1657733345.351952][7595:7600] CHIP:TOO: NetworkID: 536265655F4D6F746F - [1657733345.352000][7595:7600] CHIP:TOO: Connected: FALSE - [1657733345.352053][7595:7600] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, + Connected: false, + }, + ] - label: "Step 7: TH sends ConnectNetwork command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID and Breadcrumb field set to 2" - PICS: CNET.S.C06.Rsp - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:536265655F4D6F746F 1 0 --Breadcrumb 2 (second network) - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains Networking Status value as 0 (success). - - [1653479953.633815][30491:30496] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0007 - [1653479953.633986][30491:30496] CHIP:TOO: ConnectNetworkResponse: { - [1653479953.634133][30491:30496] CHIP:TOO: networkingStatus: 0 - [1653479953.634195][30491:30496] CHIP:TOO: errorValue: null - [1653479953.634275][30491:30496] CHIP:TOO: } - [1653479953.634367][30491:30496] CHIP:DMG: ICR moving to [AwaitingDe] - [1653479953.634501][30491:30496] CHIP:EM: Sending Standalone Ack for MessageCounter:490923 on exchange 21425i - disabled: true + PICS: CNET.C.C06.Tx + timedInteractionTimeoutMs: 5000 + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 2 + response: + values: + - name: "NetworkingStatus" + value: 0 + - name: "ErrorValue" + constraints: + type: int32s - label: "Step 8: TH changes its WiFi connection to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID" verification: | Make sure TH also joins the 2nd Wifi network to have a connectivity to the DUT. - disabled: true + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 9: TH discovers and connects to DUT on the PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID operational network" - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that contains value as PIXIT.CNET.WIFI_2ND_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as TRUE. - - [1657733596.457792][7640:7645] CHIP:TOO: Networks: 1 entries - [1657733596.457867][7640:7645] CHIP:TOO: [1]: { - [1657733596.457906][7640:7645] CHIP:TOO: NetworkID: 536265655F4D6F746F - [1657733596.457940][7640:7645] CHIP:TOO: Connected: TRUE - [1657733596.457972][7640:7645] CHIP:TOO: } - disabled: true + PICS: CNET.S.A0001 + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 10: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" PICS: CNET.S.C06.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 2. - - [1657733618.370511][7653:7658] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2956231097 - [1657733618.370581][7653:7658] CHIP:TOO: Breadcrumb: 2 - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 2 + constraints: + type: int64u - label: "Step 11: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 0. This forcibly disarms the fail-safe and is expected to cause the changes of configuration to NetworkCommissioning cluster done so far to be reverted." - verification: | - ./chip-tool generalcommissioning arm-fail-safe 0 0 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 0 secs to the TH. - - [1657289119.775902][2519:2524] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657289119.775973][2519:2524] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657289119.776050][2519:2524] CHIP:TOO: ArmFailSafeResponse: { - [1657289119.776102][2519:2524] CHIP:TOO: errorCode: 0 - [1657289119.776141][2519:2524] CHIP:TOO: debugText: - [1657289119.776177][2519:2524] CHIP:TOO: } - disabled: true - + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 0 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + + #Issue: https://github.com/project-chip/connectedhomeip/issues/26848 - label: "Step 12 & 13: TH changes its WiFi connection to - PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and TH discovers and connects to - DUT on the PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID operational network" + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, TH discovers and connects to DUT + on the PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID operational network" + PICS: CNET.S.A0001 && PICS_USER_PROMPT verification: | ./chip-tool networkcommissioning read networks 1 0 @@ -238,46 +277,47 @@ tests: [1684497703.596697][3941:3943] CHIP:TOO: Connected: FALSE [1684497703.596721][3941:3943] CHIP:TOO: } [1684497703.596882][3941:3943] CHIP:EM: <<< [E:51584i S:48726 M:88313254 (Ack:206238679)] (S) Msg TX to 1:0000000000000001 [3A8F] --- Type 0000:10 (SecureChannel:StandaloneAck) - disabled: true + cluster: "LogCommands" + command: "UserPrompt" + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 14: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 0 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout of 900 secs to the TH. - - [1657289228.311622][2529:2534] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657289228.311668][2529:2534] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657289228.311721][2529:2534] CHIP:TOO: ArmFailSafeResponse: { - [1657289228.311758][2529:2534] CHIP:TOO: errorCode: 0 - [1657289228.311783][2529:2534] CHIP:TOO: debugText: - [1657289228.311806][2529:2534] CHIP:TOO: } - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 - label: "Step 15: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1684497783.207292][4010:4012] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1684497783.207338][4010:4012] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1684497783.207481][4010:4012] CHIP:TOO: NetworkConfigResponse: { - [1684497783.207531][4010:4012] CHIP:TOO: networkingStatus: 0 - [1684497783.207555][4010:4012] CHIP:TOO: networkIndex: 0 - [1684497783.207578][4010:4012] CHIP:TOO: } - [1684497783.207635][4010:4012] CHIP:DMG: ICR moving to [AwaitingDe] - [1684497783.207723][4010:4012] CHIP:EM: <<< [E:60874i S:60117 M:37627612 (Ack:227520870)] (S) Msg TX to 1: - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 16: TH sends AddOrUpdateWiFiNetwork command to the DUT with SSID @@ -285,96 +325,107 @@ tests: set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_CREDENTIALS and Breadcrumb field set to 1" PICS: CNET.S.C02.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning add-or-update-wi-fi-network-network hex: 1 0 - - Below is an example: - ./chip-tool networkcommissioning add-or-update-wi-fi-network hex:536265655F4D6F746F Sunsuraj 1 0 --Breadcrumb 1 ( second network) - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1657734444.832145][7736:7741] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1657734444.832215][7736:7741] CHIP:TOO: NetworkConfigResponse: { - [1657734444.832251][7736:7741] CHIP:TOO: networkingStatus: 0 - [1657734444.832277][7736:7741] CHIP:TOO: networkIndex: 0 - [1657734444.832299][7736:7741] CHIP:TOO: } - [1657734444.832335][7736:7741] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "AddOrUpdateWiFiNetwork" + arguments: + values: + - name: "SSID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Credentials" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_CREDENTIALS + - name: "breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 + - name: "DebugText" + constraints: + maxLength: 512 - label: "Step 17: TH sends ConnectNetwork command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID and Breadcrumb field set to 3" PICS: CNET.S.C06.Rsp && CNET.S.C07.Tx - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - Below is an example: - ./chip-tool networkcommissioning connect-network hex:536265655F4D6F746F 1 0 --Breadcrumb 3 (second network) - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains Networking Status value as 0 (success). - - [1657734624.698518][7768:7773] CHIP:TOO: ConnectNetworkResponse: { - [1657734624.698601][7768:7773] CHIP:TOO: networkingStatus: 0 - [1657734624.698661][7768:7773] CHIP:TOO: errorValue: null - [1657734624.698740][7768:7773] CHIP:TOO: } - disabled: true + command: "ConnectNetwork" + timedInteractionTimeoutMs: 5000 + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 3 + response: + values: + - name: "NetworkingStatus" + value: 0 + - name: "ErrorValue" + constraints: + type: int32s - label: - "Step 18 & 19: TH changes its WiFi connection to - PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID and TH discovers and connects to - DUT on the PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID operational network" + "Step 18: TH changes its WiFi connection to + PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID" verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that contains value as PIXIT.CNET.WIFI_2ND_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as TRUE. + Make sure TH also joins the 2nd Wifi network to have a connectivity to the DUT. + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - [1657733596.457792][7640:7645] CHIP:TOO: Networks: 1 entries - [1657733596.457867][7640:7645] CHIP:TOO: [1]: { - [1657733596.457906][7640:7645] CHIP:TOO: NetworkID: 536265655F4D6F746F - [1657733596.457940][7640:7645] CHIP:TOO: Connected: TRUE - [1657733596.457972][7640:7645] CHIP:TOO: } - disabled: true + - label: + "Step 19: TH discovers and connects to DUT on the + PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID operational network" + PICS: CNET.S.A0001 + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 20: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" PICS: CNET.S.C06.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 3. - - [1657734757.740003][7793:7798] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2956231102 - [1657734757.740140][7793:7798] CHIP:TOO: Breadcrumb: 3 - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 3 + constraints: + type: int64u - label: "Step 21: TH sends the CommissioningComplete command to the DUT" - verification: | - ./chip-tool generalcommissioning commissioning-complete 1 0 - - Via the TH (chip-tool), Verify the DUT sends CommissioningComplete command and the errorCode field is 0(OK). - - [1657734803.411199][7802:7808] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0005 - [1657734803.411256][7802:7808] CHIP:TOO: CommissioningCompleteResponse: { - [1657734803.411306][7802:7808] CHIP:TOO: errorCode: 0 - [1657734803.411333][7802:7808] CHIP:TOO: debugText: - [1657734803.411356][7802:7808] CHIP:TOO: } - disabled: true - - - label: "Step 23: TH reads Networks attribute from the DUT" + cluster: "General Commissioning" + command: "CommissioningComplete" + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" + + - label: "Step 22: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should be as PIXIT.CNET.WIFI_2ND_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as TRUE. - - [1657734855.925075][7819:7824] CHIP:TOO: Networks: 1 entries - [1657734855.925147][7819:7824] CHIP:TOO: [1]: { - [1657734855.925185][7819:7824] CHIP:TOO: NetworkID: 536265655F4D6F746F - [1657734855.925215][7819:7824] CHIP:TOO: Connected: TRUE - [1657734855.925243][7819:7824] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, + Connected: true, + }, + ] diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_15.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_15.yaml index df0a9776df37f5..ec89cc137f89e4 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_15.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_15.yaml @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.13. [TC-CNET-4.15] [WiFi] NetworkIDNotFound value as @@ -22,81 +21,126 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_WIFI endpoint: 0 + PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:7A6967626565686F6D65" + tests: - - label: "Preconditions" + - label: "Precondition: DUT is factory reset" verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is factory reset - 4. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 5. TH can communicate with the DUT - 6. DUT MaxNetworks attribute value is at least 1 and is saved as 'MaxNetworksValue' for future use - disabled: true - - - label: - "Step 1: TH sends ArmFailSafe command to the DUT with the - ExpiryLengthSeconds field set to 900" + Reset Devices to factory defaults + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Factory Reset the DUT and enter 'y' after success" + - name: "expectedValue" + value: "y" + + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on WiFi network" verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 0 1 0 + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH with error code 0. + - label: + "Precondition: DUT MaxNetworks attribute value is at least 1 and is + saved as 'MaxNetworksValue' for future use" + PICS: CNET.S.A0000 + command: "readAttribute" + attribute: "MaxNetworks" + response: + saveAs: MaxNetworksValue + constraints: + type: int8u + minValue: 1 + maxValue: 255 - [1650383264.543046][44233:44238] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1650383264.543109][44233:44238] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1650383264.543212][44233:44238] CHIP:TOO: ArmFailSafeResponse: { - [1650383264.543275][44233:44238] CHIP:TOO: errorCode: 0 - [1650383264.543313][44233:44238] CHIP:TOO: debugText: - [1650383264.543348][44233:44238] CHIP:TOO: } - [1650383264.543402][44233:44238] CHIP:DMG: ICR moving to [AwaitingDe] - [1650383264.543470][44233:44238] CHIP:EM: Sending Standalone Ack for MessageCounter:6293749 on exchange 65264i - disabled: true + - label: + "Step 1: TH sends ArmFailSafe command to the DUT with + ExpiryLengthSeconds set to 900" + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 2: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, which does not match the provisioned network, and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 3 (NetworkIDNotFound). - - [1650383270.888700][44239:44244] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1650383270.888774][44239:44244] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1650383270.888876][44239:44244] CHIP:TOO: NetworkConfigResponse: { - [1650383270.888952][44239:44244] CHIP:TOO: networkingStatus: 3 - [1650383270.888992][44239:44244] CHIP:TOO: } - [1650383270.889044][44239:44244] CHIP:DMG: ICR moving to [AwaitingDe] - [1650383270.889125][44239:44244] CHIP:EM: Sending Standalone Ack for MessageCounter:4715093 on exchange 59014i - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 3 - label: "Step 3: TH sends ConnectNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID, which does not match the provisioned network, and Breadcrumb field set to 1" PICS: CNET.S.C06.Rsp && CNET.S.C07.Tx - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains Networking Status value as 3 (NetworkIDNotFound). - - [1650383278.349428][44245:44250] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0007 - [1650383278.349490][44245:44250] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0007 - [1650383278.349592][44245:44250] CHIP:TOO: ConnectNetworkResponse: { - [1650383278.349656][44245:44250] CHIP:TOO: networkingStatus: 3 - [1650383278.349693][44245:44250] CHIP:TOO: errorValue: 0 - [1650383278.349727][44245:44250] CHIP:TOO: } - [1650383278.349782][44245:44250] CHIP:DMG: ICR moving to [AwaitingDe] - [1650383278.349847][44245:44250] CHIP:EM: Sending Standalone Ack for MessageCounter:11070796 on exchange 31080i - disabled: true + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_2ND_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 3 + - name: "ErrorValue" + constraints: + type: int32s diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_16.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_16.yaml index 102e7f809ff4fe..36fa1ca62ceb30 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_16.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_16.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.14. [TC-CNET-4.16] [Thread] NetworkIDNotFound value as @@ -22,37 +21,97 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_THREAD endpoint: 0 + PIXIT.CNET.THREAD_2ND_OPERATIONALDATASET: + type: octet_string + defaultValue: "hex:1111111122222222" + tests: - - label: "Preconditions" + - label: "Precondition : Factory reset the DUT" verification: | - 1. DUT supports CNET.S.F01(TH) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_THREAD with FeatureMap attribute of 2 - 3. DUT is factory reset - 4. DUT is commissioned on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 5. TH can communicate with the DUT on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 6. DUT MaxNetworks attribute value is at least 1 and is saved as 'MaxNetworksValue' for future use - disabled: true - - - label: - "Step 1: TH sends ArmFailSafe command to the DUT with the - ExpiryLengthSeconds field set to 900" + Reset Devices to factory defaults + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Factory Reset the DUT and enter 'y' after success" + - name: "expectedValue" + value: "y" + + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on Thread network " verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 0 54 0 + ./chip-tool pairing ble-thread 0x12344321 + + [1698660637.937566][6429:6431] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698660637.937644][6429:6431] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698660637.937705][6429:6431] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698660637.937750][6429:6431] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698660637.937812][6429:6431] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698660637.937863][6429:6431] CHIP:DIS: Closing all BLE connections + [1698660637.937911][6429:6431] CHIP:IN: Clearing BLE pending packets. + [1698660637.938582][6429:6431] CHIP:BLE: Auto-closing end point's BLE connection. + [1698660637.938645][6429:6431] CHIP:DL: Closing BLE GATT connection (con 0xffff9c034bb0) + [1698660637.938805][6429:6430] CHIP:DL: BluezDisconnect peer=F7:D4:24:D2:4A:1F + [1698660638.365208][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: MarkForEviction Type:1 LSID:62220 + [1698660638.365311][6429:6431] CHIP:SC: SecureSession[0xffff9400f900, LSID:62220]: State change 'kActive' --> 'kPendingEviction' + [1698660638.365440][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: Released - Type:1 LSID:62220 + [1698660638.365529][6429:6431] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698660638.365598][6429:6431] CHIP:TOO: Device commissioning completed with success + [1698660638.365873][6429:6431] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after successfull Commission" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 2 + constraints: + type: bitmap32 - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. + - label: + "Precondition: DUT MaxNetworks attribute value is at least 1 and is + saved as 'MaxNetworksValue' for future use" + PICS: CNET.S.A0000 + command: "readAttribute" + attribute: "MaxNetworks" + response: + saveAs: MaxNetworksValue + constraints: + type: int8u + minValue: 1 + maxValue: 255 - [1650392597.976230][10152:10157] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1650392597.976363][10152:10157] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1650392597.976539][10152:10157] CHIP:TOO: ArmFailSafeResponse: { - [1650392597.976665][10152:10157] CHIP:TOO: errorCode: 0 - [1650392597.976729][10152:10157] CHIP:TOO: debugText: - [1650392597.976785][10152:10157] CHIP:TOO: } - [1650392597.976874][10152:10157] CHIP:DMG: ICR moving to [AwaitingDe] - [1650392597.976987][10152:10157] CHIP:EM: Sending Standalone Ack for MessageCounter:10494017 on exchange 14665i - disabled: true + - label: + "Step 1: TH sends ArmFailSafe command to the DUT with + ExpiryLengthSeconds set to 900" + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 2: TH sends RemoveNetwork Command to the DUT with NetworkID @@ -60,27 +119,17 @@ tests: PIXIT.CNET.THREAD_2ND_OPERATIONALDATASET, which does not match the commissioned network, and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network 2111111122222222 54 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 3 (NetworkIDNotFound). - - [1683268296.896031][12131:12134] CHIP:DMG: InteractionModelRevision = 1 - [1683268296.896239][12131:12134] CHIP:DMG: }, - [1683268296.896474][12131:12134] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1683268296.897219][12131:12134] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1683268296.897526][12131:12134] CHIP:TOO: NetworkConfigResponse: { - [1683268296.897745][12131:12134] CHIP:TOO: networkingStatus: 3 - [1683268296.898546][12131:12134] CHIP:TOO: } - [1683268296.898769][12131:12134] CHIP:DMG: ICR moving to [AwaitingDe] - [1683268296.901995][12131:12134] CHIP:EM: <<< [E:60271i S:53927 M:99281930 (Ack:250739545)] (S) Msg TX to 1:0000000000000036 [345E] --- Type 0000:10 (SecureChannel:StandaloneAck) - [1683268296.903001][12131:12134] CHIP:IN: (S) Sending msg 99281930 on secure session with LSID: 53927 - [1683268296.905843][12131:12134] CHIP:EM: Flushed pending ack for MessageCounter:250739545 on exchange 60271i - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_2ND_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 3 - label: "Step 3: TH sends ConnectNetwork Command to the DUT with NetworkID @@ -88,20 +137,14 @@ tests: PIXIT.CNET.THREAD_2ND_OPERATIONALDATASET, which does not match the commissioned network, and Breadcrumb field set to 1" PICS: CNET.S.C06.Rsp && CNET.S.C07.Tx - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network 47524C50726976617465 54 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains Networking Status value as 3 (NetworkIDNotFound). - - [1650392982.606392][10188:10193] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0007 - [1650392982.606501][10188:10193] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0007 - [1650392982.606653][10188:10193] CHIP:TOO: ConnectNetworkResponse: { - [1650392982.606753][10188:10193] CHIP:TOO: networkingStatus: 3 - [1650392982.606815][10188:10193] CHIP:TOO: errorValue: 0 - [1650392982.606872][10188:10193] CHIP:TOO: } - [1650392982.606960][10188:10193] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_2ND_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 3 diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_2.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_2.yaml index 2fa7fd06383799..7b60871fdbc6e3 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_2.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_2.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.2. [TC-CNET-4.2] [Thread] Verification for attributes check @@ -22,217 +21,175 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_THREAD endpoint: 0 + PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET: + type: octet_string + defaultValue: "hex:1111111122222222" tests: - - label: "Preconditions" - verification: | - 1. DUT supports CNET.S.F01(TH) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_THREAD with FeatureMap attribute of 2 - 3. DUT is commissioned on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 4. TH can communicate with the DUT on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - disabled: true - - label: "Step 1: Factory reset the DUT" verification: | - - disabled: true - + Reset Devices to factory defaults + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Factory Reset the DUT and enter 'y' after success" + - name: "expectedValue" + value: "y" + + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 - label: "Step 2: Commission TH and DUT on Thread network" verification: | - - disabled: true + ./chip-tool pairing ble-thread 0x12344321 + + [1698660637.937566][6429:6431] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698660637.937644][6429:6431] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698660637.937705][6429:6431] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698660637.937750][6429:6431] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698660637.937812][6429:6431] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698660637.937863][6429:6431] CHIP:DIS: Closing all BLE connections + [1698660637.937911][6429:6431] CHIP:IN: Clearing BLE pending packets. + [1698660637.938582][6429:6431] CHIP:BLE: Auto-closing end point's BLE connection. + [1698660637.938645][6429:6431] CHIP:DL: Closing BLE GATT connection (con 0xffff9c034bb0) + [1698660637.938805][6429:6430] CHIP:DL: BluezDisconnect peer=F7:D4:24:D2:4A:1F + [1698660638.365208][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: MarkForEviction Type:1 LSID:62220 + [1698660638.365311][6429:6431] CHIP:SC: SecureSession[0xffff9400f900, LSID:62220]: State change 'kActive' --> 'kPendingEviction' + [1698660638.365440][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: Released - Type:1 LSID:62220 + [1698660638.365529][6429:6431] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698660638.365598][6429:6431] CHIP:TOO: Device commissioning completed with success + [1698660638.365873][6429:6431] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after successfull Commission" + - name: "expectedValue" + value: "y" - label: "Step 3: TH reads Descriptor Cluster from the DUT with EP0 TH reads ServerList from the DUT" - verification: | - ./chip-tool descriptor read server-list 54 0 - - Via the TH (chip-tool), verify that the server list has value as 49. - - [1686293236.629388][3601:3603] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001D Attribute 0x0000_0001 DataVersion: 3777417155 - [1686293236.629594][3601:3603] CHIP:TOO: ServerList: 28 entries - [1686293236.629688][3601:3603] CHIP:TOO: [1]: 3 - [1686293236.629749][3601:3603] CHIP:TOO: [2]: 4 - [1686293236.629807][3601:3603] CHIP:TOO: [3]: 29 - [1686293236.629876][3601:3603] CHIP:TOO: [4]: 30 - [1686293236.629935][3601:3603] CHIP:TOO: [5]: 31 - [1686293236.629991][3601:3603] CHIP:TOO: [6]: 40 - [1686293236.630048][3601:3603] CHIP:TOO: [7]: 42 - [1686293236.630106][3601:3603] CHIP:TOO: [8]: 43 - [1686293236.630190][3601:3603] CHIP:TOO: [9]: 44 - [1686293236.630253][3601:3603] CHIP:TOO: [10]: 45 - [1686293236.630311][3601:3603] CHIP:TOO: [11]: 46 - [1686293236.630367][3601:3603] CHIP:TOO: [12]: 47 - [1686293236.630424][3601:3603] CHIP:TOO: [13]: 48 - [1686293236.630481][3601:3603] CHIP:TOO: [14]: 49 - [1686293236.630538][3601:3603] CHIP:TOO: [15]: 50 - [1686293236.630604][3601:3603] CHIP:TOO: [16]: 51 - [1686293236.630662][3601:3603] CHIP:TOO: [17]: 52 - [1686293236.630718][3601:3603] CHIP:TOO: [18]: 53 - [1686293236.630775][3601:3603] CHIP:TOO: [19]: 54 - [1686293236.630831][3601:3603] CHIP:TOO: [20]: 55 - [1686293236.630888][3601:3603] CHIP:TOO: [21]: 60 - [1686293236.630944][3601:3603] CHIP:TOO: [22]: 62 - [1686293236.631002][3601:3603] CHIP:TOO: [23]: 63 - [1686293236.631058][3601:3603] CHIP:TOO: [24]: 64 - [1686293236.631114][3601:3603] CHIP:TOO: [25]: 65 - [1686293236.631171][3601:3603] CHIP:TOO: [26]: 70 - [1686293236.631227][3601:3603] CHIP:TOO: [27]: 1029 - [1686293236.631285][3601:3603] CHIP:TOO: [28]: 4294048774 - [1686293236.631613][3601:3603] CHIP:EM: <<< [E:2627i S:46052 M:27080745 (Ack:161764674)] (S) Msg TX to 1:0000000000000037 [8709] --- Type 0000:10 (SecureChannel:StandaloneAck) - disabled: true + cluster: "Descriptor" + command: "readAttribute" + attribute: "ServerList" + response: + constraints: + type: list + contains: [49] - label: "Step 4: TH reads FeatureMap attribute from the DUT" - verification: | - ./chip-tool networkcommissioning read feature-map 54 0 - - Via the TH (chip-tool), verify that FeatureMap attribute value as 2 for Thread NetworkInterface. - - [1645772204.502545][3809:3814] CHIP:DMG: SuppressResponse = true, - [1645772204.502608][3809:3814] CHIP:DMG: InteractionModelRevision = 1 - [1645772204.502683][3809:3814] CHIP:DMG: } - [1645772204.503195][3809:3814] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFCDataVersion: 92121563 - [1645772204.503398][3809:3814] CHIP:TOO: FeatureMap: 2 - [1645772204.503556][3809:3814] CHIP:EM: Sending Standalone Ack for MessageCounter:5988746 on exchange 46140i - disabled: true - - - label: "Step 5: TH reads the MaxNetworks attribute from the DUT" - PICS: CNET.S.A0000 - verification: | - ./chip-tool networkcommissioning read max-networks 54 0 - - Via the TH (chip-tool), Verify the MaxNetworks attribute that contains value in the range of 1 to 255. - - [1645772548.257320][3837:3842] CHIP:DMG: SuppressResponse = true, - [1645772548.257381][3837:3842] CHIP:DMG: InteractionModelRevision = 1 - [1645772548.257437][3837:3842] CHIP:DMG: } - [1645772548.257735][3837:3842] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0000DataVersion: 92121563 - [1645772548.257878][3837:3842] CHIP:TOO: MaxNetworks: 1 - [1645772548.258032][3837:3842] CHIP:EM: Sending Standalone Ack for MessageCounter:7388528 on exchange 41499i - disabled: true + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 2 + constraints: + type: bitmap32 - label: - "Step 6: TH saves the MaxNetworks attribute value as - 'MaxNetworksValue' for future use" - verification: | - TH1 saves the MaxNetworks attribute value - disabled: true + "Step 5 & 6: TH reads the MaxNetworks attribute from the DUT. TH saves + the MaxNetworks attribute value as 'MaxNetworksValue' for future use" + PICS: CNET.S.A0000 + command: "readAttribute" + attribute: "MaxNetworks" + response: + saveAs: MaxNetworksValue + constraints: + type: int8u + minValue: 1 + maxValue: 255 - label: "Step 7: TH reads the Networks attribute list from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 54 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should be type of octstr with a length range 1 to 32. - -that the connected status is in the type of bool value as TRUE. - - [1645772651.445097][3856:3861] CHIP:DMG: SuppressResponse = true, - [1645772651.445149][3856:3861] CHIP:DMG: InteractionModelRevision = 1 - [1645772651.445209][3856:3861] CHIP:DMG: } - [1645772651.445754][3856:3861] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001DataVersion: 92121563 - [1645772651.445875][3856:3861] CHIP:TOO: Networks: 1 entries - [1645772651.446057][3856:3861] CHIP:TOO: [1]: { - [1645772651.446120][3856:3861] CHIP:TOO: NetworkID: 1111161622222211 - [1645772651.446173][3856:3861] CHIP:TOO: Connected: TRUE - [1645772651.446228][3856:3861] CHIP:TOO: } - [1645772651.446431][3856:3861] CHIP:EM: Sending Standalone Ack for MessageCounter:12695576 on exchange 11133i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] - label: "Step 8: TH reads ScanMaxTimeSeconds attribute from the DUT" PICS: CNET.S.A0002 - verification: | - ./chip-tool networkcommissioning read scan-max-time-seconds 54 0 - - Via the TH (chip-tool), Verify the ScanMaxTimeSeconds attribute that contains value in the range of 1 to 255 secs. - - [1645772820.740795][3867:3872] CHIP:DMG: SuppressResponse = true, - [1645772820.740855][3867:3872] CHIP:DMG: InteractionModelRevision = 1 - [1645772820.740903][3867:3872] CHIP:DMG: } - [1645772820.741209][3867:3872] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0002DataVersion: 92121563 - [1645772820.741357][3867:3872] CHIP:TOO: ScanMaxTimeSeconds: 10 - [1645772820.741512][3867:3872] CHIP:EM: Sending Standalone Ack for MessageCounter:10309775 on exchange 55305i - disabled: true - - - label: "Step 9: TH reads ConnectMaxTimeSeconds Attribute from the DUT" + command: "readAttribute" + attribute: "ScanMaxTimeSeconds" + response: + constraints: + type: int8u + minValue: 1 + maxValue: 255 + + - label: "Step 9: TH reads ConnectMaxTimeSeconds attribute from the DUT" PICS: CNET.S.A0003 - verification: | - ./chip-tool networkcommissioning read connect-max-time-seconds 54 0 - - Via the TH (chip-tool), Verify the ConnectMaxTimeSeconds attribute that contains value in the range of 1 to 255 secs. - - [1645772901.118880][3879:3884] CHIP:DMG: SuppressResponse = true, - [1645772901.119008][3879:3884] CHIP:DMG: InteractionModelRevision = 1 - [1645772901.119141][3879:3884] CHIP:DMG: } - [1645772901.119684][3879:3884] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0003DataVersion: 92121563 - [1645772901.119885][3879:3884] CHIP:TOO: ConnectMaxTimeSeconds: 20 - [1645772901.120100][3879:3884] CHIP:EM: Sending Standalone Ack for MessageCounter:11917538 on exchange 4188 - disabled: true + command: "readAttribute" + attribute: "ConnectMaxTimeSeconds" + response: + constraints: + type: int8u + minValue: 1 + maxValue: 255 - label: "Step 10: TH reads InterfaceEnabled attribute from the DUT" PICS: CNET.S.A0004 - verification: | - ./chip-tool networkcommissioning read interface-enabled 54 0 - - Via the TH (chip-tool), Verify the InterfaceEnabled attribute that contains bool value as True. - - [1645772984.653996][3895:3900] CHIP:DMG: SuppressResponse = true, - [1645772984.654043][3895:3900] CHIP:DMG: InteractionModelRevision = 1 - [1645772984.654084][3895:3900] CHIP:DMG: } - [1645772984.654310][3895:3900] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0004DataVersion: 92121563 - [1645772984.654388][3895:3900] CHIP:TOO: InterfaceEnabled: TRUE - [1645772984.654530][3895:3900] CHIP:EM: Sending Standalone Ack for MessageCounter:14026610 on exchange 33717i - disabled: true + command: "readAttribute" + attribute: "InterfaceEnabled" + response: + value: true + constraints: + type: boolean - label: "Step 11: TH reads LastNetworkingStatus attribute from the DUT" PICS: CNET.S.A0005 - verification: | - ./chip-tool networkcommissioning read last-networking-status 54 0 - - Via the TH (chip-tool), Verify the LastNetworkingStatus attribute that contains value as 0 that mentions success. - - [1645773078.930516][3905:3910] CHIP:DMG: SuppressResponse = true, - [1645773078.930579][3905:3910] CHIP:DMG: InteractionModelRevision = 1 - [1645773078.930635][3905:3910] CHIP:DMG: } - [1645773078.930943][3905:3910] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0005DataVersion: 92121563 - [1645773078.931067][3905:3910] CHIP:TOO: LastNetworkingStatus: 0 - [1645773078.931217][3905:3910] CHIP:EM: Sending Standalone Ack for MessageCounter:16576011 on exchange 44187i - disabled: true + command: "readAttribute" + attribute: "LastNetworkingStatus" + response: + value: 0 + constraints: + type: NetworkCommissioningStatusEnum - label: - "Step 12: TH reads the LastNetworkID attribute from the DUT TH reads + "Step 12a: TH reads the LastNetworkID attribute from the DUT. TH reads the Networks attribute from the DUT" PICS: CNET.S.A0006 - verification: | - ./chip-tool networkcommissioning read last-network-id 54 0 - - Via the TH (chip-tool), Verify: - -that the LastNetworkID attribute that contains NetworkID that should be type of octstr with a length range 1 to 32. - -if the Networks attribute list is Empty, then LastNetworkID attribute value is null. - - [1645773167.178501][3913:3918] CHIP:DMG: SuppressResponse = true, - [1645773167.178561][3913:3918] CHIP:DMG: InteractionModelRevision = 1 - [1645773167.178618][3913:3918] CHIP:DMG: } - [1645773167.178919][3913:3918] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006DataVersion: 92121563 - [1645773167.182241][3913:3918] CHIP:TOO: LastNetworkID: 1111161622222211 - [1645773167.182422][3913:3918] CHIP:EM: Sending Standalone Ack for MessageCounter:2029571 on exchange 18566i - disabled: true + command: "readAttribute" + attribute: "LastNetworkID" + response: + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + constraints: + type: octet_string + minLength: 1 + maxLength: 32 + + - label: "Step 12b: TH reads the Networks attribute list from the DUT" + PICS: CNET.S.A0001 + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET, + Connected: true, + }, + ] - label: "Step 13: TH reads the LastConnectErrorValue attribute from the DUT" PICS: CNET.S.A0007 - verification: | - ./chip-tool networkcommissioning read last-connect-error-value 54 0 - - Via the TH (chip-tool), Verify the LastConnectErrorValue attribute that contains value as null. - - [1645773318.752774][3938:3943] CHIP:DMG: SuppressResponse = true, - [1645773318.752861][3938:3943] CHIP:DMG: InteractionModelRevision = 1 - [1645773318.753043][3938:3943] CHIP:DMG: } - [1645773318.753543][3938:3943] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0007DataVersion: 92121563 - [1645773318.753724][3938:3943] CHIP:TOO: LastConnectErrorValue: null - [1645773318.753985][3938:3943] CHIP:EM: Sending Standalone Ack for MessageCounter:15303417 on exchange 41937i - disabled: true + command: "readAttribute" + attribute: "LastConnectErrorValue" + response: + value: null + constraints: + type: int32s diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_22.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_22.yaml index 410a4ca2b56751..b8e82aced329fc 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_22.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_22.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 4.4.20. [TC-CNET-4.22] [Thread] Verification for ScanNetworks command @@ -22,179 +21,212 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_THREAD endpoint: 0 + PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET: + type: octet_string + defaultValue: "hex:1111111122222222" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on Thread network " verification: | - 1. DUT supports CNET.S.F01(TH) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_THREAD with FeatureMap attribute of 2 - 3. DUT is commissioned on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 4. TH can communicate with the DUT on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - disabled: true + ./chip-tool pairing ble-thread 0x12344321 + + [1698660637.937566][6429:6431] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698660637.937644][6429:6431] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698660637.937705][6429:6431] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698660637.937750][6429:6431] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698660637.937812][6429:6431] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698660637.937863][6429:6431] CHIP:DIS: Closing all BLE connections + [1698660637.937911][6429:6431] CHIP:IN: Clearing BLE pending packets. + [1698660637.938582][6429:6431] CHIP:BLE: Auto-closing end point's BLE connection. + [1698660637.938645][6429:6431] CHIP:DL: Closing BLE GATT connection (con 0xffff9c034bb0) + [1698660637.938805][6429:6430] CHIP:DL: BluezDisconnect peer=F7:D4:24:D2:4A:1F + [1698660638.365208][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: MarkForEviction Type:1 LSID:62220 + [1698660638.365311][6429:6431] CHIP:SC: SecureSession[0xffff9400f900, LSID:62220]: State change 'kActive' --> 'kPendingEviction' + [1698660638.365440][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: Released - Type:1 LSID:62220 + [1698660638.365529][6429:6431] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698660638.365598][6429:6431] CHIP:TOO: Device commissioning completed with success + [1698660638.365873][6429:6431] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" - label: "Step 1: TH sends ScanNetworks command to the DUT with the SSID field omitted and the Breadcrumb field set to 1" PICS: CNET.S.C00.Rsp && CNET.S.C01.Tx - verification: | - ./chip-tool networkcommissioning scan-networks 54 0 --Breadcrumb 1 + command: "ScanNetworks" + arguments: + values: + - name: "SSID" + value: "" + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + constraints: + anyOf: [0, 1, 5, 6, 12] + - name: "DebugText" + constraints: + maxLength: 512 + - name: "ThreadScanResults" + constraints: + type: list + - label: + "Step 1: Verify each element in the ThreadScanResults list will have + the following fields:" + verification: | Via the TH (all-clusters-app), verify: - -the NetworkingStatus value as 0 that mentions success. - -the PanId value is in the range of 0 to 65534. - -the ExtendedPanId value is type of uint64. - -the NetworkName value is type of string with a size of 1 to 16 bytes. - -the Channel is type of uint16 with range 0 to 65535. - -the version value is type of uint8(0 to 255). - -the ExtendedAddress is a hwaddr with a size of 8 bytes - -the RSSI is of type int8 with a range of -120 to 0. - -the LQI is type of uint8(0 to 255). - - [1658297246.000815][7679:7684] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0001 - [1658297246.001029][7679:7684] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0001 - [1658297246.001190][7679:7684] CHIP:TOO: ScanNetworksResponse: { - [1658297246.001270][7679:7684] CHIP:TOO: networkingStatus: 0 - [1658297246.001357][7679:7684] CHIP:TOO: threadScanResults: 1 entries - [1658297246.001485][7679:7684] CHIP:TOO: [1]: { - [1658297246.001548][7679:7684] CHIP:TOO: PanId: 64206 - [1658297246.001607][7679:7684] CHIP:TOO: ExtendedPanId: 3861484836749312 - [1658297246.001665][7679:7684] CHIP:TOO: NetworkName: GRL - [1658297246.001721][7679:7684] CHIP:TOO: Channel: 11 - [1658297246.001777][7679:7684] CHIP:TOO: Version: 4 - [1658297246.001841][7679:7684] CHIP:TOO: ExtendedAddress: 166E0A0000000001 - [1658297246.001900][7679:7684] CHIP:TOO: Rssi: -81 - [1658297246.001955][7679:7684] CHIP:TOO: Lqi: 48 - [1658297246.002010][7679:7684] CHIP:TOO: } - [1658297246.002070][7679:7684] CHIP:TOO: } - [1658297246.002181][7679:7684] CHIP:DMG: ICR moving to [AwaitingDe] - [1658297246.002298][7679:7684] CHIP:EM: Sending Standalone Ack for MessageCounter:124278362 on exchange 24525i - disabled: true + -the PanId value is in the range of 0 to 65534. + -the ExtendedPanId value is type of uint64. + -the NetworkName value is type of string with a size of 1 to 16 bytes. + -the Channel is type of uint16 with range 0 to 65535. + -the version value is type of uint8(0 to 255). + -the ExtendedAddress is a hwaddr with a size of 8 bytes + -the RSSI is of type int8 with a range of -120 to 0. + -the LQI is type of uint8(0 to 255). + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.C00.Rsp && CNET.S.C01.Tx + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 2: TH reads Breadcrumb attribute from the General Commissioning Cluster" - verification: | - ./chip-tool generalcommissioning read breadcrumb 54 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657688310.986593][1613:1618] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 829017612 - [1657688310.989412][1613:1618] CHIP:TOO: Breadcrumb: 1 - [1657688310.989586][1613:1618] CHIP:EM: Sending Standalone Ack for MessageCounter:63605306 on exchange 55886i - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 + constraints: + type: int64u - label: "Step 3: TH sends ScanNetworks command to the DUT with the SSID field set to null and the Breadcrumb field set to 2" PICS: CNET.S.C00.Rsp && CNET.S.C01.Tx - verification: | - ./chip-tool networkcommissioning scan-networks 54 0 --Breadcrumb 2 + command: "ScanNetworks" + arguments: + values: + - name: "SSID" + value: null + - name: "Breadcrumb" + value: 2 + response: + values: + - name: "NetworkingStatus" + constraints: + anyOf: [0, 1, 5, 6, 12] + - name: "DebugText" + constraints: + maxLength: 512 + - name: "ThreadScanResults" + constraints: + type: list + - label: + "Step 3: Verify each element in the ThreadScanResults list will have + the following fields:" + verification: | Via the TH (all-clusters-app), verify: - -the NetworkingStatus value as 0 that mentions success. - -the PanId value is in the range of 0 to 65534. - -the ExtendedPanId value is type of uint64. - -the NetworkName value is type of string with a size of 1 to 16 bytes. - -the Channel is type of uint16 with range 0 to 65535. - -the version value is type of uint8(0 to 255). - -the ExtendedAddress is a hwaddr with a size of 8 bytes - -the RSSI is of type int8 with a range of -120 to 0. - -the LQI is type of uint8(0 to 255). - - [1658297283.141075][7695:7700] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0001 - [1658297283.141183][7695:7700] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0001 - [1658297283.141356][7695:7700] CHIP:TOO: ScanNetworksResponse: { - [1658297283.141438][7695:7700] CHIP:TOO: networkingStatus: 0 - [1658297283.141534][7695:7700] CHIP:TOO: threadScanResults: 2 entries - [1658297283.141663][7695:7700] CHIP:TOO: [1]: { - [1658297283.141729][7695:7700] CHIP:TOO: PanId: 64206 - [1658297283.141788][7695:7700] CHIP:TOO: ExtendedPanId: 3861484836749312 - [1658297283.141847][7695:7700] CHIP:TOO: NetworkName: GRL - [1658297283.141904][7695:7700] CHIP:TOO: Channel: 11 - [1658297283.141961][7695:7700] CHIP:TOO: Version: 4 - [1658297283.142023][7695:7700] CHIP:TOO: ExtendedAddress: 166E0A0000000001 - [1658297283.142079][7695:7700] CHIP:TOO: Rssi: -80 - [1658297283.142134][7695:7700] CHIP:TOO: Lqi: 52 - [1658297283.142188][7695:7700] CHIP:TOO: } - [1658297283.142271][7695:7700] CHIP:TOO: [2]: { - [1658297283.142331][7695:7700] CHIP:TOO: PanId: 64206 - [1658297283.142386][7695:7700] CHIP:TOO: ExtendedPanId: 3861484836749312 - [1658297283.142443][7695:7700] CHIP:TOO: NetworkName: GRL - [1658297283.142500][7695:7700] CHIP:TOO: Channel: 11 - [1658297283.142551][7695:7700] CHIP:TOO: Version: 4 - [1658297283.142609][7695:7700] CHIP:TOO: ExtendedAddress: 166E0A0000000001 - [1658297283.142665][7695:7700] CHIP:TOO: Rssi: -83 - [1658297283.142718][7695:7700] CHIP:TOO: Lqi: 44 - [1658297283.142771][7695:7700] CHIP:TOO: } - [1658297283.142828][7695:7700] CHIP:TOO: } - [1658297283.142958][7695:7700] CHIP:DMG: ICR moving to [AwaitingDe] - [1658297283.143074][7695:7700] CHIP:EM: Sending Standalone Ack for MessageCounter:115607423 on exchange 55136i - disabled: true + -the PanId value is in the range of 0 to 65534. + -the ExtendedPanId value is type of uint64. + -the NetworkName value is type of string with a size of 1 to 16 bytes. + -the Channel is type of uint16 with range 0 to 65535. + -the version value is type of uint8(0 to 255). + -the ExtendedAddress is a hwaddr with a size of 8 bytes + -the RSSI is of type int8 with a range of -120 to 0. + -the LQI is type of uint8(0 to 255). + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.C00.Rsp && CNET.S.C01.Tx + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 4: TH reads Breadcrumb attribute from the General Commissioning Cluster" - verification: | - ./chip-tool generalcommissioning read breadcrumb 54 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 2. - - [1657688397.398564][1626:1631] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 829017613 - [1657688397.398697][1626:1631] CHIP:TOO: Breadcrumb: 2 - [1657688397.398852][1626:1631] CHIP:EM: Sending Standalone Ack for MessageCounter:129342305 on exchange 25970i - disabled: true - + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 2 + constraints: + type: int64u - label: "Step 5: TH sends ScanNetworks command to the DUT with the SSID field set to a random string of ASCII characters with a size of between 1 and 31 characters and the Breadcrumb field set to 3" PICS: CNET.S.C00.Rsp && CNET.S.C01.Tx - verification: | - ./chip-tool networkcommissioning scan-networks 54 0 --Breadcrumb 3 + command: "ScanNetworks" + arguments: + values: + - name: "SSID" + value: "hex:1111111522222222" + - name: "Breadcrumb" + value: 3 + response: + values: + - name: "NetworkingStatus" + constraints: + anyOf: [0, 1, 5, 6, 12] + - name: "DebugText" + constraints: + maxLength: 512 + - name: "ThreadScanResults" + constraints: + type: list + - label: + "Step 5: Verify each element in the ThreadScanResults list will have + the following fields:" + verification: | Via the TH (all-clusters-app), verify: - -the NetworkingStatus value should be as 0 that mentions success. - -the PanId value should be with in the range of 0 to 65534. - -the ExtendedPanId value is type of uint64. - -the NetworkName value is type of string with a size of 1 to 16 bytes. - -the Channel is type of uint16 with range 0 to 65535. - -the version value is type of uint8(0 to 255). - -the ExtendedAddress is a hwaddr with a size of 8 bytes - -the RSSI is of type int8 with a range of -120 to 0. - -the LQI is type of uint8(0 to 255). - - [1658297312.201709][7708:7713] CHIP:DMG: }, - [1658297312.201898][7708:7713] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0001 - [1658297312.202021][7708:7713] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0001 - [1658297312.202196][7708:7713] CHIP:TOO: ScanNetworksResponse: { - [1658297312.202276][7708:7713] CHIP:TOO: networkingStatus: 0 - [1658297312.202359][7708:7713] CHIP:TOO: threadScanResults: 1 entries - [1658297312.202481][7708:7713] CHIP:TOO: [1]: { - [1658297312.202544][7708:7713] CHIP:TOO: PanId: 64206 - [1658297312.202604][7708:7713] CHIP:TOO: ExtendedPanId: 3861484836749312 - [1658297312.202663][7708:7713] CHIP:TOO: NetworkName: GRL - [1658297312.202718][7708:7713] CHIP:TOO: Channel: 11 - [1658297312.202775][7708:7713] CHIP:TOO: Version: 4 - [1658297312.202838][7708:7713] CHIP:TOO: ExtendedAddress: 166E0A0000000001 - [1658297312.202897][7708:7713] CHIP:TOO: Rssi: -78 - [1658297312.202952][7708:7713] CHIP:TOO: Lqi: 60 - [1658297312.203007][7708:7713] CHIP:TOO: } - [1658297312.203066][7708:7713] CHIP:TOO: } - [1658297312.203176][7708:7713] CHIP:DMG: ICR moving to [AwaitingDe] - [1658297312.203284][7708:7713] CHIP:EM: Sending Standalone Ack for MessageCounter:217378941 on exchange 37389i - disabled: true + -the PanId value is in the range of 0 to 65534. + -the ExtendedPanId value is type of uint64. + -the NetworkName value is type of string with a size of 1 to 16 bytes. + -the Channel is type of uint16 with range 0 to 65535. + -the version value is type of uint8(0 to 255). + -the ExtendedAddress is a hwaddr with a size of 8 bytes + -the RSSI is of type int8 with a range of -120 to 0. + -the LQI is type of uint8(0 to 255). + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.C00.Rsp && CNET.S.C01.Tx + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 6: TH reads Breadcrumb attribute from the General Commissioning Cluster" - verification: | - ./chip-tool generalcommissioning read breadcrumb 54 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 3. - - [1657688489.553742][1639:1644] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 829017614 - [1657688489.553897][1639:1644] CHIP:TOO: Breadcrumb: 3 - [1657688489.554053][1639:1644] CHIP:EM: Sending Standalone Ack for MessageCounter:86525470 on exchange 7368i - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 3 + constraints: + type: int64u diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_3.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_3.yaml index e65428f1878632..aa7d545e9b4a70 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_3.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_3.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,179 +11,146 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.3. [TC-CNET-4.3] [Ethernet] Verification for attributes check [DUT-Server] + PICS: - CNET.S.F02 config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + # PIXIT.CNET.ENDPOINT_ETHERNET endpoint: 0 + NetworkID: + type: octet_string + defaultValue: "hex:6574682D617070" + payload: + type: char_string + defaultValue: "MT:-24J042C00KA0648G00" tests: - - label: "Preconditions" - verification: | - 1. DUT supports CNET.S.F02(ET) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_ETHERNET with FeatureMap attribute of 4 - 3. DUT has a valid Ethernet connection - 4. TH can communicate with the DUT - disabled: true + - label: "Step 1: Reset Devices to factory defaults" + PICS: PICS_SDK_CI_ONLY + cluster: "SystemCommands" + command: "FactoryReset" - - label: "Step 1: Factory reset the DUT" + - label: "Step 1: Reset Devices to factory defaults" verification: | - - disabled: true + Reset Devices to factory defaults + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Factory Reset the DUT and enter 'y' after success" + - name: "expectedValue" + value: "y" - label: "Step 2: Commission TH and DUT on Ethernet setup" - verification: | - - disabled: true + cluster: "CommissionerCommands" + command: "PairWithCode" + arguments: + values: + - name: "nodeId" + value: nodeId + - name: "payload" + value: payload + + - label: "Step 2: Wait for the commissioned device to be retrieved" + cluster: "DelayCommands" + command: "WaitForCommissionee" + arguments: + values: + - name: "nodeId" + value: nodeId - label: "Step 3: TH reads Descriptor Cluster from the DUT with EP0 TH reads ServerList from the DUT" - verification: | - ./chip-tool descriptor read server-list 1 0 - - Via the TH (chip-tool), verify that the server list has value as 49. - - [1646226258.250313][2446:2451] CHIP:DMG: SuppressResponse = true, - [1646226258.250337][2446:2451] CHIP:DMG: InteractionModelRevision = 1 - [1646226258.250359][2446:2451] CHIP:DMG: } - [1646226258.252027][2446:2451] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_001D Attribute 0x0000_0001DataVersion: 3582931896 - [1646226258.252128][2446:2451] CHIP:TOO: server list: 25 entries - [1646226258.252183][2446:2451] CHIP:TOO: [1]: 3 - [1646226258.252208][2446:2451] CHIP:TOO: [2]: 4 - [1646226258.252232][2446:2451] CHIP:TOO: [3]: 29 - [1646226258.252256][2446:2451] CHIP:TOO: [4]: 30 - [1646226258.252280][2446:2451] CHIP:TOO: [5]: 31 - [1646226258.252303][2446:2451] CHIP:TOO: [6]: 40 - [1646226258.252326][2446:2451] CHIP:TOO: [7]: 42 - [1646226258.252349][2446:2451] CHIP:TOO: [8]: 43 - [1646226258.252373][2446:2451] CHIP:TOO: [9]: 44 - [1646226258.252396][2446:2451] CHIP:TOO: [10]: 45 - [1646226258.252420][2446:2451] CHIP:TOO: [11]: 46 - [1646226258.252443][2446:2451] CHIP:TOO: [12]: 48 - [1646226258.252466][2446:2451] CHIP:TOO: [13]: 49 - [1646226258.252489][2446:2451] CHIP:TOO: [14]: 50 - [1646226258.252512][2446:2451] CHIP:TOO: [15]: 51 - [1646226258.252536][2446:2451] CHIP:TOO: [16]: 52 - [1646226258.252559][2446:2451] CHIP:TOO: [17]: 53 - [1646226258.252582][2446:2451] CHIP:TOO: [18]: 54 - [1646226258.252605][2446:2451] CHIP:TOO: [19]: 55 - [1646226258.252629][2446:2451] CHIP:TOO: [20]: 60 - [1646226258.252652][2446:2451] CHIP:TOO: [21]: 62 - [1646226258.252675][2446:2451] CHIP:TOO: [22]: 63 - [1646226258.252698][2446:2451] CHIP:TOO: [23]: 64 - [1646226258.252721][2446:2451] CHIP:TOO: [24]: 65 - [1646226258.252745][2446:2451] CHIP:TOO: [25]: 1029 - [1646226258.255517][2446:2451] CHIP:EM: Sending Standalone Ack for MessageCounter:10627940 on exchange 21443i - disabled: true - - - label: "Step 4: TH reads FeatureMap attribute from the DUT" - verification: | - ./chip-tool networkcommissioning read feature-map 1 0 - - Via the TH (chip-tool), verify that FeatureMap attribute value as 4 for Ethernet NetworkInterface. - - [1649309323.273092][2611:2617] CHIP:DMG: } - [1649309323.273466][2611:2617] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_FFFC DataVersion: 3138976789 - [1649309323.278715][2611:2617] CHIP:TOO: FeatureMap: 4 - [1649309323.278863][2611:2617] CHIP:EM: Sending Standalone Ack for MessageCounter:532597 on exchange 51560i - disabled: true - - - label: "Step 5: TH reads the MaxNetworks attribute from the DUT" - PICS: CNET.S.A0000 - verification: | - ./chip-tool networkcommissioning read max-networks 1 0 - - Via the TH (chip-tool), Verify the MaxNetworks attribute that contains value in the range of 1 to 255. - - [1646226441.815782][2475:2480] CHIP:DMG: SuppressResponse = true, - [1646226441.815849][2475:2480] CHIP:DMG: InteractionModelRevision = 1 - [1646226441.815889][2475:2480] CHIP:DMG: } - [1646226441.816092][2475:2480] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0000DataVersion: 3622667250 - [1646226441.816191][2475:2480] CHIP:TOO: MaxNetworks: 1 - [1646226441.816288][2475:2480] CHIP:EM: Sending Standalone Ack for MessageCounter:14864333 on exchange 39473i - disabled: true + cluster: "Descriptor" + command: "readAttribute" + attribute: "ServerList" + response: + constraints: + type: list + contains: [49] + + - label: "Step 4a: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 4 + constraints: + type: bitmap32 - label: - "Step 6: TH saves the MaxNetworks attribute value as - 'MaxNetworksValue' for future use" - verification: | - TH saves MaxNetworks attribute value - disabled: true + "Step 5 & 6: TH reads the MaxNetworks attribute from the DUT. TH saves + the MaxNetworks attribute value as 'MaxNetworksValue' for future use" + PICS: CNET.S.A0000 + command: "readAttribute" + attribute: "MaxNetworks" + response: + saveAs: MaxNetworksValue + constraints: + type: int8u + minValue: 1 + maxValue: 255 - label: "Step 7: TH reads the Networks attribute list from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that should be the type of octstr with a length range of 1 to 32. - -that the connected status should be type of bool and value as TRUE. - - [1654076774.294361][33659:33664] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 609053543 - [1654076774.294505][33659:33664] CHIP:TOO: Networks: 1 entries - [1654076774.294625][33659:33664] CHIP:TOO: [1]: { - [1654076774.294679][33659:33664] CHIP:TOO: NetworkID: 6368697035 - [1654076774.294726][33659:33664] CHIP:TOO: Connected: TRUE - [1654076774.294774][33659:33664] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: [{ NetworkID: NetworkID, Connected: true }] - label: "Step 8: TH reads InterfaceEnabled attribute from the DUT" PICS: CNET.S.A0004 - verification: | - ./chip-tool networkcommissioning read interface-enabled 1 0 - - Via the TH (chip-tool), Verify the InterfaceEnabled attribute that contains bool value as True. - - [1653473893.275901][29834:29839] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0004 DataVersion: 1600858167 - [1653473893.275964][29834:29839] CHIP:TOO: InterfaceEnabled: TRUE - [1653473893.276084][29834:29839] CHIP:EM: Sending Standalone Ack for MessageCounter:13157245 on exchange 55578i - disabled: true + command: "readAttribute" + attribute: "InterfaceEnabled" + response: + value: true + constraints: + type: boolean - label: "Step 9: TH reads LastNetworkingStatus attribute from the DUT" PICS: CNET.S.A0005 - verification: | - ./chip-tool networkcommissioning read last-networking-status 1 0 - - Via the TH (chip-tool), Verify the LastNetworkingStatus attribute that contains value as null as per spec. - - [1659609891.611493][3877:3882] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0005 DataVersion: 4108508964 - [1659609891.611559][3877:3882] CHIP:TOO: LastNetworkingStatus: null - [1659609891.611689][3877:3882] CHIP:EM: Sending Standalone Ack for MessageCounter:172102677 on exchange 50438i - disabled: true + command: "readAttribute" + attribute: "LastNetworkingStatus" + response: + value: null - label: - "Step 10: TH reads the LastNetworkID attribute from the DUT TH reads + "Step 10: TH reads the LastNetworkID attribute from the DUT. TH reads the Networks attribute from the DUT" PICS: CNET.S.A0006 - verification: | - ./chip-tool networkcommissioning read last-network-id 1 0 - - Via the TH (chip-tool), Verify: - -that the LastNetworkID attribute that contains NetworkID that should be the type of octstr with a length range of 1 to 32. - -if the Networks attribute list is Empty, then LastNetworkID attribute value is null. - - [1659610135.589352][3895:3900] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006 DataVersion: 4108508964 - [1659610135.589410][3895:3900] CHIP:TOO: LastNetworkID: null - [1659610135.589549][3895:3900] CHIP:EM: Sending Standalone Ack for MessageCounter:28696356 on exchange 52969i - disabled: true + command: "readAttribute" + attribute: "LastNetworkID" + response: + value: null + constraints: + type: octet_string + minLength: 1 + maxLength: 32 + + - label: "Step 10: TH reads the Networks attribute list from the DUT" + PICS: CNET.S.A0001 + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: [{ NetworkID: NetworkID, Connected: true }] - label: "Step 11: TH reads the LastConnectErrorValue attribute from the DUT" PICS: CNET.S.A0007 - verification: | - ./chip-tool networkcommissioning read last-connect-error-value 1 0 - - Via the TH (chip-tool), Verify the LastConnectErrorValue attribute that contains value as null. - - [1653483224.839873][28189:28194] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0007 DataVersion: 3189790698 - [1653483224.839927][28189:28194] CHIP:TOO: LastConnectErrorValue: null - [1653483224.840028][28189:28194] CHIP:EM: Sending Standalone Ack for MessageCounter:289132 on exchange 60682i - disabled: true + command: "readAttribute" + attribute: "LastConnectErrorValue" + response: + value: null + constraints: + type: int32s diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_4.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_4.yaml index 26493ea10e7c1c..aaf348393320e1 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_4.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_4.yaml @@ -1,8 +1,8 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. -# You may obtain a copy of the License at +# You may obtain a copy of the License atour sweet # # http://www.apache.org/licenses/LICENSE-2.0 # @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.4. [TC-CNET-4.4] [WiFi] Verification for ScanNetworks command @@ -22,216 +21,153 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_WIFI endpoint: 0 + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:47524C50726976617465" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition : Commission TH and DUT on WiFi network" verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 4. TH can communicate with the DUT - disabled: true - - - label: "Commission TH and DUT over BLE to setup the Wi-Fi" - verification: | - - disabled: true + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - label: - "Step 1: TH sends ScanNetworks command to the DUT with the SSID field + "Step 1a: TH sends ScanNetworks command to the DUT with the SSID field set to 'null' and Breadcrumb field set to 1" PICS: CNET.S.C00.Rsp && CNET.S.C01.Tx - verification: | - ./chip-tool networkcommissioning scan-networks 1 0 --Ssid null --Breadcrumb 1 + command: "ScanNetworks" + arguments: + values: + - name: "SSID" + value: null + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + constraints: + anyOf: [0, 1, 5, 6, 12] + - name: "DebugText" + constraints: + maxLength: 512 + - name: "WiFiScanResults" + constraints: + type: list + - label: + "Step 1a: Verify each element in the WiFiScanResults list will have + the following fields:" + verification: | Via the TH (chip-tool), verify: - -the NetworkingStatus value should be as 0 that mentions success. -the Security value is in the type of map8 with length range 0 to 254. -the SSID value is in the ype of octstr with length range 1 to 32. -the BSSID value is in the type of octstr with length range of 6. -the Channel is in the type of uint16 with range 0 to 65,535. -the WiFi Band is in the of type enum8 with a range of -128 to 127. -the RSSI is in the of type int8 with a range of -120 to 0. - - [1653475026.012811][29937:29942] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0001 - [1653475026.012942][29937:29942] CHIP:TOO: ScanNetworksResponse: { - [1653475026.012983][29937:29942] CHIP:TOO: networkingStatus: 0 - [1653475026.013075][29937:29942] CHIP:TOO: wiFiScanResults: 15 entries - [1653475026.013143][29937:29942] CHIP:TOO: [1]: { - [1653475026.013169][29937:29942] CHIP:TOO: Security: 8 - [1653475026.013195][29937:29942] CHIP:TOO: Ssid: 47524C507269766174655F455854 - [1653475026.013219][29937:29942] CHIP:TOO: Bssid: E01CFCE4B236 - [1653475026.013242][29937:29942] CHIP:TOO: Channel: 11 - [1653475026.013264][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.013286][29937:29942] CHIP:TOO: Rssi: -9 - [1653475026.013310][29937:29942] CHIP:TOO: } - [1653475026.013344][29937:29942] CHIP:TOO: [2]: { - [1653475026.013368][29937:29942] CHIP:TOO: Security: 8 - [1653475026.013390][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.013414][29937:29942] CHIP:TOO: Bssid: C006C3F95EEB - [1653475026.013436][29937:29942] CHIP:TOO: Channel: 153 - [1653475026.013458][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.013479][29937:29942] CHIP:TOO: Rssi: -52 - [1653475026.013500][29937:29942] CHIP:TOO: } - [1653475026.013531][29937:29942] CHIP:TOO: [3]: { - [1653475026.013556][29937:29942] CHIP:TOO: Security: 8 - [1653475026.013578][29937:29942] CHIP:TOO: Ssid: - [1653475026.013599][29937:29942] CHIP:TOO: Bssid: C606C3F95EEB - [1653475026.013621][29937:29942] CHIP:TOO: Channel: 153 - [1653475026.013642][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.013663][29937:29942] CHIP:TOO: Rssi: -52 - [1653475026.013684][29937:29942] CHIP:TOO: } - [1653475026.013715][29937:29942] CHIP:TOO: [4]: { - [1653475026.013738][29937:29942] CHIP:TOO: Security: 12 - [1653475026.013762][29937:29942] CHIP:TOO: Ssid: 7A69676265652D7468726561642D3547487A - [1653475026.013784][29937:29942] CHIP:TOO: Bssid: 6C198FC83ABE - [1653475026.013806][29937:29942] CHIP:TOO: Channel: 44 - [1653475026.013827][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.013848][29937:29942] CHIP:TOO: Rssi: -55 - [1653475026.013869][29937:29942] CHIP:TOO: } - [1653475026.013900][29937:29942] CHIP:TOO: [5]: { - [1653475026.013923][29937:29942] CHIP:TOO: Security: 8 - [1653475026.013945][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.013967][29937:29942] CHIP:TOO: Bssid: C006C3F95F31 - [1653475026.013988][29937:29942] CHIP:TOO: Channel: 48 - [1653475026.014029][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.014051][29937:29942] CHIP:TOO: Rssi: -65 - [1653475026.014073][29937:29942] CHIP:TOO: } - [1653475026.014106][29937:29942] CHIP:TOO: [6]: { - [1653475026.014129][29937:29942] CHIP:TOO: Security: 8 - [1653475026.014151][29937:29942] CHIP:TOO: Ssid: - [1653475026.014172][29937:29942] CHIP:TOO: Bssid: C606C3F95F31 - [1653475026.014194][29937:29942] CHIP:TOO: Channel: 48 - [1653475026.014215][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.014236][29937:29942] CHIP:TOO: Rssi: -65 - [1653475026.014257][29937:29942] CHIP:TOO: } - [1653475026.014288][29937:29942] CHIP:TOO: [7]: { - [1653475026.014311][29937:29942] CHIP:TOO: Security: 8 - [1653475026.014335][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.014357][29937:29942] CHIP:TOO: Bssid: C006C3F95ECF - [1653475026.014379][29937:29942] CHIP:TOO: Channel: 153 - [1653475026.014400][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.014421][29937:29942] CHIP:TOO: Rssi: -68 - [1653475026.014442][29937:29942] CHIP:TOO: } - [1653475026.014473][29937:29942] CHIP:TOO: [8]: { - [1653475026.014496][29937:29942] CHIP:TOO: Security: 8 - [1653475026.014518][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.014540][29937:29942] CHIP:TOO: Bssid: 1027F5374EC7 - [1653475026.014561][29937:29942] CHIP:TOO: Channel: 153 - [1653475026.014582][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.014603][29937:29942] CHIP:TOO: Rssi: -73 - [1653475026.014624][29937:29942] CHIP:TOO: } - [1653475026.014654][29937:29942] CHIP:TOO: [9]: { - [1653475026.014677][29937:29942] CHIP:TOO: Security: 8 - [1653475026.014698][29937:29942] CHIP:TOO: Ssid: - [1653475026.014720][29937:29942] CHIP:TOO: Bssid: 1627F5374EC7 - [1653475026.014741][29937:29942] CHIP:TOO: Channel: 153 - [1653475026.014762][29937:29942] CHIP:TOO: WiFiBand: 2 - [1653475026.014783][29937:29942] CHIP:TOO: Rssi: -72 - [1653475026.014804][29937:29942] CHIP:TOO: } - [1653475026.014834][29937:29942] CHIP:TOO: [10]: { - [1653475026.014858][29937:29942] CHIP:TOO: Security: 12 - [1653475026.014880][29937:29942] CHIP:TOO: Ssid: 4368697031 - [1653475026.014902][29937:29942] CHIP:TOO: Bssid: 0C0E764EF1C8 - [1653475026.014923][29937:29942] CHIP:TOO: Channel: 11 - [1653475026.014944][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.014965][29937:29942] CHIP:TOO: Rssi: -38 - [1653475026.014986][29937:29942] CHIP:TOO: } - [1653475026.015017][29937:29942] CHIP:TOO: [11]: { - [1653475026.015039][29937:29942] CHIP:TOO: Security: 8 - [1653475026.015061][29937:29942] CHIP:TOO: Ssid: 4368697073657475703442 - [1653475026.015083][29937:29942] CHIP:TOO: Bssid: E01CFCEA2A46 - [1653475026.015105][29937:29942] CHIP:TOO: Channel: 11 - [1653475026.015126][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.015147][29937:29942] CHIP:TOO: Rssi: -34 - [1653475026.015168][29937:29942] CHIP:TOO: } - [1653475026.015198][29937:29942] CHIP:TOO: [12]: { - [1653475026.015221][29937:29942] CHIP:TOO: Security: 8 - [1653475026.015244][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.015266][29937:29942] CHIP:TOO: Bssid: 6032B197B89E - [1653475026.015288][29937:29942] CHIP:TOO: Channel: 11 - [1653475026.015309][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.015330][29937:29942] CHIP:TOO: Rssi: -37 - [1653475026.015351][29937:29942] CHIP:TOO: } - [1653475026.015381][29937:29942] CHIP:TOO: [13]: { - [1653475026.015404][29937:29942] CHIP:TOO: Security: 12 - [1653475026.015427][29937:29942] CHIP:TOO: Ssid: 7A69676265652D746872656164 - [1653475026.015449][29937:29942] CHIP:TOO: Bssid: 6C198FC83ABC - [1653475026.015470][29937:29942] CHIP:TOO: Channel: 2 - [1653475026.015491][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.015512][29937:29942] CHIP:TOO: Rssi: -40 - [1653475026.015533][29937:29942] CHIP:TOO: } - [1653475026.015563][29937:29942] CHIP:TOO: [14]: { - [1653475026.015587][29937:29942] CHIP:TOO: Security: 8 - [1653475026.015609][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.015631][29937:29942] CHIP:TOO: Bssid: 1027F5374EC6 - [1653475026.015652][29937:29942] CHIP:TOO: Channel: 6 - [1653475026.015673][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.015694][29937:29942] CHIP:TOO: Rssi: -53 - [1653475026.015714][29937:29942] CHIP:TOO: } - [1653475026.015745][29937:29942] CHIP:TOO: [15]: { - [1653475026.015768][29937:29942] CHIP:TOO: Security: 8 - [1653475026.015789][29937:29942] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475026.015811][29937:29942] CHIP:TOO: Bssid: C006C3F95ECE - [1653475026.015832][29937:29942] CHIP:TOO: Channel: 6 - [1653475026.015853][29937:29942] CHIP:TOO: WiFiBand: 0 - [1653475026.015874][29937:29942] CHIP:TOO: Rssi: -50 - [1653475026.015896][29937:29942] CHIP:TOO: } - [1653475026.015920][29937:29942] CHIP:TOO: } - [1653475026.016050][29937:29942] CHIP:DMG: ICR moving to [AwaitingDe] - [1653475026.016114][29937:29942] CHIP:EM: Sending Standalone Ack for MessageCounter:14684023 on exchange 35456i - disabled: true + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.C00.Rsp && CNET.S.C01.Tx + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: - "Step 1b: TH reads Breadcumb attribute from the General Commissioning + "Step 1b: TH reads Breadcrumb attribute from the General Commissioning Cluster" - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657190614.753193][5241:5246] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2805642039 - [1657190614.753305][5241:5246] CHIP:TOO: Breadcrumb: 1 - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 + constraints: + type: int64u - label: "Step 2a: TH sends ScanNetworks Command to the DUT with SSID field set - to PIXIT.CNET.WIFI_ 1ST_ACCESSPOINT _SSID and Breadcrumb field set to - 2" + to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 2" PICS: CNET.S.C00.Rsp && CNET.S.C01.Tx - verification: | - Below is an example: - ./chip-tool networkcommissioning scan-networks 1 0 --Ssid hex:47524C50726976617465 --Breadcrumb 2 - - Via the TH (chip-tool), verify the ScanNetworks response with first network SSID. - - [1653475824.575642][30076:30081] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0001 - [1653475824.575807][30076:30081] CHIP:TOO: ScanNetworksResponse: { - [1653475824.575888][30076:30081] CHIP:TOO: networkingStatus: 0 - [1653475824.575966][30076:30081] CHIP:TOO: wiFiScanResults: 1 entries - [1653475824.576108][30076:30081] CHIP:TOO: [1]: { - [1653475824.576168][30076:30081] CHIP:TOO: Security: 8 - [1653475824.576227][30076:30081] CHIP:TOO: Ssid: 47524C50726976617465 - [1653475824.576283][30076:30081] CHIP:TOO: Bssid: E01CFCE4B236 - [1653475824.576339][30076:30081] CHIP:TOO: Channel: 11 - [1653475824.576392][30076:30081] CHIP:TOO: WiFiBand: 0 - [1653475824.576445][30076:30081] CHIP:TOO: Rssi: -9 - [1653475824.576500][30076:30081] CHIP:TOO: } - [1653475824.576560][30076:30081] CHIP:TOO: } - [1653475824.576668][30076:30081] CHIP:DMG: ICR moving to [AwaitingDe] - [1653475824.576777][30076:30081] CHIP:EM: Sending Standalone Ack for MessageCounter:251134 on exchange 38023i - disabled: true + command: "ScanNetworks" + arguments: + values: + - name: "SSID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 2 + response: + values: + - name: "NetworkingStatus" + value: 0 + - name: "DebugText" + constraints: + maxLength: 512 + - name: "WiFiScanResults" + constraints: + type: list - label: - "Step 2b: TH reads Breadcumb attribute from the General Commissioning - Cluster" + "Step 2a: Verify each element in the WiFiScanResults list will have + the following fields: " verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 2. + Via the TH (chip-tool), verify: + -the Security value is in the type of map8 with length range 0 to 254. + -the SSID value is in the ype of octstr with length range 1 to 32. + -the BSSID value is in the type of octstr with length range of 6. + -the Channel is in the type of uint16 with range 0 to 65,535. + -the WiFi Band is in the of type enum8 with a range of -128 to 127. + -the RSSI is in the of type int8 with a range of -120 to 0. + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT && CNET.S.C00.Rsp && CNET.S.C01.Tx + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - [1657197542.352377][5661:5666] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2805642042 - [1657197542.352450][5661:5666] CHIP:TOO: Breadcrumb: 2 - disabled: true + - label: + "Step 2b: TH reads Breadcrumb attribute from the General Commissioning + Cluster" + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 2 + constraints: + type: int64u diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_5.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_5.yaml index 9ef9cefc40617a..3d5a732fae831b 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_5.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_5.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.5. [TC-CNET-4.5] [Wi-Fi] FAILSAFE_REQUIRED message Validation @@ -22,17 +21,50 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_WIFI endpoint: 0 + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:7A6967626565686F6D65" + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_CREDENTIALS: + type: octet_string + defaultValue: "hex:70617373776f7264313233" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on WiFi network" verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 4. TH can communicate with the DUT - disabled: true + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - label: "Step 1: TH sends the AddOrUpdateWiFiNetwork command to the DUT with @@ -40,54 +72,44 @@ tests: T_ACCESSPOINT_SSI D 2. Credentials field set to PIXIT.CNET.WIFI_1S T_ACCESSPOINT_CRE DENTIALS 3. Breadcrumb field set to 1" PICS: CNET.S.C02.Rsp - verification: | - ./chip-tool networkcommissioning add-or-update-wi-fi-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning add-or-update-wi-fi-network hex:47524C50726976617465 grlprivatewifi092010 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the AddOrUpdateWiFiNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "AddOrUpdateWiFiNetwork" + arguments: + values: + - name: "SSID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Credentials" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_CREDENTIALS + - name: "breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED - label: "Step 2: TH sends RemoveNetwork command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCE SSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the RemoveNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED - label: "Step 3: TH sends ConnectNetwork command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCE SSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C06.Rsp - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the ConnectNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_6.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_6.yaml index e9f1368e4c79cb..aeac82e7857335 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_6.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_6.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.6. [TC-CNET-4.6] [Thread] FAILSAFE_REQUIRED message Validation @@ -22,76 +21,93 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" endpoint: 0 + PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET: + type: octet_string + defaultValue: "hex:1111111122222222" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on Thread network" verification: | - 1. DUT supports CNET.S.F01(TH) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_THREAD with FeatureMap attribute of 2 - 3. DUT is commissioned on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - 4. TH can communicate with the DUT on PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET - disabled: true - - - label: "Commission TH and DUT on Thread setup" - verification: | - - disabled: true + ./chip-tool pairing ble-thread 0x12344321 + + [1698660637.937566][6429:6431] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698660637.937644][6429:6431] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698660637.937705][6429:6431] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698660637.937750][6429:6431] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698660637.937812][6429:6431] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698660637.937863][6429:6431] CHIP:DIS: Closing all BLE connections + [1698660637.937911][6429:6431] CHIP:IN: Clearing BLE pending packets. + [1698660637.938582][6429:6431] CHIP:BLE: Auto-closing end point's BLE connection. + [1698660637.938645][6429:6431] CHIP:DL: Closing BLE GATT connection (con 0xffff9c034bb0) + [1698660637.938805][6429:6430] CHIP:DL: BluezDisconnect peer=F7:D4:24:D2:4A:1F + [1698660638.365208][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: MarkForEviction Type:1 LSID:62220 + [1698660638.365311][6429:6431] CHIP:SC: SecureSession[0xffff9400f900, LSID:62220]: State change 'kActive' --> 'kPendingEviction' + [1698660638.365440][6429:6431] CHIP:IN: SecureSession[0xffff9400f900]: Released - Type:1 LSID:62220 + [1698660638.365529][6429:6431] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698660638.365598][6429:6431] CHIP:TOO: Device commissioning completed with success + [1698660638.365873][6429:6431] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 2 + constraints: + type: bitmap32 - label: "Step 1: TH sends the AddOrUpdateThreadNetwork command to the DUT with - the following fields: OperationalDataset field set to - PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET Breadcrumb field set to 1" + OperationalDataset field set to + PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 1" PICS: CNET.S.C03.Rsp - verification: | - ./chip-tool networkcommissioning add-or-update-thread-network-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning add-or-update-thread-network hex:1011101122222229 51 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the AddOrUpdateThreadNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "AddOrUpdateThreadNetwork" + arguments: + values: + - name: "OperationalDataset" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED - label: "Step 2: TH sends RemoveNetwork command to the DUT with NetworkID field set to PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:1011101122222229 51 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the RemoveNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED - label: "Step 3: TH sends ConnectNetwork command to the DUT with NetworkID field set to PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET and Breadcrumb field set to 1" PICS: CNET.S.C06.Rsp - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:1011101122222229 51 0 --Breadcrumb 1 - - Via the TH (chip-tool), verify the FAILSAFE_REQUIRED response for sending the ConnectNetwork command. - - [1657619600.364023][2056:2061] CHIP:DMG: Received Command Response Status for Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0003 Status=0xca - [1657619600.364102][2056:2061] CHIP:TOO: Error: IM Error 0x000005CA: General error: 0xca (FAILSAFE_REQUIRED) - [1657619600.364186][2056:2061] CHIP:DMG: ICR moving to [AwaitingDe] - disabled: true + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.THREAD_1ST_OPERATIONALDATASET + - name: "Breadcrumb" + value: 1 + response: + error: FAILSAFE_REQUIRED diff --git a/src/app/tests/suites/certification/Test_TC_CNET_4_9.yaml b/src/app/tests/suites/certification/Test_TC_CNET_4_9.yaml index 1bb06e91f05c31..341fe7d1cae131 100644 --- a/src/app/tests/suites/certification/Test_TC_CNET_4_9.yaml +++ b/src/app/tests/suites/certification/Test_TC_CNET_4_9.yaml @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,7 +11,6 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -# Auto-generated scripts for harness use only, please review before automation. The endpoints and cluster names are currently set to default name: 12.4.7. [TC-CNET-4.9] [WiFi] Verification for RemoveNetwork Command @@ -22,290 +21,302 @@ PICS: config: nodeId: 0x12344321 - cluster: "Basic Information" + cluster: "Network Commissioning" + #PIXIT.CNET.ENDPOINT_WIFI endpoint: 0 + PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID: + type: octet_string + defaultValue: "hex:7A6967626565686F6D65" tests: - - label: "Preconditions" + #Issue: https://github.com/project-chip/connectedhomeip/issues/30196 + - label: "Precondition: Commission TH and DUT on WiFi network" verification: | - 1. DUT supports CNET.S.F00(WI) - 2. DUT has a Network Commissioning cluster on endpoint PIXIT.CNET.ENDPOINT_WIFI with FeatureMap attribute of 1 - 3. DUT is commissioned on PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID - 4. TH can communicate with the DUT - disabled: true - - - label: "Commission TH and DUT over BLE to setup the Wi-Fi" - verification: | - - disabled: true + ./chip-tool pairing ble-wifi 0x12344321 + + [1698912271.738597][32363:32366] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 + [1698912271.738606][32363:32366] CHIP:CTL: Received CommissioningComplete response, errorCode=0 + [1698912271.738613][32363:32366] CHIP:CTL: Successfully finished commissioning step 'SendComplete' + [1698912271.738617][32363:32366] CHIP:CTL: Commissioning stage next step: 'SendComplete' -> 'Cleanup' + [1698912271.738622][32363:32366] CHIP:CTL: Performing next commissioning step 'Cleanup' + [1698912271.738639][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: MarkForEviction Type:1 LSID:50170 + [1698912271.738642][32363:32366] CHIP:SC: SecureSession[0x7fbb04014a50, LSID:50170]: State change 'kActive' --> 'kPendingEviction' + [1698912271.738666][32363:32366] CHIP:IN: SecureSession[0x7fbb04014a50]: Released - Type:1 LSID:50170 + [1698912271.738672][32363:32366] CHIP:CTL: Successfully finished commissioning step 'Cleanup' + [1698912271.738677][32363:32366] CHIP:TOO: Device commissioning completed with success + [1698912271.738691][32363:32366] CHIP:DMG: ICR moving to [AwaitingDe] + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: enter 'y' after success" + - name: "expectedValue" + value: "y" + + - label: "Precondition: TH reads FeatureMap attribute from the DUT" + command: "readAttribute" + attribute: "FeatureMap" + response: + value: 1 + constraints: + type: bitmap32 - label: "Step 1: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 1 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. - - [1653478311.640549][30368:30373] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1653478311.640646][30368:30373] CHIP:TOO: ArmFailSafeResponse: { - [1653478311.640696][30368:30373] CHIP:TOO: errorCode: 0 - [1653478311.640729][30368:30373] CHIP:TOO: debugText: - [1653478311.640763][30368:30373] CHIP:TOO: } - [1653478311.640821][30368:30373] CHIP:DMG: ICR moving to [AwaitingDe] - [1653478311.640901][30368:30373] CHIP:EM: Sending Standalone Ack for MessageCounter:8633037 on exchange 20698i - disabled: true - - - label: - "Step 2: TH reads Networks attribute from the DUT and saves the number - of entries as 'NumNetworks'" + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" + + - label: "Step 2: TH reads Networks attribute from the DUT " PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that value as PIXIT.CNET.WIFI_1ST_ ACCESSPOINT_SSID. - -that the connected status is in the the type of bool value as TRUE. - - [1654250379.881780][5309:5314] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 3741733376 - [1654250379.881974][5309:5314] CHIP:TOO: Networks: 1 entries - [1654250379.882123][5309:5314] CHIP:TOO: [1]: { - [1654250379.882196][5309:5314] CHIP:TOO: NetworkID: 47524C50726976617465 - [1654250379.882257][5309:5314] CHIP:TOO: Connected: TRUE - [1654250379.882312][5309:5314] CHIP:TOO: } - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 3: TH finds the index of the Networks list entry with NetworkID field value PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and saves it as - 'Userwifi_netidx'" + 'Userth_netidx'" verification: | - ./chip-tool networkcommissioning read last-network-id 1 0 - - Via the TH (chip-tool), Verify: - -that the LastNetworkID attribute that contains NetworkID that should be the type of octstr with a length range 1 to 32. - - [1657198553.376268][5799:5804] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006 DataVersion: 2494552649 - [1657198553.376351][5799:5804] CHIP:TOO: LastNetworkID: 47524C50726976617465 - disabled: true + TH finds the index of the Networks list entry with NetworkID + field value PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and saves it as + 'Userth_netidx' + cluster: "LogCommands" + command: "UserPrompt" + PICS: PICS_USER_PROMPT + arguments: + values: + - name: "message" + value: "Please enter 'y' for success" + - name: "expectedValue" + value: "y" - label: "Step 4: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1653478327.351092][30388:30393] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1653478327.351200][30388:30393] CHIP:TOO: NetworkConfigResponse: { - [1653478327.351252][30388:30393] CHIP:TOO: networkingStatus: 0 - [1653478327.351288][30388:30393] CHIP:TOO: networkIndex: 0 - [1653478327.351320][30388:30393] CHIP:TOO: } - [1653478327.351373][30388:30393] CHIP:DMG: ICR moving to [AwaitingDe] - [1653478327.351449][30388:30393] CHIP:EM: Sending Standalone Ack for MessageCounter:14887098 on exchange 8676i - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 5: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify that the Networks attribute list has empty(0 entries). - - [1653478331.979300][30395:30400] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 1600858167 - [1653478331.979380][30395:30400] CHIP:TOO: Networks: 0 entries - [1653478331.979496][30395:30400] CHIP:EM: Sending Standalone Ack for MessageCounter:609449 on exchange 40264i - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + type: list + excludes: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 6: TH reads LastNetworkingStatus attribute from the DUT" PICS: CNET.S.A0005 - verification: | - ./chip-tool networkcommissioning read last-networking-status 1 0 - - Via the TH (chip-tool), Verify the LastNetworkingStatus attribute that contains value as 0 that mentions success. - - [1653478850.425096][30420:30425] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0005 DataVersion: 1600858167 - [1653478850.425170][30420:30425] CHIP:TOO: LastNetworkingStatus: 0 - [1653478850.425269][30420:30425] CHIP:EM: Sending Standalone Ack for MessageCounter:8275942 on exchange 13394i - disabled: true + command: "readAttribute" + attribute: "LastNetworkingStatus" + response: + value: 0 + constraints: + type: NetworkCommissioningStatusEnum - label: "Step 7: TH reads LastNetworkID attribute from the DUT" PICS: CNET.S.A0006 - verification: | - ./chip-tool networkcommissioning read last-network-id 1 0 - - Via the TH (chip-tool), Verify that the LastNetworkID has PIXIT.CNET.WIFI_ 1ST_ACCESSPOINT _SSID. - - [1657197861.497831][5737:5742] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0006 DataVersion: 2494552649 - [1657197861.497897][5737:5742] CHIP:TOO: LastNetworkID: 47524C50726976617465 - disabled: true + command: "readAttribute" + attribute: "LastNetworkID" + response: + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + constraints: + type: octet_string + minLength: 1 + maxLength: 32 - label: "Step 8: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657197903.686316][5745:5750] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 2805642043 - [1657197903.686428][5745:5750] CHIP:TOO: Breadcrumb: 1 - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 + constraints: + type: int64u - label: "Step 9: TH sends ConnectNetwork command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 2" PICS: CNET.S.C04.Rsp && CNET.S.C06.Rsp - verification: | - ./chip-tool networkcommissioning connect-network hex: 1 0 - - Below is an example: - - ./chip-tool networkcommissioning connect-network hex:47524C50726976617465 1 0 --Breadcrumb 2 - - Via the TH (chip-tool), Verify the ConnectNetworkResponse that contains networkingStatus value as 3(NetworkIdNotFound). - - [1657288261.892249][2347:2352] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0007 - [1657288261.892304][2347:2352] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0007 - [1657288261.892430][2347:2352] CHIP:TOO: ConnectNetworkResponse: { - [1657288261.892477][2347:2352] CHIP:TOO: networkingStatus: 3 - [1657288261.892511][2347:2352] CHIP:TOO: errorValue: 0 - [1657288261.892542][2347:2352] CHIP:TOO: } - disabled: true + timedInteractionTimeoutMs: 5000 + command: "ConnectNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 2 + response: + values: + - name: "NetworkingStatus" + value: 3 + - name: "ErrorValue" + constraints: + type: int32s - label: "Step 10: TH reads Breadcrumb attribute from the General Commissioning cluster of the DUT" - PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning read breadcrumb 1 0 - - Via the TH (chip-tool), verify the Breadcumb attribute that contains value as 1. - - [1657288331.671111][2360:2365] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Attribute 0x0000_0000 DataVersion: 3470734109 - [1657288331.671207][2360:2365] CHIP:TOO: Breadcrumb: 1 - disabled: true + cluster: "General Commissioning" + command: "readAttribute" + attribute: "Breadcrumb" + response: + value: 1 + constraints: + type: int64u - label: "Step 11: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 0" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 0 0 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 0 secs to the TH. - - [1657288382.006035][2369:2374] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657288382.006094][2369:2374] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657288382.006157][2369:2374] CHIP:TOO: ArmFailSafeResponse: { - [1657288382.006201][2369:2374] CHIP:TOO: errorCode: 0 - [1657288382.006233][2369:2374] CHIP:TOO: debugText: - [1657288382.006263][2369:2374] CHIP:TOO: } - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 0 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 12: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify: - -the Networks attribute has NetworkID that contains value as PIXIT.CNET.WIFI_1ST_ ACCESSPOINT_SSID. - -that the connected status should be the type of bool value as TRUE. - - 1684494160.580218][15306:15308] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 130057616 - [1684494160.580248][15306:15308] CHIP:TOO: Networks: 1 entries - [1684494160.580273][15306:15308] CHIP:TOO: [1]: { - [1684494160.580288][15306:15308] CHIP:TOO: NetworkID: 47524C50726976617465 - [1684494160.580298][15306:15308] CHIP:TOO: Connected: TRUE - [1684494160.580307][15306:15308] CHIP:TOO: } - [1684494160.580360][15306:15308] CHIP:EM: <<< [E:26231i S:16056 M:263765151 (Ack:216379970)] (S) Msg TX to 1:0000000000000001 [4DB7] --- Type 0000:10 (SecureChannel:StandaloneAck) - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + contains: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] - label: "Step 13: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 900" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 900 1 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 900 secs to the TH. - - [1657288428.409103][2382:2388] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657288428.409191][2382:2388] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657288428.409303][2382:2388] CHIP:TOO: ArmFailSafeResponse: { - [1657288428.409367][2382:2388] CHIP:TOO: errorCode: 0 - [1657288428.409435][2382:2388] CHIP:TOO: debugText: - [1657288428.409481][2382:2388] CHIP:TOO: } - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 900 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 14: TH sends RemoveNetwork Command to the DUT with NetworkID field set to PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID and Breadcrumb field set to 1" PICS: CNET.S.C04.Rsp && CNET.S.C05.Tx - verification: | - ./chip-tool networkcommissioning remove-network hex: 1 0 - Below is an example: - - ./chip-tool networkcommissioning remove-network hex:47524C50726976617465 1 0 --Breadcrumb 1 - - Via the TH (chip-tool), Verify the NetworkConfigResponse that contains Networking Status value as 0 (success). - - [1687240172.756582][17509:17511] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0031 Command=0x0000_0005 - [1687240172.756684][17509:17511] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Command 0x0000_0005 - [1687240172.756847][17509:17511] CHIP:TOO: NetworkConfigResponse: { - [1687240172.756951][17509:17511] CHIP:TOO: networkingStatus: 0 - [1687240172.757011][17509:17511] CHIP:TOO: networkIndex: 0 - [1687240172.757062][17509:17511] CHIP:TOO: } - disabled: true + command: "RemoveNetwork" + arguments: + values: + - name: "NetworkID" + value: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID + - name: "Breadcrumb" + value: 1 + response: + values: + - name: "NetworkingStatus" + value: 0 - label: "Step 15: TH sends the CommissioningComplete command to the DUT" - PICS: CNET.S.C04.Rsp - verification: | - ./chip-tool generalcommissioning commissioning-complete 1 0 - - Via the TH (chip-tool), Verify the DUT sends CommissioningComplete command and the errorCode field is 0(OK). - - [1657288504.905001][2397:2402] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0005 - [1657288504.905050][2397:2402] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0005 - [1657288504.905108][2397:2402] CHIP:TOO: CommissioningCompleteResponse: { - [1657288504.905145][2397:2402] CHIP:TOO: errorCode: 0 - [1657288504.905169][2397:2402] CHIP:TOO: debugText: - [1657288504.905191][2397:2402] CHIP:TOO: } - disabled: true + cluster: "General Commissioning" + command: "CommissioningComplete" + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 16: TH sends ArmFailSafe command to the DUT with ExpiryLengthSeconds set to 0 to ensure the CommissioningComplete call properly persisted the failsafe context. This call should have no effect if Commissioning Complete call is handled correctly" - verification: | - ./chip-tool generalcommissioning arm-fail-safe 0 0 1 0 - - Via the TH (chip-tool), Verify the DUT sends ArmFailSafe with timeout as 0 secs to the TH. - - [1657288529.987350][2404:2409] CHIP:DMG: Received Command Response Data, Endpoint=0 Cluster=0x0000_0030 Command=0x0000_0001 - [1657288529.987514][2404:2409] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0030 Command 0x0000_0001 - [1657288529.987612][2404:2409] CHIP:TOO: ArmFailSafeResponse: { - [1657288529.987677][2404:2409] CHIP:TOO: errorCode: 0 - [1657288529.987725][2404:2409] CHIP:TOO: debugText: - [1657288529.987772][2404:2409] CHIP:TOO: } - disabled: true + cluster: "General Commissioning" + command: "ArmFailSafe" + arguments: + values: + - name: "ExpiryLengthSeconds" + value: 0 + - name: "Breadcrumb" + value: 0 + response: + values: + - name: "ErrorCode" + value: 0 + - name: "DebugText" + value: "" - label: "Step 17: TH reads Networks attribute from the DUT" PICS: CNET.S.A0001 - verification: | - ./chip-tool networkcommissioning read networks 1 0 - - Via the TH (chip-tool), Verify that the Networks attribute list has empty(0 entries). - - [1657288549.446752][2412:2417] CHIP:TOO: Endpoint: 0 Cluster: 0x0000_0031 Attribute 0x0000_0001 DataVersion: 1420716065 - [1657288549.446852][2412:2417] CHIP:TOO: Networks: 0 entries - disabled: true + command: "readAttribute" + attribute: "Networks" + response: + constraints: + type: list + excludes: + [ + { + NetworkID: PIXIT.CNET.WIFI_1ST_ACCESSPOINT_SSID, + Connected: true, + }, + ] From eb2f8f6ca95c181577415bc4b3e7cc240d5b2edd Mon Sep 17 00:00:00 2001 From: C Freeman Date: Sat, 4 Nov 2023 22:37:14 -0400 Subject: [PATCH 06/11] python conformance test: Add flags for provisional and in-progress (#30189) * Add flags for provisional and in-progress Also remove extra print * Add the CI weirdness as well * Remove extra print --- .../TC_DeviceBasicComposition.py | 25 ++++++++++++++++--- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/src/python_testing/TC_DeviceBasicComposition.py b/src/python_testing/TC_DeviceBasicComposition.py index 21fdcf914a2906..2288c7c5a4b596 100644 --- a/src/python_testing/TC_DeviceBasicComposition.py +++ b/src/python_testing/TC_DeviceBasicComposition.py @@ -1013,13 +1013,26 @@ def conformance_str(conformance: Callable, feature_map: uint, feature_dict: dict return f'Conformance: {str(conformance)}, implemented features: {",".join(codes)}' + ignore_in_progress = self.user_params.get("ignore_in_progress", False) + is_ci = self.check_pics('PICS_SDK_CI_ONLY') + + ignore_attributes: dict[int, list[int]] = {} + if ignore_in_progress: + # This is a manually curated list of attributes that are in-progress in the SDK, but have landed in the spec + in_progress_attributes = {Clusters.BasicInformation.id: [0x15, 0x016]} + ignore_attributes.update(in_progress_attributes) + + if is_ci: + # The network commissioning clusters on the CI select the features on the fly and end up non-conformant + # on these attributes. Production devices should not. + ci_ignore_attributes = {Clusters.NetworkCommissioning.id: [ + Clusters.NetworkCommissioning.Attributes.ScanMaxTimeSeconds.attribute_id, Clusters.NetworkCommissioning.Attributes.ConnectMaxTimeSeconds.attribute_id]} + ignore_attributes.update(ci_ignore_attributes) + success = True - # TODO: provisional needs to be an input parameter - allow_provisional = True + allow_provisional = self.user_params.get("allow_provisional", False) clusters, problems = build_xml_clusters() self.problems = self.problems + problems - for id in sorted(list(clusters.keys())): - print(f'{id} 0x{id:02x}: {clusters[id].name}') for endpoint_id, endpoint in self.endpoints_tlv.items(): for cluster_id, cluster in endpoint.items(): if cluster_id not in clusters.keys(): @@ -1059,6 +1072,8 @@ def conformance_str(conformance: Callable, feature_map: uint, feature_dict: dict # Attribute conformance checking for attribute_id, attribute in cluster.items(): + if cluster_id in ignore_attributes and attribute_id in ignore_attributes[cluster_id]: + continue location = AttributePathLocation(endpoint_id=endpoint_id, cluster_id=cluster_id, attribute_id=attribute_id) if attribute_id not in clusters[cluster_id].attributes.keys(): # TODO: Consolidate the range checks with IDM-10.1 once that lands @@ -1076,6 +1091,8 @@ def conformance_str(conformance: Callable, feature_map: uint, feature_dict: dict problem=f'Attribute 0x{attribute_id:02x} is included, but is disallowed by conformance. {conformance_str(xml_attribute.conformance, feature_map, clusters[cluster_id].features)}') success = False for attribute_id, xml_attribute in clusters[cluster_id].attributes.items(): + if cluster_id in ignore_attributes and attribute_id in ignore_attributes[cluster_id]: + continue conformance_decision = xml_attribute.conformance(feature_map, attribute_list, all_command_list) if conformance_decision == ConformanceDecision.MANDATORY and attribute_id not in cluster.keys(): location = AttributePathLocation(endpoint_id=endpoint_id, cluster_id=cluster_id, attribute_id=attribute_id) From 0baa1c67ffe0300d564b46c0c90ab01aac4dd8d1 Mon Sep 17 00:00:00 2001 From: Boris Zbarsky Date: Mon, 6 Nov 2023 09:42:38 -0500 Subject: [PATCH 07/11] Fix constraint type checks for command responses. (#30218) For a command response, the YAML parser was ending up with the wrong type definition (the one for the whole command response, not the one for the one field) when a type-dependent constraint was used on a field of the response. This led to issues when a type-dependent constraint (like "contains") was used with a list of structs: the field names for the structs were not found, since the object used for lookup had field names for the command itself, not for the field in question. Fixes https://github.com/project-chip/connectedhomeip/issues/30204 --- scripts/py_matter_yamltests/matter_yamltests/parser.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/py_matter_yamltests/matter_yamltests/parser.py b/scripts/py_matter_yamltests/matter_yamltests/parser.py index 6e9ab2a2e7224a..16f98bcf96d800 100644 --- a/scripts/py_matter_yamltests/matter_yamltests/parser.py +++ b/scripts/py_matter_yamltests/matter_yamltests/parser.py @@ -491,7 +491,7 @@ def _update_with_definition(self, container: dict, mapping_type): # the the value type for the target field. if is_typed_constraint(constraint): value[key][constraint] = self._update_value_with_definition( - constraint_value, mapping_type) + constraint_value, mapping) else: # This key, value pair does not rely on cluster specifications. pass From ce5e7fbeaa30dd48ace440237c0fbbfd547a07d9 Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Mon, 6 Nov 2023 10:00:27 -0500 Subject: [PATCH 08/11] Match `Media Playback Cluster` to spec (#30217) * move MediaPlaybackStatusEnum to StatusEnum * Add compat shim * Zap regen * Replace enum name to the new name * Fix Darwin availability annotations. --------- Co-authored-by: Andrei Litvin Co-authored-by: Boris Zbarsky --- .../all-clusters-minimal-app.matter | 18 +++++----- ...ootnode_basicvideoplayer_0ff86e943b.matter | 18 +++++----- .../placeholder/linux/apps/app1/config.matter | 36 +++++++++---------- .../placeholder/linux/apps/app2/config.matter | 36 +++++++++---------- .../AppMediaPlaybackManager.cpp | 2 +- .../java/ContentAppCommandDelegate.cpp | 2 +- .../android/java/MediaPlaybackManager.cpp | 6 ++-- .../media-playback/MediaPlaybackManager.cpp | 28 +++++++-------- examples/tv-app/tv-common/tv-app.matter | 18 +++++----- .../tv-casting-common/tv-casting-app.matter | 18 +++++----- src/app/CompatEnumNames.h | 4 +++ .../chip/media-playback-cluster.xml | 4 +-- .../data_model/controller-clusters.matter | 18 +++++----- .../python/chip/clusters/Objects.py | 28 +++++++-------- .../CHIP/templates/availability.yaml | 10 ++++-- .../CHIP/zap-generated/MTRBaseClusters.h | 14 ++++---- .../zap-generated/cluster-enums-check.h | 32 ++++++++--------- .../app-common/zap-generated/cluster-enums.h | 32 ++++++++--------- .../zap-generated/cluster-objects.h | 4 +-- 19 files changed, 169 insertions(+), 159 deletions(-) diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter index ec8ef140c3db94..3ce4f8352bffc2 100644 --- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter +++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter @@ -3227,7 +3227,14 @@ server cluster TargetNavigator = 1285 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ server cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -3236,13 +3243,6 @@ server cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -3262,7 +3262,7 @@ server cluster MediaPlayback = 1286 { readonly attribute int16u clusterRevision = 65533; response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } diff --git a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter index 2d61f49ec83443..99285653fb5c39 100644 --- a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter +++ b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter @@ -1198,7 +1198,14 @@ server cluster TargetNavigator = 1285 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ server cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -1207,13 +1214,6 @@ server cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -1233,7 +1233,7 @@ server cluster MediaPlayback = 1286 { readonly attribute int16u clusterRevision = 65533; response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } diff --git a/examples/placeholder/linux/apps/app1/config.matter b/examples/placeholder/linux/apps/app1/config.matter index 6a9706415d79c4..e9d63cf6bccc28 100644 --- a/examples/placeholder/linux/apps/app1/config.matter +++ b/examples/placeholder/linux/apps/app1/config.matter @@ -5501,7 +5501,14 @@ server cluster TargetNavigator = 1285 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ client cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -5510,13 +5517,6 @@ client cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -5550,7 +5550,7 @@ client cluster MediaPlayback = 1286 { } response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } @@ -5584,7 +5584,14 @@ client cluster MediaPlayback = 1286 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ server cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -5593,13 +5600,6 @@ server cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -5637,7 +5637,7 @@ server cluster MediaPlayback = 1286 { } response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } diff --git a/examples/placeholder/linux/apps/app2/config.matter b/examples/placeholder/linux/apps/app2/config.matter index c5397194a84ee9..b6ea2125074b4f 100644 --- a/examples/placeholder/linux/apps/app2/config.matter +++ b/examples/placeholder/linux/apps/app2/config.matter @@ -5460,7 +5460,14 @@ server cluster TargetNavigator = 1285 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ client cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -5469,13 +5476,6 @@ client cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -5509,7 +5509,7 @@ client cluster MediaPlayback = 1286 { } response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } @@ -5543,7 +5543,14 @@ client cluster MediaPlayback = 1286 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ server cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -5552,13 +5559,6 @@ server cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -5596,7 +5596,7 @@ server cluster MediaPlayback = 1286 { } response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } diff --git a/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp b/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp index 564779a62affd8..0fe5e9d63d4f6f 100644 --- a/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp +++ b/examples/tv-app/android/include/media-playback/AppMediaPlaybackManager.cpp @@ -165,7 +165,7 @@ Commands::PlaybackResponse::Type AppMediaPlaybackManager::HandleMediaRequest(Med // Ideally should not come here ChipLogProgress(Zcl, "AppMediaPlaybackManager::HandleMediaRequest"); Commands::PlaybackResponse::Type response; - response.status = MediaPlaybackStatusEnum::kInvalidStateForCommand; + response.status = StatusEnum::kInvalidStateForCommand; return response; } diff --git a/examples/tv-app/android/java/ContentAppCommandDelegate.cpp b/examples/tv-app/android/java/ContentAppCommandDelegate.cpp index 1ad6ef2fa40311..0d232d716bae0a 100644 --- a/examples/tv-app/android/java/ContentAppCommandDelegate.cpp +++ b/examples/tv-app/android/java/ContentAppCommandDelegate.cpp @@ -302,7 +302,7 @@ PlaybackResponseType ContentAppCommandDelegate::FormatMediaPlaybackResponse(Json } else { - playbackResponse.status = static_cast(value[statusFieldId].asInt()); + playbackResponse.status = static_cast(value[statusFieldId].asInt()); std::string dataFieldId = std::to_string(to_underlying(app::Clusters::MediaPlayback::Commands::PlaybackResponse::Fields::kData)); if (!value[dataFieldId].empty()) diff --git a/examples/tv-app/android/java/MediaPlaybackManager.cpp b/examples/tv-app/android/java/MediaPlaybackManager.cpp index c1e92fe51b9aa3..53a7066551cd22 100644 --- a/examples/tv-app/android/java/MediaPlaybackManager.cpp +++ b/examples/tv-app/android/java/MediaPlaybackManager.cpp @@ -277,14 +277,14 @@ Commands::PlaybackResponse::Type MediaPlaybackManager::HandleMediaRequest(MediaP ChipLogError(AppServer, "Java exception in MediaPlaybackManager::Request %d", mediaPlaybackRequest); env->ExceptionDescribe(); env->ExceptionClear(); - response.status = MediaPlaybackStatusEnum::kInvalidStateForCommand; + response.status = StatusEnum::kInvalidStateForCommand; } - response.status = static_cast(ret); + response.status = static_cast(ret); exit: if (err != CHIP_NO_ERROR) { - response.status = MediaPlaybackStatusEnum::kInvalidStateForCommand; + response.status = StatusEnum::kInvalidStateForCommand; ChipLogError(Zcl, "MediaPlaybackManager::HandleMediaRequest status error: %s", err.AsString()); } diff --git a/examples/tv-app/tv-common/clusters/media-playback/MediaPlaybackManager.cpp b/examples/tv-app/tv-common/clusters/media-playback/MediaPlaybackManager.cpp index 4fffd610ddde6f..6d018d6522ede8 100644 --- a/examples/tv-app/tv-common/clusters/media-playback/MediaPlaybackManager.cpp +++ b/examples/tv-app/tv-common/clusters/media-playback/MediaPlaybackManager.cpp @@ -68,7 +68,7 @@ void MediaPlaybackManager::HandlePlay(CommandResponseHelper This command SHALL be generated in response to various Playback Request commands. - + @@ -104,7 +104,7 @@ limitations under the License. - + diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index a114961e81e089..86144d0ee763dc 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -5974,7 +5974,14 @@ client cluster TargetNavigator = 1285 { /** This cluster provides an interface for controlling Media Playback (PLAY, PAUSE, etc) on a media device such as a TV or Speaker. */ client cluster MediaPlayback = 1286 { - enum MediaPlaybackStatusEnum : enum8 { + enum PlaybackStateEnum : enum8 { + kPlaying = 0; + kPaused = 1; + kNotPlaying = 2; + kBuffering = 3; + } + + enum StatusEnum : enum8 { kSuccess = 0; kInvalidStateForCommand = 1; kNotAllowed = 2; @@ -5983,13 +5990,6 @@ client cluster MediaPlayback = 1286 { kSeekOutOfRange = 5; } - enum PlaybackStateEnum : enum8 { - kPlaying = 0; - kPaused = 1; - kNotPlaying = 2; - kBuffering = 3; - } - bitmap Feature : bitmap32 { kAdvancedSeek = 0x1; kVariableSpeed = 0x2; @@ -6023,7 +6023,7 @@ client cluster MediaPlayback = 1286 { } response struct PlaybackResponse = 10 { - MediaPlaybackStatusEnum status = 0; + StatusEnum status = 0; optional char_string data = 1; } diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py index e26648d9ccd20d..eb73af290d3ac2 100644 --- a/src/controller/python/chip/clusters/Objects.py +++ b/src/controller/python/chip/clusters/Objects.py @@ -33612,7 +33612,18 @@ def descriptor(cls) -> ClusterObjectDescriptor: clusterRevision: 'uint' = None class Enums: - class MediaPlaybackStatusEnum(MatterIntEnum): + class PlaybackStateEnum(MatterIntEnum): + kPlaying = 0x00 + kPaused = 0x01 + kNotPlaying = 0x02 + kBuffering = 0x03 + # All received enum values that are not listed above will be mapped + # to kUnknownEnumValue. This is a helper enum value that should only + # be used by code to process how it handles receiving and unknown + # enum value. This specific should never be transmitted. + kUnknownEnumValue = 4, + + class StatusEnum(MatterIntEnum): kSuccess = 0x00 kInvalidStateForCommand = 0x01 kNotAllowed = 0x02 @@ -33625,17 +33636,6 @@ class MediaPlaybackStatusEnum(MatterIntEnum): # enum value. This specific should never be transmitted. kUnknownEnumValue = 6, - class PlaybackStateEnum(MatterIntEnum): - kPlaying = 0x00 - kPaused = 0x01 - kNotPlaying = 0x02 - kBuffering = 0x03 - # All received enum values that are not listed above will be mapped - # to kUnknownEnumValue. This is a helper enum value that should only - # be used by code to process how it handles receiving and unknown - # enum value. This specific should never be transmitted. - kUnknownEnumValue = 4, - class Bitmaps: class Feature(IntFlag): kAdvancedSeek = 0x1 @@ -33803,11 +33803,11 @@ class PlaybackResponse(ClusterCommand): def descriptor(cls) -> ClusterObjectDescriptor: return ClusterObjectDescriptor( Fields=[ - ClusterObjectFieldDescriptor(Label="status", Tag=0, Type=MediaPlayback.Enums.MediaPlaybackStatusEnum), + ClusterObjectFieldDescriptor(Label="status", Tag=0, Type=MediaPlayback.Enums.StatusEnum), ClusterObjectFieldDescriptor(Label="data", Tag=1, Type=typing.Optional[str]), ]) - status: 'MediaPlayback.Enums.MediaPlaybackStatusEnum' = 0 + status: 'MediaPlayback.Enums.StatusEnum' = 0 data: 'typing.Optional[str]' = None @dataclass diff --git a/src/darwin/Framework/CHIP/templates/availability.yaml b/src/darwin/Framework/CHIP/templates/availability.yaml index e79ccb23af13ed..60cd3ac3dae78f 100644 --- a/src/darwin/Framework/CHIP/templates/availability.yaml +++ b/src/darwin/Framework/CHIP/templates/availability.yaml @@ -3247,7 +3247,10 @@ TargetNavigator: - TargetNavigatorStatusEnum MediaPlayback: - - MediaPlaybackStatusEnum + # StatusEnum was originally named MediaPlaybackStatusEnum, but we + # generate the same API for the names with/without the cluster + # name at the beginning, so the name can just change here. + - StatusEnum - PlaybackStateEnum MediaInput: - InputTypeEnum @@ -3997,7 +4000,10 @@ - TargetNotFound - NotAllowed MediaPlayback: - MediaPlaybackStatusEnum: + # StatusEnum was originally named MediaPlaybackStatusEnum, but we + # generate the same API for the names with/without the cluster + # name at the beginning, so the name can just change here. + StatusEnum: - Success - InvalidStateForCommand - NotAllowed diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h index bbe527dde793ff..22dcdd51f5c80c 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h @@ -16359,6 +16359,13 @@ typedef NS_ENUM(uint8_t, MTRTargetNavigatorStatus) { MTRTargetNavigatorStatusNotAllowed MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x02, } MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); +typedef NS_ENUM(uint8_t, MTRMediaPlaybackPlaybackState) { + MTRMediaPlaybackPlaybackStatePlaying MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x00, + MTRMediaPlaybackPlaybackStatePaused MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x01, + MTRMediaPlaybackPlaybackStateNotPlaying MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x02, + MTRMediaPlaybackPlaybackStateBuffering MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x03, +} MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); + typedef NS_ENUM(uint8_t, MTRMediaPlaybackStatus) { MTRMediaPlaybackStatusSuccess MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x00, MTRMediaPlaybackStatusInvalidStateForCommand MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x01, @@ -16368,13 +16375,6 @@ typedef NS_ENUM(uint8_t, MTRMediaPlaybackStatus) { MTRMediaPlaybackStatusSeekOutOfRange MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x05, } MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); -typedef NS_ENUM(uint8_t, MTRMediaPlaybackPlaybackState) { - MTRMediaPlaybackPlaybackStatePlaying MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x00, - MTRMediaPlaybackPlaybackStatePaused MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x01, - MTRMediaPlaybackPlaybackStateNotPlaying MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x02, - MTRMediaPlaybackPlaybackStateBuffering MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x03, -} MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); - typedef NS_OPTIONS(uint32_t, MTRMediaPlaybackFeature) { MTRMediaPlaybackFeatureAdvancedSeek MTR_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) = 0x1, MTRMediaPlaybackFeatureVariableSpeed MTR_AVAILABLE(ios(16.2), macos(13.1), watchos(9.2), tvos(16.2)) = 0x2, diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-enums-check.h b/zzz_generated/app-common/app-common/zap-generated/cluster-enums-check.h index d6e4be54fbac0e..efe20ce7a401a7 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-enums-check.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-enums-check.h @@ -2649,22 +2649,6 @@ static auto __attribute__((unused)) EnsureKnownEnumValue(TargetNavigator::Target } } -static auto __attribute__((unused)) EnsureKnownEnumValue(MediaPlayback::MediaPlaybackStatusEnum val) -{ - using EnumType = MediaPlayback::MediaPlaybackStatusEnum; - switch (val) - { - case EnumType::kSuccess: - case EnumType::kInvalidStateForCommand: - case EnumType::kNotAllowed: - case EnumType::kNotActive: - case EnumType::kSpeedOutOfRange: - case EnumType::kSeekOutOfRange: - return val; - default: - return static_cast(6); - } -} static auto __attribute__((unused)) EnsureKnownEnumValue(MediaPlayback::PlaybackStateEnum val) { using EnumType = MediaPlayback::PlaybackStateEnum; @@ -2679,6 +2663,22 @@ static auto __attribute__((unused)) EnsureKnownEnumValue(MediaPlayback::Playback return static_cast(4); } } +static auto __attribute__((unused)) EnsureKnownEnumValue(MediaPlayback::StatusEnum val) +{ + using EnumType = MediaPlayback::StatusEnum; + switch (val) + { + case EnumType::kSuccess: + case EnumType::kInvalidStateForCommand: + case EnumType::kNotAllowed: + case EnumType::kNotActive: + case EnumType::kSpeedOutOfRange: + case EnumType::kSeekOutOfRange: + return val; + default: + return static_cast(6); + } +} static auto __attribute__((unused)) EnsureKnownEnumValue(MediaInput::InputTypeEnum val) { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h index e590fed2c81741..559a735f499971 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h @@ -3801,22 +3801,6 @@ enum class TargetNavigatorStatusEnum : uint8_t namespace MediaPlayback { -// Enum for MediaPlaybackStatusEnum -enum class MediaPlaybackStatusEnum : uint8_t -{ - kSuccess = 0x00, - kInvalidStateForCommand = 0x01, - kNotAllowed = 0x02, - kNotActive = 0x03, - kSpeedOutOfRange = 0x04, - kSeekOutOfRange = 0x05, - // All received enum values that are not listed above will be mapped - // to kUnknownEnumValue. This is a helper enum value that should only - // be used by code to process how it handles receiving and unknown - // enum value. This specific should never be transmitted. - kUnknownEnumValue = 6, -}; - // Enum for PlaybackStateEnum enum class PlaybackStateEnum : uint8_t { @@ -3831,6 +3815,22 @@ enum class PlaybackStateEnum : uint8_t kUnknownEnumValue = 4, }; +// Enum for StatusEnum +enum class StatusEnum : uint8_t +{ + kSuccess = 0x00, + kInvalidStateForCommand = 0x01, + kNotAllowed = 0x02, + kNotActive = 0x03, + kSpeedOutOfRange = 0x04, + kSeekOutOfRange = 0x05, + // All received enum values that are not listed above will be mapped + // to kUnknownEnumValue. This is a helper enum value that should only + // be used by code to process how it handles receiving and unknown + // enum value. This specific should never be transmitted. + kUnknownEnumValue = 6, +}; + // Bitmap for Feature enum class Feature : uint32_t { 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 6ebe298d283b59..f88e598f1bccb0 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 @@ -29087,7 +29087,7 @@ struct Type static constexpr CommandId GetCommandId() { return Commands::PlaybackResponse::Id; } static constexpr ClusterId GetClusterId() { return Clusters::MediaPlayback::Id; } - MediaPlaybackStatusEnum status = static_cast(0); + StatusEnum status = static_cast(0); Optional data; CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const; @@ -29103,7 +29103,7 @@ struct DecodableType static constexpr CommandId GetCommandId() { return Commands::PlaybackResponse::Id; } static constexpr ClusterId GetClusterId() { return Clusters::MediaPlayback::Id; } - MediaPlaybackStatusEnum status = static_cast(0); + StatusEnum status = static_cast(0); Optional data; CHIP_ERROR Decode(TLV::TLVReader & reader); }; From 606cf218ffca36a3f57d2d2b64993ee3fa519759 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Nov 2023 10:42:04 -0500 Subject: [PATCH 09/11] Bump third_party/libwebsockets/repo from `816544f` to `26c3f9a` (#30228) Bumps [third_party/libwebsockets/repo](https://github.com/warmcat/libwebsockets) from `816544f` to `26c3f9a`. - [Commits](https://github.com/warmcat/libwebsockets/compare/816544f1d6d05cfa5d9fa5875f38e218c56285b3...26c3f9a01bb41d75126dc6817459b7c4a3491431) --- updated-dependencies: - dependency-name: third_party/libwebsockets/repo dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- third_party/libwebsockets/repo | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/third_party/libwebsockets/repo b/third_party/libwebsockets/repo index 816544f1d6d05c..26c3f9a01bb41d 160000 --- a/third_party/libwebsockets/repo +++ b/third_party/libwebsockets/repo @@ -1 +1 @@ -Subproject commit 816544f1d6d05cfa5d9fa5875f38e218c56285b3 +Subproject commit 26c3f9a01bb41d75126dc6817459b7c4a3491431 From d5d767e3ffe3c5aa15f091dd7804cc421ef95337 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Nov 2023 10:42:16 -0500 Subject: [PATCH 10/11] Bump third_party/bouffalolab/repo from `a57482f` to `07ac148` (#30230) Bumps [third_party/bouffalolab/repo](https://github.com/bouffalolab/bl_iot_sdk_tiny) from `a57482f` to `07ac148`. - [Commits](https://github.com/bouffalolab/bl_iot_sdk_tiny/compare/a57482f469fe2bbe4ab96b5b6034550ab61a302e...07ac148f70e1e3773f0ba0fa5ccad00bdf40e4d9) --- updated-dependencies: - dependency-name: third_party/bouffalolab/repo dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- third_party/bouffalolab/repo | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/third_party/bouffalolab/repo b/third_party/bouffalolab/repo index a57482f469fe2b..07ac148f70e1e3 160000 --- a/third_party/bouffalolab/repo +++ b/third_party/bouffalolab/repo @@ -1 +1 @@ -Subproject commit a57482f469fe2bbe4ab96b5b6034550ab61a302e +Subproject commit 07ac148f70e1e3773f0ba0fa5ccad00bdf40e4d9 From 0f5f7084727be885c15e08391316f5eeb250157a Mon Sep 17 00:00:00 2001 From: C Freeman Date: Mon, 6 Nov 2023 10:43:42 -0500 Subject: [PATCH 11/11] Python: Add more API documentation (#30220) --- src/controller/python/chip/ChipDeviceCtrl.py | 91 +++++++++++++++++++- 1 file changed, 90 insertions(+), 1 deletion(-) diff --git a/src/controller/python/chip/ChipDeviceCtrl.py b/src/controller/python/chip/ChipDeviceCtrl.py index 22ae11cda65a78..f30cc711b9a7cb 100644 --- a/src/controller/python/chip/ChipDeviceCtrl.py +++ b/src/controller/python/chip/ChipDeviceCtrl.py @@ -684,6 +684,19 @@ def DiscoverAllCommissioning(self): def OpenCommissioningWindow(self, nodeid: int, timeout: int, iteration: int, discriminator: int, option: int) -> CommissioningParameters: + ''' Opens a commissioning window on the device with the given nodeid. + nodeid: Node id of the device + timeout: Command timeout + iteration: The PAKE iteration count associated with the PAKE Passcode ID and ephemeral + PAKE passcode verifier to be used for this commissioning. Valid range: 1000 - 100000 + Ignored if option == 0 + discriminator: The long discriminator for the DNS-SD advertisement. Valid range: 0-4095 + Ignored if option == 0 + option: 0 = kOriginalSetupCode + 1 = kTokenWithRandomPIN + + Returns CommissioningParameters + ''' self.CheckIsActive() self._ChipStack.CallAsync( lambda: self._dmLib.pychip_DeviceController_OpenCommissioningWindow( @@ -825,6 +838,11 @@ async def SendCommand(self, nodeid: int, endpoint: int, payload: ClusterObjects. timedWriteTimeoutMs: Timeout for a timed invoke request. Omit or set to 'None' to indicate a non-timed request. interactionTimeoutMs: Overall timeout for the interaction. Omit or set to 'None' to have the SDK automatically compute the right timeout value based on transport characteristics as well as the responsiveness of the target. + + Returns: + - command respone. The type of the response is defined by the command. + Raises: + - InteractionModelError on error ''' self.CheckIsActive() @@ -845,6 +863,10 @@ def SendGroupCommand(self, groupid: int, payload: ClusterObjects.ClusterCommand, ''' Send a group cluster-object encapsulated command to a group_id and get returned a future that can be awaited upon to get confirmation command was sent. + Returns: + - None: responses are not sent to group commands + Raises: + - InteractionModelError on error ''' self.CheckIsActive() @@ -870,6 +892,9 @@ async def WriteAttribute(self, nodeid: int, E.g (1, Clusters.UnitTesting.Attributes.XYZAttribute('hello')) -- Write 'hello' to the XYZ attribute on the test cluster to endpoint 1 + + Returns: + - PyChipError ''' self.CheckIsActive() @@ -1091,6 +1116,13 @@ async def Read(self, nodeid: int, attributes: typing.List[typing.Union[ reportInterval: A tuple of two int-s for (MinIntervalFloor, MaxIntervalCeiling). Used by establishing subscriptions. When not provided, a read request will be sent. + + Returns: + - AsyncReadTransaction.ReadResponse. Please see ReadAttribute and ReadEvent for examples of how to access data. + + Raises: + - InteractionModelError (chip.interaction_model) on error + ''' self.CheckIsActive() @@ -1153,6 +1185,26 @@ async def ReadAttribute(self, nodeid: int, attributes: typing.List[typing.Union[ reportInterval: A tuple of two int-s for (MinIntervalFloor, MaxIntervalCeiling). Used by establishing subscriptions. When not provided, a read request will be sent. + + Returns: + - subscription request: ClusterAttribute.SubscriptionTransaction + To get notified on attribute change use SetAttributeUpdateCallback on the returned + SubscriptionTransaction. This is used to set a callback function, which is a callable of + type Callable[[TypedAttributePath, SubscriptionTransaction], None] + Get the attribute value from the change path using GetAttribute on the SubscriptionTransasction + You can await changes in the main loop using a trigger mechanism from the callback. + ex. queue.SimpleQueue + + - read request: AsyncReadTransation.ReadResponse.attributes. + This is of type AttributeCache.attributeCache (Attribute.py), + which is a dict mapping endpoints to a list of Cluster (ClusterObjects.py) classes + (dict[int], List[Cluster]) + Access as ret[endpoint_id][][] + Ex. To access the OnTime attribute from the OnOff cluster on EP 0 + ret[0][Clusters.OnOff][Clusters.OnOff.Attributes.OnTime] + + Raises: + - InteractionModelError (chip.interaction_model) on error ''' res = await self.Read(nodeid, attributes=attributes, @@ -1209,6 +1261,19 @@ async def ReadEvent(self, nodeid: int, events: typing.List[typing.Union[ eventNumberFilter: Optional minimum event number filter. reportInterval: A tuple of two int-s for (MinIntervalFloor, MaxIntervalCeiling). Used by establishing subscriptions. When not provided, a read request will be sent. + + Returns: + - subscription request: ClusterAttribute.SubscriptionTransaction + To get notified on event subscriptions, use the SetEventUpdateCallback function on the + returned SubscriptionTransaction. This is a callable of type + Callable[[EventReadResult, SubscriptionTransaction], None] + You can await events using a trigger mechanism in the callback. ex. queue.SimpleQueue + + - read request: AsyncReadTransation.ReadResponse.events. + This is a List[ClusterEvent]. + + Raises: + - InteractionModelError (chip.interaction_model) on error ''' res = await self.Read(nodeid=nodeid, events=events, eventNumberFilter=eventNumberFilter, fabricFiltered=fabricFiltered, reportInterval=reportInterval, keepSubscriptions=keepSubscriptions, @@ -1219,6 +1284,9 @@ async def ReadEvent(self, nodeid: int, events: typing.List[typing.Union[ return res.events def ZCLSend(self, cluster, command, nodeid, endpoint, groupid, args, blocking=False): + ''' Wrapper over SendCommand that catches the exceptions + Returns a tuple of (errorCode, CommandResponse) + ''' self.CheckIsActive() req = None @@ -1235,6 +1303,9 @@ def ZCLSend(self, cluster, command, nodeid, endpoint, groupid, args, blocking=Fa return (int(ex.status), None) def ZCLReadAttribute(self, cluster, attribute, nodeid, endpoint, groupid, blocking=True): + ''' Wrapper over ReadAttribute for a single attribute + Returns an AttributeReadResult + ''' self.CheckIsActive() clusterType = getattr(GeneratedObjects, cluster) @@ -1253,6 +1324,9 @@ def ZCLReadAttribute(self, cluster, attribute, nodeid, endpoint, groupid, blocki status=0, value=result[endpoint][clusterType][attributeType], dataVersion=result[endpoint][clusterType][ClusterAttribute.DataVersion]) def ZCLWriteAttribute(self, cluster: str, attribute: str, nodeid, endpoint, groupid, value, dataVersion=0, blocking=True): + ''' Wrapper over WriteAttribute for a single attribute + return PyChipError + ''' req = None try: req = eval( @@ -1263,6 +1337,9 @@ def ZCLWriteAttribute(self, cluster: str, attribute: str, nodeid, endpoint, grou return asyncio.run(self.WriteAttribute(nodeid, [(endpoint, req, dataVersion)])) def ZCLSubscribeAttribute(self, cluster, attribute, nodeid, endpoint, minInterval, maxInterval, blocking=True): + ''' Wrapper over ReadAttribute for a single attribute + Returns a SubscriptionTransaction. See ReadAttribute for more information. + ''' self.CheckIsActive() req = None @@ -1627,12 +1704,13 @@ def CommissionThread(self, discriminator, setupPinCode, nodeId, threadOperationa return self.ConnectBLE(discriminator, setupPinCode, nodeId) def CommissionWiFi(self, discriminator, setupPinCode, nodeId, ssid: str, credentials: str) -> PyChipError: - ''' Commissions a WiFi device over BLE + ''' Commissions a Wi-Fi device over BLE. ''' self.SetWiFiCredentials(ssid, credentials) return self.ConnectBLE(discriminator, setupPinCode, nodeId) def SetWiFiCredentials(self, ssid: str, credentials: str): + ''' Set the Wi-Fi credentials to set during commissioning.''' self.CheckIsActive() self._ChipStack.Call( @@ -1641,6 +1719,7 @@ def SetWiFiCredentials(self, ssid: str, credentials: str): ).raise_on_error() def SetThreadOperationalDataset(self, threadOperationalDataset): + ''' Set the Thread operational dataset to set during commissioning.''' self.CheckIsActive() self._ChipStack.Call( @@ -1649,42 +1728,49 @@ def SetThreadOperationalDataset(self, threadOperationalDataset): ).raise_on_error() def ResetCommissioningParameters(self): + ''' Sets the commissioning parameters back to the default values.''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_ResetCommissioningParameters() ).raise_on_error() def SetTimeZone(self, offset: int, validAt: int): + ''' Set the time zone to set during commissioning. Currently only one time zone entry is supported''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_SetTimeZone(offset, validAt) ).raise_on_error() def SetDSTOffset(self, offset: int, validStarting: int, validUntil: int): + ''' Set the DST offset to set during commissioning. Currently only one DST entry is supported''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_SetDSTOffset(offset, validStarting, validUntil) ).raise_on_error() def SetDefaultNTP(self, defaultNTP: str): + ''' Set the DefaultNTP to set during commissioning''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_SetDefaultNtp(defaultNTP.encode("utf-8")) ).raise_on_error() def SetTrustedTimeSource(self, nodeId: int, endpoint: int): + ''' Set the trusetd time source nodeId to set during commissioning. This must be a node on the commissioner fabric.''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_SetTrustedTimeSource(nodeId, endpoint) ).raise_on_error() def SetCheckMatchingFabric(self, check: bool): + ''' Instructs the auto-commissioner to perform a matching fabric check before commissioning.''' self.CheckIsActive() self._ChipStack.Call( lambda: self._dmLib.pychip_DeviceController_SetCheckMatchingFabric(check) ).raise_on_error() def GetFabricCheckResult(self) -> int: + ''' Returns the fabric check result if SetCheckMatchingFabric was used.''' return self.fabricCheckNodeId def CommissionOnNetwork(self, nodeId: int, setupPinCode: int, @@ -1727,6 +1813,9 @@ def CommissionOnNetwork(self, nodeId: int, setupPinCode: int, return self._ChipStack.commissioningEventRes def CommissionWithCode(self, setupPayload: str, nodeid: int) -> PyChipError: + ''' Commission with the given nodeid from the setupPayload. + setupPayload may be a QR or manual code. + ''' self.CheckIsActive() setupPayload = setupPayload.encode() + b'\0'