diff --git a/.github/.wordlist.txt b/.github/.wordlist.txt
index 44470a612f42c7..a6d2183cfd5ea1 100644
--- a/.github/.wordlist.txt
+++ b/.github/.wordlist.txt
@@ -17,6 +17,7 @@ ables
AccessControl
AccessControlEntry
accessor
+Accessors
AccountLogin
acdbc
ack
@@ -31,7 +32,9 @@ AddNOC
AddOrUpdateThreadNetwork
AddOrUpdateWiFiNetwork
addr
+AddResponse
AddThreadNetwork
+AddStatus
adk
AdministratorCommissioning
adoc
@@ -97,6 +100,7 @@ att
attId
attr
attrib
+AttributeAccessInterface
attributeValue
attrListName
attrMask
@@ -256,6 +260,7 @@ clusterAttrs
clusterId
clusterList
clusterListName
+ClusterName
ClusterObjectTests
ClusterRevision
ClusterTestGeneration
@@ -276,6 +281,8 @@ codelabs
ColorControl
Comcast
Commandline
+CommandHandlerInterface
+CommandName
Commissionable
CommissionableDataProvider
commissionables
@@ -289,6 +296,7 @@ configs
configTOTAL
ConfigurationManager
ConfigurationManagerImpl
+conformant
connectedhomeip
ConnectionData
ConnectIP
@@ -490,8 +498,11 @@ eg
EjQ
elftools
elock
+emberAf
emberAfExternalAttributeReadCallback
emberAfExternalAttributeWriteCallback
+EmberAfInitializeAttributes
+emberAfSetDynamicEndpoint
EnableNetwork
EnableWiFiNetwork
endian
@@ -519,8 +530,11 @@ EthyleneOxideConcentrationMeasurement
EvalCode
EvalCodeWithName
EvalFrameDefault
+EV
EVB
+EventLogging
evk
+EVSE
exceptfds
ExchangeContext
exe
@@ -592,6 +606,7 @@ GetDeviceInfo
GetDns
GetIP
getManualTests
+GetSafeAttributePersistenceProvider
getstarted
getTests
GH
@@ -627,6 +642,7 @@ Gv
gz
gzbf
HaloaceticAcidsConcentrationMeasurement
+HandleCommand
hardcoded
hardknott
hardwarever
@@ -698,6 +714,7 @@ installDebug
instantiation
integrations
IntelliSense
+InteractionModelEngine
InteractionModelVersion
Interoperable
introvideos
@@ -802,6 +819,7 @@ localhost
LocalizationConfiguration
localstatedir
LockingState
+LogEvent
loopback
LowPower
LPC
@@ -830,6 +848,7 @@ matterc
MatterCustomTrace
matterd
MatterLock
+MatterReportingAttributeChangeCallback
matterSdkSourceBuild
matterSourceBuildAbiFilters
matterUTestLib
@@ -1063,6 +1082,7 @@ plaintext
PlatformManager
PlatformManagerImpl
plt
+PluginServerCallback
png
Podman
PollControl
@@ -1150,6 +1170,8 @@ recommand
recommanded
recurse
regen
+registerAttributeAccessOverride
+RegisterCommandHandler
RelativeHumidityMeasurement
RemainAfterExit
remoteDeviceId
@@ -1159,6 +1181,7 @@ RendezvousParameters
RendezVousTest
REPL
repo
+repos
req
Requestor
Requestor's
diff --git a/.github/workflows/examples-qpg.yaml b/.github/workflows/examples-qpg.yaml
index e95e26816dbcc0..b5aadaf11c11bb 100644
--- a/.github/workflows/examples-qpg.yaml
+++ b/.github/workflows/examples-qpg.yaml
@@ -63,6 +63,8 @@ jobs:
--target qpg-qpg6105-light \
--target qpg-qpg6105-shell \
--target qpg-qpg6105-persistent-storage \
+ --target qpg-qpg6105-light-switch \
+ --target qpg-qpg6105-thermostat \
build \
--copy-artifacts-to out/artifacts \
"
diff --git a/build/chip/esp32/esp32_codegen.cmake b/build/chip/esp32/esp32_codegen.cmake
index 75cd1f42587469..af943e39fbff30 100644
--- a/build/chip/esp32/esp32_codegen.cmake
+++ b/build/chip/esp32/esp32_codegen.cmake
@@ -33,6 +33,7 @@ macro(chip_app_component_codegen IDL_NAME)
OUTPUTS
"app/PluginApplicationCallbacks.h"
"app/callback-stub.cpp"
+ "app/cluster-init-callback.cpp"
OUTPUT_PATH APP_GEN_DIR
OUTPUT_FILES APP_GEN_FILES
)
diff --git a/config/qpg/toolchain/BUILD.gn b/config/qpg/toolchain/BUILD.gn
index bdf72c9b2ccf5e..65984b186a4f80 100644
--- a/config/qpg/toolchain/BUILD.gn
+++ b/config/qpg/toolchain/BUILD.gn
@@ -31,6 +31,13 @@ arm_toolchain("qpg_lighting_app") {
}
}
+arm_toolchain("qpg_light_switch_app") {
+ toolchain_args = {
+ current_os = "freertos"
+ import("${chip_root}/examples/light-switch-app/qpg/args.gni")
+ }
+}
+
arm_toolchain("qpg_shell_app") {
toolchain_args = {
current_os = "freertos"
diff --git a/config/telink/chip-module/CMakeLists.txt b/config/telink/chip-module/CMakeLists.txt
index f9f4b933cccf5d..418dbc07e0ba0b 100644
--- a/config/telink/chip-module/CMakeLists.txt
+++ b/config/telink/chip-module/CMakeLists.txt
@@ -97,7 +97,6 @@ matter_add_gn_arg_bool ("chip_config_network_layer_ble" CONFIG_BT)
matter_add_gn_arg_bool ("chip_inet_config_enable_ipv4" CONFIG_NET_IPV4)
matter_add_gn_arg_bool ("chip_enable_nfc" CONFIG_CHIP_NFC_COMMISSIONING)
matter_add_gn_arg_bool ("chip_enable_ota_requestor" CONFIG_CHIP_OTA_REQUESTOR)
-matter_add_gn_arg_bool ("chip_enable_bootloader_mcuboot" CONFIG_BOOTLOADER_MCUBOOT)
matter_add_gn_arg_bool ("chip_inet_config_enable_tcp_endpoint" CONFIG_CHIP_BUILD_TESTS)
matter_add_gn_arg_bool ("chip_error_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 1)
matter_add_gn_arg_bool ("chip_progress_logging" CONFIG_MATTER_LOG_LEVEL GREATER_EQUAL 3)
diff --git a/data_model/clusters/BooleanSensorConfiguration.xml b/data_model/clusters/BooleanSensorConfiguration.xml
deleted file mode 100644
index 7321a70113087f..00000000000000
--- a/data_model/clusters/BooleanSensorConfiguration.xml
+++ /dev/null
@@ -1,184 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
- -
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/data_model/clusters/Scenes.xml b/data_model/clusters/Scenes.xml
index f82a470ca28eb5..daa9e5da564a41 100644
--- a/data_model/clusters/Scenes.xml
+++ b/data_model/clusters/Scenes.xml
@@ -1,61 +1,61 @@
-
-
+
@@ -528,4 +528,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/ColorDimmerSwitch.xml b/data_model/device_types/ColorDimmerSwitch.xml
index dcd2ac18b1a912..4de98619c1f9fb 100644
--- a/data_model/device_types/ColorDimmerSwitch.xml
+++ b/data_model/device_types/ColorDimmerSwitch.xml
@@ -1,59 +1,59 @@
-
@@ -73,7 +73,7 @@ Davis, CA 95616, USA
-
+
@@ -89,4 +89,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/ColorTemperatureLight.xml b/data_model/device_types/ColorTemperatureLight.xml
index 889f63db0de1f5..2e6db00535d3e3 100644
--- a/data_model/device_types/ColorTemperatureLight.xml
+++ b/data_model/device_types/ColorTemperatureLight.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -155,4 +155,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/ControlBridge.xml b/data_model/device_types/ControlBridge.xml
index 6ed528c0122d96..6c73377045b533 100644
--- a/data_model/device_types/ControlBridge.xml
+++ b/data_model/device_types/ControlBridge.xml
@@ -1,59 +1,59 @@
-
@@ -74,7 +74,7 @@ required."/>
-
+
@@ -96,4 +96,4 @@ required."/>
-
\ No newline at end of file
+
diff --git a/data_model/device_types/DimmableLight.xml b/data_model/device_types/DimmableLight.xml
index 39f193f53e7553..777cf64847884b 100644
--- a/data_model/device_types/DimmableLight.xml
+++ b/data_model/device_types/DimmableLight.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -142,4 +142,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/DimmablePlug-InUnit.xml b/data_model/device_types/DimmablePlug-InUnit.xml
index 012f752c7cc699..9a304fe9d18460 100644
--- a/data_model/device_types/DimmablePlug-InUnit.xml
+++ b/data_model/device_types/DimmablePlug-InUnit.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -142,4 +142,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/DimmerSwitch.xml b/data_model/device_types/DimmerSwitch.xml
index a3bae868a2498b..9922d6fb96dbcf 100644
--- a/data_model/device_types/DimmerSwitch.xml
+++ b/data_model/device_types/DimmerSwitch.xml
@@ -1,59 +1,59 @@
-
@@ -73,7 +73,7 @@ Davis, CA 95616, USA
-
+
@@ -86,4 +86,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/DoorLock.xml b/data_model/device_types/DoorLock.xml
index b322f991c3b6e4..c5eaf911f8f537 100644
--- a/data_model/device_types/DoorLock.xml
+++ b/data_model/device_types/DoorLock.xml
@@ -1,59 +1,59 @@
-
@@ -72,7 +72,7 @@ Davis, CA 95616, USA
-
+
@@ -187,4 +187,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/DoorLockController.xml b/data_model/device_types/DoorLockController.xml
index 413509de632c6e..6e515bc206e04a 100644
--- a/data_model/device_types/DoorLockController.xml
+++ b/data_model/device_types/DoorLockController.xml
@@ -1,59 +1,59 @@
-
@@ -78,7 +78,7 @@ Davis, CA 95616, USA
-
+
@@ -96,4 +96,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/ExtendedColorLight.xml b/data_model/device_types/ExtendedColorLight.xml
index d0ad7936d3629d..839a9c1db7a75b 100644
--- a/data_model/device_types/ExtendedColorLight.xml
+++ b/data_model/device_types/ExtendedColorLight.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -167,4 +167,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/HeatingCoolingUnit.xml b/data_model/device_types/HeatingCoolingUnit.xml
index 244ff14b0a15fa..3bcf0b8e2db0d1 100644
--- a/data_model/device_types/HeatingCoolingUnit.xml
+++ b/data_model/device_types/HeatingCoolingUnit.xml
@@ -1,59 +1,59 @@
-
@@ -70,7 +70,7 @@ Davis, CA 95616, USA
-
+
@@ -92,4 +92,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/OnOffLight.xml b/data_model/device_types/OnOffLight.xml
index 1ce39e8545c84a..6b12217ff10d6f 100644
--- a/data_model/device_types/OnOffLight.xml
+++ b/data_model/device_types/OnOffLight.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -142,4 +142,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/OnOffLightSwitch.xml b/data_model/device_types/OnOffLightSwitch.xml
index c2c324c8ee5d2a..df64178ade52ad 100644
--- a/data_model/device_types/OnOffLightSwitch.xml
+++ b/data_model/device_types/OnOffLightSwitch.xml
@@ -1,59 +1,59 @@
-
@@ -73,7 +73,7 @@ Davis, CA 95616, USA
-
+
@@ -83,4 +83,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/OnOffPlug-inUnit.xml b/data_model/device_types/OnOffPlug-inUnit.xml
index 11bd17151d5e49..83f1c9d0ec15ec 100644
--- a/data_model/device_types/OnOffPlug-inUnit.xml
+++ b/data_model/device_types/OnOffPlug-inUnit.xml
@@ -1,59 +1,59 @@
-
@@ -76,7 +76,7 @@ Davis, CA 95616, USA
-
+
@@ -142,4 +142,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/OnOffSensor.xml b/data_model/device_types/OnOffSensor.xml
index d2c6553fc1140c..d28f76f6130964 100644
--- a/data_model/device_types/OnOffSensor.xml
+++ b/data_model/device_types/OnOffSensor.xml
@@ -1,59 +1,59 @@
-
@@ -74,7 +74,7 @@ required."/>
-
+
@@ -90,4 +90,4 @@ required."/>
-
\ No newline at end of file
+
diff --git a/data_model/device_types/Pump.xml b/data_model/device_types/Pump.xml
index 6f1b1f39aae53c..298bb43cbb02c6 100644
--- a/data_model/device_types/Pump.xml
+++ b/data_model/device_types/Pump.xml
@@ -1,59 +1,59 @@
-
@@ -70,7 +70,7 @@ Davis, CA 95616, USA
-
+
@@ -107,4 +107,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/PumpController.xml b/data_model/device_types/PumpController.xml
index 1eb302399379fe..223915f4525b40 100644
--- a/data_model/device_types/PumpController.xml
+++ b/data_model/device_types/PumpController.xml
@@ -1,59 +1,59 @@
-
@@ -72,7 +72,7 @@ Davis, CA 95616, USA
-
+
@@ -100,4 +100,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/RoomAirConditioner.xml b/data_model/device_types/RoomAirConditioner.xml
index 86240698da6789..8e6a833406637c 100644
--- a/data_model/device_types/RoomAirConditioner.xml
+++ b/data_model/device_types/RoomAirConditioner.xml
@@ -1,59 +1,59 @@
-
@@ -68,7 +68,7 @@ Davis, CA 95616, USA
-
+
@@ -95,4 +95,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/Thermostat.xml b/data_model/device_types/Thermostat.xml
index 117bf36aa8b025..dac8172278b4ad 100644
--- a/data_model/device_types/Thermostat.xml
+++ b/data_model/device_types/Thermostat.xml
@@ -1,59 +1,59 @@
-
@@ -72,7 +72,7 @@ Davis, CA 95616, USA
-
+
@@ -154,4 +154,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/WindowCovering.xml b/data_model/device_types/WindowCovering.xml
index aecac7e3b24052..1f9e4a3a8ec319 100644
--- a/data_model/device_types/WindowCovering.xml
+++ b/data_model/device_types/WindowCovering.xml
@@ -1,59 +1,59 @@
-
@@ -75,7 +75,7 @@ Davis, CA 95616, USA
-
+
@@ -121,4 +121,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/data_model/device_types/WindowCoveringController.xml b/data_model/device_types/WindowCoveringController.xml
index f61f46f5132b4b..8e31eed548e90e 100644
--- a/data_model/device_types/WindowCoveringController.xml
+++ b/data_model/device_types/WindowCoveringController.xml
@@ -1,59 +1,59 @@
-
@@ -78,7 +78,7 @@ Davis, CA 95616, USA
-
+
@@ -98,4 +98,4 @@ Davis, CA 95616, USA
-
\ No newline at end of file
+
diff --git a/docs/ERROR_CODES.md b/docs/ERROR_CODES.md
index 35dcd05d5bff07..8cd4a4c80940e3 100644
--- a/docs/ERROR_CODES.md
+++ b/docs/ERROR_CODES.md
@@ -44,6 +44,7 @@ This file was **AUTOMATICALLY** generated by
| 26 | 0x1A | `CHIP_ERROR_DUPLICATE_KEY_ID` |
| 27 | 0x1B | `CHIP_ERROR_WRONG_KEY_TYPE` |
| 28 | 0x1C | `CHIP_ERROR_UNINITIALIZED` |
+| 29 | 0x1D | `CHIP_ERROR_INVALID_IPK` |
| 30 | 0x1E | `CHIP_ERROR_INVALID_STRING_LENGTH` |
| 31 | 0x1F | `CHIP_ERROR_INVALID_LIST_LENGTH` |
| 33 | 0x21 | `CHIP_ERROR_END_OF_TLV` |
diff --git a/docs/cluster_and_device_type_dev/cluster_and_device_type_dev.md b/docs/cluster_and_device_type_dev/cluster_and_device_type_dev.md
new file mode 100644
index 00000000000000..9e34e961ae6d87
--- /dev/null
+++ b/docs/cluster_and_device_type_dev/cluster_and_device_type_dev.md
@@ -0,0 +1,251 @@
+# New Clusters & Device Types
+
+The goal of new cluster and device type development is to
+
+1. write the cluster implementations
+2. write the code and supporting material that will allow zap to generate the
+ appropriate ember layers
+3. write the unit tests, test plans and automation scripts that prove the code
+ correctness and allow these new features to be certified
+
+Unit tests, test plans and certification tests are covered in the testing
+section. This document will concentrate on implementing clusters and device
+types in the SDK.
+
+- Cluster Definition
+ - XML
+ - Describes the structures, enums, attributes, commands, events etc.
+ - Direct translation of the spec into code
+ - src/app/zap-templates/zcl/data-model/chip/
+- Cluster Implementation
+
+ - Client side - codegen, you write the glue
+ - Server side - cpp implementation through Ember and / or
+ AttributeAccessInterface & CommandHandlerInterface
+ - src/app/clusters/
+ - build file: src/app/chip_data_model.gni
+ - build file uses data from the codegen to auto-populate the cluster
+ list.
+ - Follow examples in there to get your code building into the image
+ when selected in zap
+
+- Device Type Definitions
+ - XML defines conformance
+ - src/app/zap-templates/zcl/data-model/chip/matter-devices.xml
+
+The following wiki page has a detailed description of how and where to add
+cluster and device type definitions so they are picked up properly by ZAP/ember
+and the SDK.
+
+[https://groups.csa-iot.org/wg/matter-tsg/wiki/howto-add-a-new-device-type](https://groups.csa-iot.org/wg/matter-tsg/wiki/howto-add-a-new-device-type)
+
+Note that the output should also be verified against the spec using the
+[.matter parser tools](https://project-chip.github.io/connectedhomeip-doc/guides/matter_idl_tooling.html).
+
+## ZAP, Ember and Overrides
+
+- Goal: get zap to understand the new cluster so it can be used on devices
+ (XML and glue)
+
+![](../getting_started/img/zap_compiler.png)
+
+### Cluster definitions and ZAP
+
+Please see [ZAP](../getting_started/zap.md) for an introduction to ZAP.
+
+After implementing the changes outlined in the wiki article, your cluster and
+device type should show up in zap. you can check this by running zaptool with
+any zap file.
+
+./scripts/tools/zap/run_zaptool.sh
+
+To ensure the cluster and device type are correctly implemented for ZAP, open
+the endpoint configuration and ensure the device type appears in the device type
+list.
+
+![](../getting_started/img/zap3.png)
+
+Next, check your cluster. The "domain" parameter in the XML controls which group
+the cluster is in. It should have all the expected attributes, commands and
+events.
+
+![](../getting_started/img/zap4.png)
+
+Last, ensure that your attributes have the storage option set appropriately.
+
+![](../getting_started/img/zap5.png)
+
+### Cluster implementation - Ember and overrides
+
+- Ember: layer used to setup/access the endpoints / attributes / commands etc.
+ on the device
+
+ - The build generates the Ember function signatures and defaults
+ - The Cluster server code implements callbacks for initialization,
+ commands, attribute access and event generation
+ - Interaction Model layer will call ember functions when it receives
+ incoming interactions for your cluster
+
+- Overrides
+ - Ember layer is _generated_ at compile time whereas overrides are
+ _installed_ at run time
+ - Overrides are called before the ember layer for attribute access or
+ command handling
+ - AttributeAccessInterface & CommandHandlerInterface
+ - Allow significantly more control, but are more complex
+ - **UNIT TESTABLE**
+ - Both allow fall through to the ember layer (if setup in zap)
+
+#### Cluster Server Initialization
+
+The following diagram shows the flow of messages coming into the Matter core and
+ending in the cluster initialization code.
+
+![](img/cluster_initialization.png)
+
+EmberAfInitializeAttributes - ember attribute storage - for all attributes
+marked as “RAM” in the zap, sets defaults in the storage
+MatterPluginServerCallback - .h is a generated file, .cpp impl is done
+in the server cluster code. Use this to setup the cluster and do attribute
+overrides registerAttributeAccessOverride - use this if you want to handle
+attribute reads and writes externally
+
+Blue sections can be overridden.
+
+#### Cluster Server Attributes
+
+**Two mechanisms**
+
+- Ember layer
+- Override
+
+**ZAP files and implementation**
+
+- For attributes marked as **“RAM”** storage in the zap file
+ - Storage allocated automatically, Ember handles read/write
+ - Generated “Get” and “Set” functions for each attribute in Accessors.h
+ (generated file)
+ - You _CAN_ register an override on the cluster. If you don’t try to
+ encode the attribute in the override, it will fall through to the
+ storage.
+ - If you _DO_ always encode the attribute in the access override
+ function, you’re wasting space.
+- For attributes marked as **“External”** storage in the zap file
+ - NO storage is allocated, no fall through to ember storage
+ - NEED to register an access override for these to work
+
+##### Cluster Server Attributes via Override (read)
+
+![](img/cluster_attribute_read.png)
+
+[AttributeAccessInterface::Read()](https://github.com/project-chip/connectedhomeip/blob/master/src/app/AttributeAccessInterface.h#L424)
+
+```
+CHIP_ERROR Read(const ConcreteReadAttributePath & aPath,
+ AttributeValueEncoder & aEncoder)
+{
+ // Parse aPath to determine the requested attribute
+ switch (aPath.mAttributeId)
+ {
+ case SomeAttribute::Id:
+ // Just encode the value
+ aEncoder.Encode(mSomeValue);
+ break;
+ }
+ // Beware of lists - the need to use EncodeList to have
+ // chunking handled properly
+ return CHIP_NO_ERROR;
+```
+
+#### Cluster Server Attributes via override (write)
+
+Write are handled using the same path as read, but land in the “Write” function
+of the AttributeAccessInterface.
+
+[AttributeAccessInterface::Write()](https://github.com/project-chip/connectedhomeip/blob/master/src/app/AttributeAccessInterface.h#444)
+
+The attribute handler is responsible for constraint checking and Attribute
+persistence
+
+##### Attribute Persistence
+
+- When using AttributeAccessInterface, you need to manage any Attributes that
+ require Persistence.
+- This can be done by using GetSafeAttributePersistenceProvider()
+- This provides a useful API for Reading & Writing values of any type to the
+ default Persistence Store
+ - [src/app/SafeAttributePersistenceProvider.h](https://github.com/project-chip/connectedhomeip/blob/master/src/app/SafeAttributePersistenceProvider.h)
+
+#### Ember layer read / write
+
+In the ember layer functions, the ember layer handles the encode and decode.
+This can work for simple attributes, but is can be challenging for complex
+attribute interactions. The ember layer is also VERY difficult to unit test.
+
+The ember layer provides callbacks for attribute changes so you can handle them
+
+```
+void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & attributePath,
+ uint8_t type, uint16_t size, uint8_t * value)
+
+```
+
+Take care when using this that the callbacks are implemented in a way that can
+be used across examples
+
+#### Cluster Server Commands
+
+- As with Attributes, there is an ember layer option, and an override option
+- **Override**
+ - Registered at runtime
+ - InteractionModelEngine::RegisterCommandHandler
+ - Implement CommandHandlerInterface
+- **Ember**
+ - static
+ - emberAfCallback
+
+![](img/cluster_commands.png)
+
+##### Command Handler Code
+
+- CommandHandlerInterface
+ - Can use HandleCommand function for convenience (sets handled)
+ - If not, need to set whether the command was handled
+ - if no, falls through to ember by default
+ - If entirely handled by this interface, add to
+ src/app/common/templates/config-data.yaml to disable ember
+- Ember interface
+ - Return true if the command was handled, false to have an invalid command
+ response returned
+- For both
+ - Need to handle the return to the caller using either AddResponse or
+ AddStatus in the command handler
+ - Need to handle constraints checking and return the appropriate status or
+ response per the spec
+
+The
+[config-data.yaml](https://github.com/project-chip/connectedhomeip/blob/master/src/app/common/templates/config-data.yaml)
+file is used to turn off ember command callback generation for clusters with
+pure CommandHandlerInterface implementations.
+
+#### Events and Attribute Subscriptions
+
+- **Attribute** change reporting
+ - If you go through the ember storage layer (generated Get/Set functions
+ on the attribute), this is handled for you
+ - If you are using an AttributeAccessInterface, you need to tell the
+ reporting engine that the attribute has changed
+ - **MatterReportingAttributeChangeCallback**
+- **Events**
+ - No direct ember support
+ - Call LogEvent function in EventLogging.h
+
+#### A note on Dynamic Endpoints
+
+- Dynamic endpoint registration
+ - ZAP configs are static at compile time
+ - Can also use dynamic endpoint registration at runtime
+ - common for bridges
+ - **emberAfSetDynamicEndpoint**
+ - If you have your own storage for attributes etc, need to account for
+ dynamic endpoints as well as static
diff --git a/docs/cluster_and_device_type_dev/img/cluster_attribute_read.png b/docs/cluster_and_device_type_dev/img/cluster_attribute_read.png
new file mode 100644
index 00000000000000..5f073aca8067a6
Binary files /dev/null and b/docs/cluster_and_device_type_dev/img/cluster_attribute_read.png differ
diff --git a/docs/cluster_and_device_type_dev/img/cluster_commands.png b/docs/cluster_and_device_type_dev/img/cluster_commands.png
new file mode 100644
index 00000000000000..959774e071b717
Binary files /dev/null and b/docs/cluster_and_device_type_dev/img/cluster_commands.png differ
diff --git a/docs/cluster_and_device_type_dev/img/cluster_initialization.png b/docs/cluster_and_device_type_dev/img/cluster_initialization.png
new file mode 100644
index 00000000000000..9cf980e3f727fb
Binary files /dev/null and b/docs/cluster_and_device_type_dev/img/cluster_initialization.png differ
diff --git a/docs/cluster_and_device_type_dev/index.md b/docs/cluster_and_device_type_dev/index.md
new file mode 100644
index 00000000000000..6d5cf71edfef1c
--- /dev/null
+++ b/docs/cluster_and_device_type_dev/index.md
@@ -0,0 +1,15 @@
+# Cluster and Device Type development
+
+The following docs present a guide on how to develop new clusters and device
+types in the SDK.
+
+```{toctree}
+:glob:
+:maxdepth: 1
+:hidden:
+
+*
+
+```
+
+- [Cluster and device type development](./cluster_and_device_type_dev.md)
diff --git a/docs/clusters.md b/docs/clusters.md
index 1d0453033db586..70f657fd8779ad 100644
--- a/docs/clusters.md
+++ b/docs/clusters.md
@@ -14,7 +14,6 @@ Generally regenerate using one of:
| ---------- | ---------- | ------------------------------------------------------- |
| 3 | 0x03 | Identify |
| 4 | 0x04 | Groups |
-| 5 | 0x05 | Scenes |
| 6 | 0x06 | OnOff |
| 7 | 0x07 | OnOffSwitchConfiguration |
| 8 | 0x08 | LevelControl |
@@ -73,6 +72,7 @@ Generally regenerate using one of:
| 95 | 0x5F | MicrowaveOvenControl |
| 96 | 0x60 | OperationalState |
| 97 | 0x61 | RvcOperationalState |
+| 98 | 0x62 | ScenesManagement |
| 113 | 0x71 | HepaFilterMonitoring |
| 114 | 0x72 | ActivatedCarbonFilterMonitoring |
| 128 | 0x80 | BooleanStateConfiguration |
diff --git a/docs/examples/index.md b/docs/examples/index.md
index e31b434515f11b..0162a25afc149f 100644
--- a/docs/examples/index.md
+++ b/docs/examples/index.md
@@ -131,6 +131,7 @@ lighting-app/qpg/APPLICATION
:maxdepth: 1
light-switch-app/**/README
+light-switch-app/qpg/APPLICATION
```
## Lock example
@@ -282,6 +283,7 @@ temperature-measurement-app/**/README
thermostat/**/README
thermostat/**/Readme
+thermostat/qpg/APPLICATION
```
## TV example
diff --git a/docs/getting_started/SDKBasics.md b/docs/getting_started/SDKBasics.md
new file mode 100644
index 00000000000000..fee03ae7cd484d
--- /dev/null
+++ b/docs/getting_started/SDKBasics.md
@@ -0,0 +1,99 @@
+# SDK Basics
+
+## Getting Started
+
+- SDK Location:
+ [https://github\.com/project\-chip/connectedhomeip](https://github.com/project-chip/connectedhomeip)\_
+- email _[help@csa\-iot\.org](mailto:help@csa-iot.org)_ to get access to the
+ other repos and to be added to project\-chip org
+
+## Basic SDK Architecture
+
+![](img/SDK_layers.png)
+
+### Platform Layer
+
+Platform layer implements the connection to the network stack and the base OS.
+Messages flow off the wire into the platform layer, where they are routed into
+the platform API for processing by the Matter stack.
+
+### Platform API
+
+The platform API defines a common layer to interact with the core.
+
+### Core
+
+Core encompasses a huge part of the spec, including all of the the underlying
+communication protocols. The goal of the core code is to deliver valid messages
+to the ember layer indicating the cluster request and associated endpoint
+information.
+
+### Ember
+
+The ember layer is a generated layer that implements the composition of ONE
+SPECIFIC device. It looks at each message and determines if the device has
+implemented the selected attribute or command on the cluster on the selected
+endpoint, and then blocks or routes accordingly, based on the implementation and
+the access control.
+
+Valid requests are forwarded on to the cluster implementations to handle and
+invalid requests get sent back with an error. Ember layer is the piece that
+makes your device your device. Most are generated statically using zap.
+
+### Cluster implementations
+
+The cluster implementations are the logic that back the cluster. The cluster
+implementation code receives messages from the ember layer to request data model
+operations on the cluster (reads / writes / command invokes). They are also
+responsible for event generation and attribute change reporting. Simple cluster
+logic can be written in the ember callback functions, but more complex cluster
+logic is handled in the run-time installed interface layers.
+
+## SDK Organization (some key bits)
+
+- docs
+ - [docs/guides/BUILDING\.md](https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/BUILDING.md) -
+ follow this first
+ - [docs/guides/chip_tool_guide.md](https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/chip_tool_guide.md)
+- examples
+ - [examples/chip-tool](https://github.com/project-chip/connectedhomeip/blob/master/examples/chip-tool) -
+ main controller example
+ - [examples/all-clusters-app](https://github.com/project-chip/connectedhomeip/blob/master/examples/all-cluster-app) -
+ QA app
+ - [examples/\](https://github.com/project-chip/connectedhomeip/blob/master/examples) -
+ Specific Device examples
+- scripts
+ - [bootstrap.sh](https://github.com/project-chip/connectedhomeip/blob/master/scripts/bootstrap.sh)
+ &
+ [activate.sh](https://github.com/project-chip/connectedhomeip/blob/master/scripts/activate.sh) -
+ environment setup
+ - [build/build_examples.py](https://github.com/project-chip/connectedhomeip/blob/master/scripts/build/build_examples.py) -
+ build example code
+ - [tools/zap/run_zaptool.sh](https://github.com/project-chip/connectedhomeip/blob/master/scripts/tools/zap/run_zaptool.sh) -
+ start zap tool
+ - [tools/zap_regen_all.py](https://github.com/project-chip/connectedhomeip/blob/master/scripts/tools/zap_regen_all.py) -
+ .zap -> .matter
+- src
+ - [controller](https://github.com/project-chip/connectedhomeip/blob/master/src/controller/) -
+ client side code including python implementation
+ - [app](https://github.com/project-chip/connectedhomeip/blob/master/src/app) -
+ base server side code
+ - [app/clusters](https://github.com/project-chip/connectedhomeip/blob/master/src/app/clusters) -
+ cluster implementations (.cpp)
+ - [app/zap-templates/zcl/data-model/chip/](https://github.com/project-chip/connectedhomeip/blob/master/src/app/zap-templates/zcl/data-model/chip/) -
+ cluster definitions (.xml)
+ - [app/tests/suites/certification](https://github.com/project-chip/connectedhomeip/blob/master/src/app/tests/suites/certification) -
+ yaml cert test automation scripts
+ - [lib/support/](https://github.com/project-chip/connectedhomeip/blob/master/src/lib/support/) -
+ Embedded versions of common utilities
+ - [platform](https://github.com/project-chip/connectedhomeip/blob/master/src/platform) -
+ platform delegate APIs / implementations
+ - [include/platform](https://github.com/project-chip/connectedhomeip/blob/master/src/include/platform) -
+ platform delegate APIs / implementations
+ - [python_testing](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing) -
+ python cert test automation scripts
+- zzz_generated/app-common/app-common/zap-generated/\*
+ - all the generated cluster logic / namespaces
+- data_model
+ - These files are generated and are used to check conformance against the
+ spec. They should not be manually changed.
diff --git a/docs/getting_started/discovery_from_a_host_computer.md b/docs/getting_started/discovery_from_a_host_computer.md
new file mode 100644
index 00000000000000..5b02524460ff80
--- /dev/null
+++ b/docs/getting_started/discovery_from_a_host_computer.md
@@ -0,0 +1,14 @@
+# Device discovery from a Host computer (mDNS Scanning)
+
+Device discovery for commissioning over the operational network happens over
+DNS-SD. DNS-SD is handled over mDNS on WiFi and using an SRP server on a boarder
+router for thread. On a computer, you can use the built-in mDNS applications to
+discover devices for the purposes of testing. Avahi is the standard mDNS program
+for linux, dns-sd is used on macs.
+
+- Scanning for commissionable devices
+ - avahi-browse -d local \_matterc.\_udp --resolve
+ - dns-sd -B \_matterc.\_udp
+- Scanning for commissioned devices
+ - avahi-browse -d local \_matter.\_tcp --resolve
+ - dns-sd -B \_matter.\_tcp
diff --git a/docs/getting_started/img/SDK_layers.png b/docs/getting_started/img/SDK_layers.png
new file mode 100644
index 00000000000000..84ecda72153507
Binary files /dev/null and b/docs/getting_started/img/SDK_layers.png differ
diff --git a/docs/getting_started/img/ci_raw_logs.png b/docs/getting_started/img/ci_raw_logs.png
new file mode 100644
index 00000000000000..84465ab7d19592
Binary files /dev/null and b/docs/getting_started/img/ci_raw_logs.png differ
diff --git a/docs/getting_started/img/zap1.png b/docs/getting_started/img/zap1.png
new file mode 100644
index 00000000000000..4356cda98e85e5
Binary files /dev/null and b/docs/getting_started/img/zap1.png differ
diff --git a/docs/getting_started/img/zap2.png b/docs/getting_started/img/zap2.png
new file mode 100644
index 00000000000000..cd73e0417c25ad
Binary files /dev/null and b/docs/getting_started/img/zap2.png differ
diff --git a/docs/getting_started/img/zap3.png b/docs/getting_started/img/zap3.png
new file mode 100644
index 00000000000000..018778c7dceeb4
Binary files /dev/null and b/docs/getting_started/img/zap3.png differ
diff --git a/docs/getting_started/img/zap4.png b/docs/getting_started/img/zap4.png
new file mode 100644
index 00000000000000..92ab5cce5186b4
Binary files /dev/null and b/docs/getting_started/img/zap4.png differ
diff --git a/docs/getting_started/img/zap5.png b/docs/getting_started/img/zap5.png
new file mode 100644
index 00000000000000..5ca6908144704b
Binary files /dev/null and b/docs/getting_started/img/zap5.png differ
diff --git a/docs/getting_started/img/zap6.png b/docs/getting_started/img/zap6.png
new file mode 100644
index 00000000000000..0901e225fbff46
Binary files /dev/null and b/docs/getting_started/img/zap6.png differ
diff --git a/docs/getting_started/img/zap_compiler.png b/docs/getting_started/img/zap_compiler.png
new file mode 100644
index 00000000000000..68c1e09395a069
Binary files /dev/null and b/docs/getting_started/img/zap_compiler.png differ
diff --git a/docs/getting_started/index.md b/docs/getting_started/index.md
new file mode 100644
index 00000000000000..b961701cc98bc8
--- /dev/null
+++ b/docs/getting_started/index.md
@@ -0,0 +1,16 @@
+# Getting Started
+
+The following docs are a brief introduction to SDK development.
+
+```{toctree}
+:glob:
+:maxdepth: 1
+:hidden:
+
+*
+
+```
+
+- [SDK Basics](./SDKBasics.md)
+- [ZAP](./zap.md)
+- [Discover from a host computer](./discovery_from_a_host_computer.md)
diff --git a/docs/getting_started/zap.md b/docs/getting_started/zap.md
new file mode 100644
index 00000000000000..0177aa8ba4f3a7
--- /dev/null
+++ b/docs/getting_started/zap.md
@@ -0,0 +1,92 @@
+# ZAP
+
+The ZAP tool is a GUI tool that is used to generate a .zap file that describes
+the endpoint composition of a device. This includes the endpoints on the device,
+the clusters and device types on each endpoint, as well as the cluster features,
+attributes, commands and events. The .zap file is used by the ZAP compiler along
+with the cluster definitions files to generate an ember layer. This happens
+automatically as part of the build process, and the ember layer is compiled into
+the firmware.
+
+.matter files are a human-readable version of the .zap that can be used for
+review
+
+![](img/zap_compiler.png)
+
+## A quick tour
+
+Run ./scripts/tools/zap/run_zaptool.sh \ to open a file in zap.
+Select the Matter format.
+
+The left hand side shows the endpoint configuration.
+
+![](img/zap1.png)
+
+Select the edit button (pencil) on an endpoint to edit it.
+
+![](img/zap2.png)
+
+This will open a dialog where you can edit the device types and revisions of
+your endpoint. Do not edit the profile ID or network. The profile ID identifies
+the zap endpoint as being a matter endpoint, network is a property that only
+applies to zigbee products.
+
+![](img/zap3.png)
+
+To edit the clusters on an endpoint, select the endpoint. To enable a cluster on
+an endpoint, set the "enable" drop down to "server" and click the gear to edit
+the cluster
+
+![](img/zap4.png)
+
+### Cluster setup
+
+#### Attributes
+
+The zap file will list all the available attributes in the cluster. The column
+settings are as follows:
+
+- Enabled - turn this on to enable the attribute on the device.
+- Attribute ID - Attribute ID of the attribute from the spec
+- Attribute - Attribute name from the spec
+- Required - This is set to yes if the attribute is mandatory. Note that some
+ attributes become mandatory when features or other attributes are enabled.
+ This will NOT be reflected in the UI. It is up to the device manufacture to
+ ensure the device is conformant with the specification. Conformance can be
+ checked using the conformance checker test
+ [TC_DeviceConformance.py](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing/TC_DeviceConformance.py)
+
+- Client/Server - For Matter, all attributes will be server
+- Mfg code - applies only to manufacturer specific attributes
+- Storage option - determines whether ember allocates storage for the
+ attribute. The correct value for this field is determined by the cluster
+ implementation. Clusters that use the ember layer directly will be RAM,
+ clusters that use the override layer and implement their own storage are
+ external. Files in the Matter SDK will set these values as appropriate based
+ on the the cluster implementations and as described in the Matter zap config
+ document. It is best to leave these values as-is unless you have a specific
+ reason to override them.
+
+[//]:
+ #
+ "NOTE: Insert a link to the override specification documentation once that is up"
+
+- Type - type from the spec
+- Default - this is different than the "default" set in the spec, and
+ represents the desired starting value for an attribute IF it is implemented
+ in the ember layer (RAM storage)
+
+![](img/zap5.png)
+
+#### Attribute Reporting
+
+This does not apply to Matter and is unused.
+
+#### Commands
+
+Check off the commands you wish to support. Response commands are required if
+the corresponding Request command is supported. ![](img/zap6.png)
+
+#### Events
+
+This does not apply to Matter and is unused.
diff --git a/docs/guides/python_chip_controller_building.md b/docs/guides/python_chip_controller_building.md
index 7edbede54057ae..c940f2c92575e7 100644
--- a/docs/guides/python_chip_controller_building.md
+++ b/docs/guides/python_chip_controller_building.md
@@ -539,7 +539,7 @@ OnOff
OperationalCredentials
PumpConfigurationAndControl
RelativeHumidityMeasurement
-Scenes
+ScenesManagement
SoftwareDiagnostics
Switch
Channel
diff --git a/docs/index.md b/docs/index.md
index f6575ed88a5d7c..12218445600743 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -11,6 +11,8 @@ VSCODE_DEVELOPMENT
api/index
ci-cd/index
discussion/index
+getting_started/index
+cluster_and_device_type_dev/index
guides/index
style/index
examples/index
diff --git a/examples/air-quality-sensor-app/telink/CMakeLists.txt b/examples/air-quality-sensor-app/telink/CMakeLists.txt
index 908bea9eb73a98..5ed8c314f1b334 100644
--- a/examples/air-quality-sensor-app/telink/CMakeLists.txt
+++ b/examples/air-quality-sensor-app/telink/CMakeLists.txt
@@ -86,10 +86,6 @@ target_include_directories(app PRIVATE
${TELINK_COMMON}/util/include
${CHIP_ROOT}/examples/air-quality-sensor-app/air-quality-sensor-common/include)
-add_definitions(
- "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER="
-)
-
target_sources(app PRIVATE
src/AppTask.cpp
src/ZclCallbacks.cpp
@@ -107,3 +103,7 @@ chip_configure_data_model(app
INCLUDE_SERVER
ZAP_FILE ${CMAKE_CURRENT_SOURCE_DIR}/../air-quality-sensor-common/air-quality-sensor-app.zap
)
+
+if(CONFIG_BOOTLOADER_MCUBOOT)
+ target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp)
+endif()
diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter
index 9c3e474946addf..c003d8d439803f 100644
--- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter
+++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter
@@ -128,199 +128,6 @@ cluster Groups = 4 {
fabric command access(invoke: manage) AddGroupIfIdentifying(AddGroupIfIdentifyingRequest): DefaultSuccess = 5;
}
-/** Attributes and commands for scene configuration and manipulation. */
-provisional cluster Scenes = 5 {
- revision 5;
-
- bitmap CopyModeBitmap : bitmap8 {
- kCopyAllScenes = 0x1;
- }
-
- bitmap Feature : bitmap32 {
- kSceneNames = 0x1;
- kExplicit = 0x2;
- kTableSize = 0x4;
- kFabricScenes = 0x8;
- }
-
- bitmap NameSupportBitmap : bitmap8 {
- kSceneNames = 0x80;
- }
-
- struct AttributeValuePair {
- attrib_id attributeID = 0;
- int32u attributeValue = 1;
- }
-
- struct ExtensionFieldSet {
- cluster_id clusterID = 0;
- AttributeValuePair attributeValueList[] = 1;
- }
-
- fabric_scoped struct SceneInfoStruct {
- int8u sceneCount = 0;
- fabric_sensitive int8u currentScene = 1;
- fabric_sensitive group_id currentGroup = 2;
- fabric_sensitive boolean sceneValid = 3;
- int8u remainingCapacity = 4;
- fabric_idx fabricIndex = 254;
- }
-
- readonly attribute optional int8u sceneCount = 0;
- readonly attribute optional int8u currentScene = 1;
- readonly attribute optional group_id currentGroup = 2;
- readonly attribute optional boolean sceneValid = 3;
- readonly attribute NameSupportBitmap nameSupport = 4;
- readonly attribute optional nullable node_id lastConfiguredBy = 5;
- readonly attribute int16u sceneTableSize = 6;
- readonly attribute SceneInfoStruct fabricSceneInfo[] = 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 AddSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- int16u transitionTime = 2;
- char_string sceneName = 3;
- ExtensionFieldSet extensionFieldSets[] = 4;
- }
-
- response struct AddSceneResponse = 0 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct ViewSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct ViewSceneResponse = 1 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- optional int16u transitionTime = 3;
- optional char_string sceneName = 4;
- optional ExtensionFieldSet extensionFieldSets[] = 5;
- }
-
- request struct RemoveSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct RemoveSceneResponse = 2 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct RemoveAllScenesRequest {
- group_id groupID = 0;
- }
-
- response struct RemoveAllScenesResponse = 3 {
- status status = 0;
- group_id groupID = 1;
- }
-
- request struct StoreSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct StoreSceneResponse = 4 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct RecallSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- optional nullable int16u transitionTime = 2;
- }
-
- request struct GetSceneMembershipRequest {
- group_id groupID = 0;
- }
-
- response struct GetSceneMembershipResponse = 6 {
- status status = 0;
- nullable int8u capacity = 1;
- group_id groupID = 2;
- optional int8u sceneList[] = 3;
- }
-
- request struct EnhancedAddSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- int16u transitionTime = 2;
- char_string sceneName = 3;
- ExtensionFieldSet extensionFieldSets[] = 4;
- }
-
- response struct EnhancedAddSceneResponse = 64 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct EnhancedViewSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct EnhancedViewSceneResponse = 65 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- optional int16u transitionTime = 3;
- optional char_string sceneName = 4;
- optional ExtensionFieldSet extensionFieldSets[] = 5;
- }
-
- request struct CopySceneRequest {
- CopyModeBitmap mode = 0;
- group_id groupIdentifierFrom = 1;
- int8u sceneIdentifierFrom = 2;
- group_id groupIdentifierTo = 3;
- int8u sceneIdentifierTo = 4;
- }
-
- response struct CopySceneResponse = 66 {
- status status = 0;
- group_id groupIdentifierFrom = 1;
- int8u sceneIdentifierFrom = 2;
- }
-
- /** Add a scene to the scene table. Extension field sets are supported, and are inputed as '{"ClusterID": VALUE, "AttributeValueList":[{"AttributeId": VALUE, "AttributeValue": VALUE}]}' */
- fabric command access(invoke: manage) AddScene(AddSceneRequest): AddSceneResponse = 0;
- /** Retrieves the requested scene entry from its Scene table. */
- fabric command ViewScene(ViewSceneRequest): ViewSceneResponse = 1;
- /** Removes the requested scene entry, corresponding to the value of the GroupID field, from its Scene Table */
- fabric command access(invoke: manage) RemoveScene(RemoveSceneRequest): RemoveSceneResponse = 2;
- /** Remove all scenes, corresponding to the value of the GroupID field, from its Scene Table */
- fabric command access(invoke: manage) RemoveAllScenes(RemoveAllScenesRequest): RemoveAllScenesResponse = 3;
- /** Adds the scene entry into its Scene Table along with all extension field sets corresponding to the current state of other clusters on the same endpoint */
- fabric command access(invoke: manage) StoreScene(StoreSceneRequest): StoreSceneResponse = 4;
- /** Set the attributes and corresponding state for each other cluster implemented on the endpoint accordingly to the resquested scene entry in the Scene Table */
- fabric command RecallScene(RecallSceneRequest): DefaultSuccess = 5;
- /** Get an unused scene identifier when no commissioning tool is in the network, or for a commissioning tool to get the used scene identifiers within a certain group */
- fabric command GetSceneMembership(GetSceneMembershipRequest): GetSceneMembershipResponse = 6;
- /** Allows a scene to be added using a finer scene transition time than the AddScene command. */
- fabric command EnhancedAddScene(EnhancedAddSceneRequest): EnhancedAddSceneResponse = 64;
- /** Allows a scene to be retrieved using a finer scene transition time than the ViewScene command */
- fabric command EnhancedViewScene(EnhancedViewSceneRequest): EnhancedViewSceneResponse = 65;
- /** Allows a client to efficiently copy scenes from one group/scene identifier pair to another group/scene identifier pair. */
- fabric command CopyScene(CopySceneRequest): CopySceneResponse = 66;
-}
-
/** Attributes and commands for switching devices between 'On' and 'Off' states. */
cluster OnOff = 6 {
revision 6;
@@ -3041,6 +2848,7 @@ cluster RvcRunMode = 84 {
enum ModeTag : enum16 {
kIdle = 16384;
kCleaning = 16385;
+ kMapping = 16386;
}
enum StatusCode : enum8 {
@@ -3612,6 +3420,201 @@ cluster RvcOperationalState = 97 {
command Start(): OperationalCommandResponse = 2;
/** Upon receipt, the device SHALL resume its operation from the point it was at when it received the Pause command, or from the point when it was paused by means outside of this cluster (for example by manual button press). */
command Resume(): OperationalCommandResponse = 3;
+ /** On receipt of this command, the device SHALL start seeking the charging dock, if possible in the current state of the device. */
+ command GoHome(): OperationalCommandResponse = 128;
+}
+
+/** Attributes and commands for scene configuration and manipulation. */
+provisional cluster ScenesManagement = 98 {
+ revision 5;
+
+ bitmap CopyModeBitmap : bitmap8 {
+ kCopyAllScenes = 0x1;
+ }
+
+ bitmap Feature : bitmap32 {
+ kSceneNames = 0x1;
+ kExplicit = 0x2;
+ kTableSize = 0x4;
+ kFabricScenes = 0x8;
+ }
+
+ bitmap NameSupportBitmap : bitmap8 {
+ kSceneNames = 0x80;
+ }
+
+ struct AttributeValuePair {
+ attrib_id attributeID = 0;
+ int32u attributeValue = 1;
+ }
+
+ struct ExtensionFieldSet {
+ cluster_id clusterID = 0;
+ AttributeValuePair attributeValueList[] = 1;
+ }
+
+ fabric_scoped struct SceneInfoStruct {
+ int8u sceneCount = 0;
+ fabric_sensitive int8u currentScene = 1;
+ fabric_sensitive group_id currentGroup = 2;
+ fabric_sensitive boolean sceneValid = 3;
+ int8u remainingCapacity = 4;
+ fabric_idx fabricIndex = 254;
+ }
+
+ readonly attribute optional int8u sceneCount = 0;
+ readonly attribute optional int8u currentScene = 1;
+ readonly attribute optional group_id currentGroup = 2;
+ readonly attribute optional boolean sceneValid = 3;
+ readonly attribute NameSupportBitmap nameSupport = 4;
+ readonly attribute optional nullable node_id lastConfiguredBy = 5;
+ readonly attribute int16u sceneTableSize = 6;
+ readonly attribute SceneInfoStruct fabricSceneInfo[] = 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 AddSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ int16u transitionTime = 2;
+ char_string sceneName = 3;
+ ExtensionFieldSet extensionFieldSets[] = 4;
+ }
+
+ response struct AddSceneResponse = 0 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct ViewSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct ViewSceneResponse = 1 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ optional int16u transitionTime = 3;
+ optional char_string sceneName = 4;
+ optional ExtensionFieldSet extensionFieldSets[] = 5;
+ }
+
+ request struct RemoveSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct RemoveSceneResponse = 2 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct RemoveAllScenesRequest {
+ group_id groupID = 0;
+ }
+
+ response struct RemoveAllScenesResponse = 3 {
+ status status = 0;
+ group_id groupID = 1;
+ }
+
+ request struct StoreSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct StoreSceneResponse = 4 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct RecallSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ optional nullable int16u transitionTime = 2;
+ }
+
+ request struct GetSceneMembershipRequest {
+ group_id groupID = 0;
+ }
+
+ response struct GetSceneMembershipResponse = 6 {
+ status status = 0;
+ nullable int8u capacity = 1;
+ group_id groupID = 2;
+ optional int8u sceneList[] = 3;
+ }
+
+ request struct EnhancedAddSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ int16u transitionTime = 2;
+ char_string sceneName = 3;
+ ExtensionFieldSet extensionFieldSets[] = 4;
+ }
+
+ response struct EnhancedAddSceneResponse = 64 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct EnhancedViewSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct EnhancedViewSceneResponse = 65 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ optional int16u transitionTime = 3;
+ optional char_string sceneName = 4;
+ optional ExtensionFieldSet extensionFieldSets[] = 5;
+ }
+
+ request struct CopySceneRequest {
+ CopyModeBitmap mode = 0;
+ group_id groupIdentifierFrom = 1;
+ int8u sceneIdentifierFrom = 2;
+ group_id groupIdentifierTo = 3;
+ int8u sceneIdentifierTo = 4;
+ }
+
+ response struct CopySceneResponse = 66 {
+ status status = 0;
+ group_id groupIdentifierFrom = 1;
+ int8u sceneIdentifierFrom = 2;
+ }
+
+ /** Add a scene to the scene table. Extension field sets are supported, and are inputed as '{"ClusterID": VALUE, "AttributeValueList":[{"AttributeId": VALUE, "AttributeValue": VALUE}]}' */
+ fabric command access(invoke: manage) AddScene(AddSceneRequest): AddSceneResponse = 0;
+ /** Retrieves the requested scene entry from its Scene table. */
+ fabric command ViewScene(ViewSceneRequest): ViewSceneResponse = 1;
+ /** Removes the requested scene entry, corresponding to the value of the GroupID field, from its Scene Table */
+ fabric command access(invoke: manage) RemoveScene(RemoveSceneRequest): RemoveSceneResponse = 2;
+ /** Remove all scenes, corresponding to the value of the GroupID field, from its Scene Table */
+ fabric command access(invoke: manage) RemoveAllScenes(RemoveAllScenesRequest): RemoveAllScenesResponse = 3;
+ /** Adds the scene entry into its Scene Table along with all extension field sets corresponding to the current state of other clusters on the same endpoint */
+ fabric command access(invoke: manage) StoreScene(StoreSceneRequest): StoreSceneResponse = 4;
+ /** Set the attributes and corresponding state for each other cluster implemented on the endpoint accordingly to the resquested scene entry in the Scene Table */
+ fabric command RecallScene(RecallSceneRequest): DefaultSuccess = 5;
+ /** Get an unused scene identifier when no commissioning tool is in the network, or for a commissioning tool to get the used scene identifiers within a certain group */
+ fabric command GetSceneMembership(GetSceneMembershipRequest): GetSceneMembershipResponse = 6;
+ /** Allows a scene to be added using a finer scene transition time than the AddScene command. */
+ fabric command EnhancedAddScene(EnhancedAddSceneRequest): EnhancedAddSceneResponse = 64;
+ /** Allows a scene to be retrieved using a finer scene transition time than the ViewScene command */
+ fabric command EnhancedViewScene(EnhancedViewSceneRequest): EnhancedViewSceneResponse = 65;
+ /** Allows a client to efficiently copy scenes from one group/scene identifier pair to another group/scene identifier pair. */
+ fabric command CopyScene(CopySceneRequest): CopySceneResponse = 66;
}
/** Attributes and commands for monitoring HEPA filters in a device */
@@ -3680,31 +3683,148 @@ cluster ActivatedCarbonFilterMonitoring = 114 {
kDown = 1;
}
- enum ProductIdentifierTypeEnum : enum8 {
- kUPC = 0;
- kGTIN8 = 1;
- kEAN = 2;
- kGTIN14 = 3;
- kOEM = 4;
+ enum ProductIdentifierTypeEnum : enum8 {
+ kUPC = 0;
+ kGTIN8 = 1;
+ kEAN = 2;
+ kGTIN14 = 3;
+ kOEM = 4;
+ }
+
+ bitmap Feature : bitmap32 {
+ kCondition = 0x1;
+ kWarning = 0x2;
+ kReplacementProductList = 0x4;
+ }
+
+ struct ReplacementProductStruct {
+ ProductIdentifierTypeEnum productIdentifierType = 0;
+ char_string<20> productIdentifierValue = 1;
+ }
+
+ readonly attribute optional percent condition = 0;
+ readonly attribute optional DegradationDirectionEnum degradationDirection = 1;
+ readonly attribute ChangeIndicationEnum changeIndication = 2;
+ readonly attribute optional boolean inPlaceIndicator = 3;
+ attribute optional nullable epoch_s lastChangedTime = 4;
+ readonly attribute optional ReplacementProductStruct replacementProductList[] = 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;
+
+ /** Reset the condition of the replaceable to the non degraded state */
+ command ResetCondition(): DefaultSuccess = 0;
+}
+
+/** This cluster is used to configure a boolean sensor. */
+provisional cluster BooleanStateConfiguration = 128 {
+ revision 1;
+
+ bitmap AlarmModeBitmap : bitmap8 {
+ kVisual = 0x1;
+ kAudible = 0x2;
+ }
+
+ bitmap Feature : bitmap32 {
+ kVisual = 0x1;
+ kAudible = 0x2;
+ kAlarmSuppress = 0x4;
+ kSensitivityLevel = 0x8;
+ }
+
+ bitmap SensorFaultBitmap : bitmap16 {
+ kGeneralFault = 0x1;
+ }
+
+ info event AlarmsStateChanged = 0 {
+ AlarmModeBitmap alarmsActive = 0;
+ optional AlarmModeBitmap alarmsSuppressed = 1;
+ }
+
+ info event SensorFault = 1 {
+ SensorFaultBitmap sensorFault = 0;
+ }
+
+ attribute optional int8u currentSensitivityLevel = 0;
+ readonly attribute optional int8u supportedSensitivityLevels = 1;
+ readonly attribute optional int8u defaultSensitivityLevel = 2;
+ readonly attribute optional AlarmModeBitmap alarmsActive = 3;
+ readonly attribute optional AlarmModeBitmap alarmsSuppressed = 4;
+ readonly attribute optional AlarmModeBitmap alarmsEnabled = 5;
+ readonly attribute optional AlarmModeBitmap alarmsSupported = 6;
+ readonly attribute optional SensorFaultBitmap sensorFault = 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 SuppressAlarmRequest {
+ AlarmModeBitmap alarmsToSuppress = 0;
+ }
+
+ request struct EnableDisableAlarmRequest {
+ AlarmModeBitmap alarmsToEnableDisable = 0;
+ }
+
+ /** This command is used to suppress the specified alarm mode. */
+ command SuppressAlarm(SuppressAlarmRequest): DefaultSuccess = 0;
+ /** This command is used to enable or disable the specified alarm mode. */
+ command EnableDisableAlarm(EnableDisableAlarmRequest): DefaultSuccess = 1;
+}
+
+/** This cluster is used to configure a valve. */
+provisional cluster ValveConfigurationAndControl = 129 {
+ revision 1;
+
+ enum StatusCodeEnum : enum8 {
+ kFailureDueToFault = 2;
+ }
+
+ enum ValveStateEnum : enum8 {
+ kClosed = 0;
+ kOpen = 1;
+ kTransitioning = 2;
+ }
+
+ bitmap Feature : bitmap32 {
+ kTimeSync = 0x1;
+ kLevel = 0x2;
+ }
+
+ bitmap ValveFaultBitmap : bitmap16 {
+ kGeneralFault = 0x1;
+ kBlocked = 0x2;
+ kLeaking = 0x4;
+ kNotConnected = 0x8;
+ kShortCircuit = 0x10;
+ kCurrentExceeded = 0x20;
}
- bitmap Feature : bitmap32 {
- kCondition = 0x1;
- kWarning = 0x2;
- kReplacementProductList = 0x4;
+ info event ValveStateChanged = 0 {
+ ValveStateEnum valveState = 0;
+ optional percent valveLevel = 1;
}
- struct ReplacementProductStruct {
- ProductIdentifierTypeEnum productIdentifierType = 0;
- char_string<20> productIdentifierValue = 1;
+ info event ValveFault = 1 {
+ ValveFaultBitmap valveFault = 0;
}
- readonly attribute optional percent condition = 0;
- readonly attribute optional DegradationDirectionEnum degradationDirection = 1;
- readonly attribute ChangeIndicationEnum changeIndication = 2;
- readonly attribute optional boolean inPlaceIndicator = 3;
- attribute optional nullable epoch_s lastChangedTime = 4;
- readonly attribute optional ReplacementProductStruct replacementProductList[] = 5;
+ readonly attribute nullable elapsed_s openDuration = 0;
+ attribute nullable elapsed_s defaultOpenDuration = 1;
+ readonly attribute optional nullable epoch_us autoCloseTime = 2;
+ readonly attribute nullable elapsed_s remainingDuration = 3;
+ readonly attribute nullable ValveStateEnum currentState = 4;
+ readonly attribute nullable ValveStateEnum targetState = 5;
+ readonly attribute optional nullable percent currentLevel = 6;
+ readonly attribute optional nullable percent targetLevel = 7;
+ attribute optional percent defaultOpenLevel = 8;
+ readonly attribute optional ValveFaultBitmap valveFault = 9;
+ readonly attribute optional int8u levelStep = 10;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -3712,8 +3832,15 @@ cluster ActivatedCarbonFilterMonitoring = 114 {
readonly attribute bitmap32 featureMap = 65532;
readonly attribute int16u clusterRevision = 65533;
- /** Reset the condition of the replaceable to the non degraded state */
- command ResetCondition(): DefaultSuccess = 0;
+ request struct OpenRequest {
+ optional nullable elapsed_s openDuration = 0;
+ optional percent targetLevel = 1;
+ }
+
+ /** This command is used to set the valve to its open position. */
+ command Open(OpenRequest): DefaultSuccess = 0;
+ /** This command is used to set the valve to its closed position. */
+ command Close(): DefaultSuccess = 1;
}
/** This cluster provides a mechanism for querying data about the electrical energy imported or provided by the server. */
@@ -3795,6 +3922,185 @@ provisional cluster ElectricalEnergyMeasurement = 145 {
readonly attribute int16u clusterRevision = 65533;
}
+/** This cluster allows a client to manage the power draw of a device. An example of such a client could be an Energy Management System (EMS) which controls an Energy Smart Appliance (ESA). */
+provisional cluster DeviceEnergyManagement = 152 {
+ revision 2;
+
+ enum CauseEnum : enum8 {
+ kNormalCompletion = 0;
+ kOffline = 1;
+ kFault = 2;
+ kUserOptOut = 3;
+ }
+
+ enum CostTypeEnum : enum8 {
+ kFinancial = 0;
+ kGHGEmissions = 1;
+ kComfort = 2;
+ kTemperature = 3;
+ }
+
+ enum ESAStateEnum : enum8 {
+ kOffline = 0;
+ kOnline = 1;
+ kFault = 2;
+ kUserOptOut = 3;
+ kPowerAdjustActive = 4;
+ kPaused = 5;
+ }
+
+ enum ESATypeEnum : enum8 {
+ kEVSE = 0;
+ kSpaceHeating = 1;
+ kWaterHeating = 2;
+ kSpaceCooling = 3;
+ kSpaceHeatingCooling = 4;
+ kBatteryStorage = 5;
+ kSolarPV = 6;
+ kFridgeFreezer = 7;
+ kWashingMachine = 8;
+ kDishwasher = 9;
+ kCooking = 10;
+ kHomeWaterPump = 11;
+ kIrrigationWaterPump = 12;
+ kPoolPump = 13;
+ kOther = 255;
+ }
+
+ bitmap Feature : bitmap32 {
+ kPowerAdjustment = 0x1;
+ kPowerForecastReporting = 0x2;
+ kStateForecastReporting = 0x4;
+ kForecastAdjustment = 0x8;
+ }
+
+ struct CostStruct {
+ CostTypeEnum costType = 0;
+ int32s value = 1;
+ int8u decimalPoints = 2;
+ optional int16u currency = 3;
+ }
+
+ struct SlotStruct {
+ elapsed_s minDuration = 0;
+ elapsed_s maxDuration = 1;
+ elapsed_s defaultDuration = 2;
+ elapsed_s elapsedSlotTime = 3;
+ elapsed_s remainingSlotTime = 4;
+ boolean slotIsPauseable = 5;
+ elapsed_s minPauseDuration = 6;
+ elapsed_s maxPauseDuration = 7;
+ optional int16u manufacturerESAState = 8;
+ optional power_mw nominalPower = 9;
+ optional power_mw minPower = 10;
+ optional power_mw maxPower = 11;
+ optional energy_mwh nominalEnergy = 12;
+ optional CostStruct costs[] = 13;
+ optional power_mw minPowerAdjustment = 14;
+ optional power_mw maxPowerAdjustment = 15;
+ optional elapsed_s minDurationAdjustment = 16;
+ optional elapsed_s maxDurationAdjustment = 17;
+ }
+
+ struct ForecastStruct {
+ int16u forecastId = 0;
+ nullable int16u activeSlotNumber = 1;
+ epoch_s startTime = 2;
+ epoch_s endTime = 3;
+ optional nullable epoch_s earliestStartTime = 4;
+ optional epoch_s latestEndTime = 5;
+ boolean isPauseable = 6;
+ SlotStruct slots[] = 7;
+ }
+
+ struct ConstraintsStruct {
+ epoch_s startTime = 0;
+ elapsed_s duration = 1;
+ optional power_mw nominalPower = 2;
+ optional energy_mwh maximumEnergy = 3;
+ optional int8s loadControl = 4;
+ }
+
+ struct PowerAdjustStruct {
+ power_mw minPower = 0;
+ power_mw maxPower = 1;
+ elapsed_s minDuration = 2;
+ elapsed_s maxDuration = 3;
+ }
+
+ struct SlotAdjustmentStruct {
+ int8u slotIndex = 0;
+ power_mw nominalPower = 1;
+ elapsed_s duration = 2;
+ }
+
+ info event PowerAdjustStart = 0 {
+ }
+
+ info event PowerAdjustEnd = 1 {
+ CauseEnum cause = 0;
+ elapsed_s duration = 1;
+ energy_mwh energyUse = 2;
+ }
+
+ info event Paused = 2 {
+ }
+
+ info event Resumed = 3 {
+ }
+
+ readonly attribute ESATypeEnum ESAType = 0;
+ readonly attribute boolean ESACanGenerate = 1;
+ readonly attribute ESAStateEnum ESAState = 2;
+ readonly attribute power_mw absMinPower = 3;
+ readonly attribute power_mw absMaxPower = 4;
+ readonly attribute optional nullable PowerAdjustStruct powerAdjustmentCapability[] = 5;
+ readonly attribute optional nullable ForecastStruct forecast = 6;
+ 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 PowerAdjustRequestRequest {
+ power_mw power = 0;
+ elapsed_s duration = 1;
+ }
+
+ request struct StartTimeAdjustRequestRequest {
+ epoch_s requestedStartTime = 0;
+ }
+
+ request struct PauseRequestRequest {
+ elapsed_s duration = 0;
+ }
+
+ request struct ModifyForecastRequestRequest {
+ int32u forecastId = 0;
+ SlotAdjustmentStruct slotAdjustments[] = 1;
+ }
+
+ request struct RequestConstraintBasedForecastRequest {
+ ConstraintsStruct constraints[] = 0;
+ }
+
+ /** Allows a client to request an adjustment in the power consumption of an ESA for a specified duration. */
+ command PowerAdjustRequest(PowerAdjustRequestRequest): DefaultSuccess = 0;
+ /** Allows a client to cancel an ongoing PowerAdjustmentRequest operation. */
+ command CancelPowerAdjustRequest(): DefaultSuccess = 1;
+ /** Allows a client to adjust the start time of a Forecast sequence that has not yet started operation (i.e. where the current Forecast StartTime is in the future). */
+ command StartTimeAdjustRequest(StartTimeAdjustRequestRequest): DefaultSuccess = 2;
+ /** Allows a client to temporarily pause an operation and reduce the ESAs energy demand. */
+ command PauseRequest(PauseRequestRequest): DefaultSuccess = 3;
+ /** Allows a client to cancel the PauseRequest command and enable earlier resumption of operation. */
+ command ResumeRequest(): DefaultSuccess = 4;
+ /** Allows a client to modify a Forecast within the limits allowed by the ESA. */
+ command ModifyForecastRequest(ModifyForecastRequestRequest): DefaultSuccess = 5;
+ /** Allows a client to ask the ESA to recompute its Forecast based on power and time constraints. */
+ command RequestConstraintBasedForecast(RequestConstraintBasedForecastRequest): DefaultSuccess = 6;
+}
+
/** Electric Vehicle Supply Equipment (EVSE) is equipment used to charge an Electric Vehicle (EV) or Plug-In Hybrid Electric Vehicle. This cluster provides an interface to the functionality of Electric Vehicle Supply Equipment (EVSE) management. */
provisional cluster EnergyEvse = 153 {
revision 2;
@@ -4342,6 +4648,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -4403,6 +4719,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -4412,6 +4732,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -4450,6 +4775,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -4505,6 +4886,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -4536,14 +4931,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
@@ -6316,7 +6742,8 @@ internal cluster UnitTesting = 4294048773 {
int8u fillCharacter = 2;
}
- /** Simple command without any parameters and without a specific response */
+ /** Simple command without any parameters and without a specific response.
+ To aid in unit testing, this command will re-initialize attribute storage to defaults. */
command Test(): DefaultSuccess = 0;
/** Simple command without any parameters and without a specific response not handled by the server */
command TestNotHandled(): DefaultSuccess = 1;
@@ -6628,6 +7055,9 @@ endpoint 0 {
ram attribute lastNetworkingStatus;
ram attribute lastNetworkID;
ram attribute lastConnectErrorValue;
+ callback attribute supportedWiFiBands;
+ callback attribute supportedThreadFeatures;
+ callback attribute threadVersion;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
@@ -6968,39 +7398,6 @@ endpoint 1 {
handle command AddGroupIfIdentifying;
}
- server cluster Scenes {
- ram attribute nameSupport default = 0x80;
- ram attribute lastConfiguredBy;
- ram attribute sceneTableSize default = 16;
- callback attribute fabricSceneInfo;
- callback attribute generatedCommandList;
- callback attribute acceptedCommandList;
- callback attribute eventList;
- callback attribute attributeList;
- ram attribute featureMap default = 15;
- ram attribute clusterRevision default = 5;
-
- handle command AddScene;
- handle command AddSceneResponse;
- handle command ViewScene;
- handle command ViewSceneResponse;
- handle command RemoveScene;
- handle command RemoveSceneResponse;
- handle command RemoveAllScenes;
- handle command RemoveAllScenesResponse;
- handle command StoreScene;
- handle command StoreSceneResponse;
- handle command RecallScene;
- handle command GetSceneMembership;
- handle command GetSceneMembershipResponse;
- handle command EnhancedAddScene;
- handle command EnhancedAddSceneResponse;
- handle command EnhancedViewScene;
- handle command EnhancedViewSceneResponse;
- handle command CopyScene;
- handle command CopySceneResponse;
- }
-
server cluster OnOff {
persist attribute onOff default = 0x00;
ram attribute globalSceneControl default = 0x01;
@@ -7392,6 +7789,40 @@ endpoint 1 {
handle command Pause;
handle command Resume;
handle command OperationalCommandResponse;
+ handle command GoHome;
+ }
+
+ server cluster ScenesManagement {
+ ram attribute nameSupport default = 0x80;
+ ram attribute lastConfiguredBy;
+ ram attribute sceneTableSize default = 16;
+ callback attribute fabricSceneInfo;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 15;
+ ram attribute clusterRevision default = 5;
+
+ handle command AddScene;
+ handle command AddSceneResponse;
+ handle command ViewScene;
+ handle command ViewSceneResponse;
+ handle command RemoveScene;
+ handle command RemoveSceneResponse;
+ handle command RemoveAllScenes;
+ handle command RemoveAllScenesResponse;
+ handle command StoreScene;
+ handle command StoreSceneResponse;
+ handle command RecallScene;
+ handle command GetSceneMembership;
+ handle command GetSceneMembershipResponse;
+ handle command EnhancedAddScene;
+ handle command EnhancedAddSceneResponse;
+ handle command EnhancedViewScene;
+ handle command EnhancedViewSceneResponse;
+ handle command CopyScene;
+ handle command CopySceneResponse;
}
server cluster HepaFilterMonitoring {
@@ -7426,6 +7857,53 @@ endpoint 1 {
handle command ResetCondition;
}
+ server cluster BooleanStateConfiguration {
+ emits event AlarmsStateChanged;
+ emits event SensorFault;
+ callback attribute currentSensitivityLevel;
+ ram attribute supportedSensitivityLevels default = 3;
+ ram attribute defaultSensitivityLevel default = 2;
+ ram attribute alarmsActive;
+ ram attribute alarmsSuppressed;
+ persist attribute alarmsEnabled;
+ ram attribute alarmsSupported default = 0x03;
+ ram attribute sensorFault default = 0;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 0x0F;
+ ram attribute clusterRevision default = 1;
+
+ handle command SuppressAlarm;
+ handle command EnableDisableAlarm;
+ }
+
+ server cluster ValveConfigurationAndControl {
+ emits event ValveStateChanged;
+ emits event ValveFault;
+ ram attribute openDuration;
+ persist attribute defaultOpenDuration;
+ ram attribute autoCloseTime;
+ callback attribute remainingDuration;
+ ram attribute currentState;
+ ram attribute targetState;
+ ram attribute currentLevel;
+ ram attribute targetLevel;
+ persist attribute defaultOpenLevel default = 100;
+ ram attribute valveFault default = 0;
+ ram attribute levelStep default = 1;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 3;
+ ram attribute clusterRevision default = 1;
+
+ handle command Open;
+ handle command Close;
+ }
+
server cluster ElectricalEnergyMeasurement {
emits event CumulativeEnergyMeasured;
emits event PeriodicEnergyMeasured;
@@ -7442,25 +7920,53 @@ endpoint 1 {
ram attribute clusterRevision default = 1;
}
+ server cluster DeviceEnergyManagement {
+ emits event PowerAdjustStart;
+ emits event PowerAdjustEnd;
+ emits event Paused;
+ emits event Resumed;
+ callback attribute ESAType;
+ callback attribute ESACanGenerate;
+ callback attribute ESAState;
+ callback attribute absMinPower;
+ callback attribute absMaxPower;
+ callback attribute powerAdjustmentCapability;
+ callback attribute forecast;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ callback attribute featureMap;
+ ram attribute clusterRevision default = 2;
+
+ handle command PowerAdjustRequest;
+ handle command CancelPowerAdjustRequest;
+ handle command StartTimeAdjustRequest;
+ handle command PauseRequest;
+ handle command ResumeRequest;
+ handle command ModifyForecastRequest;
+ handle command RequestConstraintBasedForecast;
+ }
+
server cluster EnergyEvse {
- callback attribute state default = 0;
- callback attribute supplyState default = 0;
- callback attribute faultState default = 0;
- callback attribute chargingEnabledUntil default = 0;
- callback attribute dischargingEnabledUntil default = 0;
- callback attribute circuitCapacity default = 0;
- callback attribute minimumChargeCurrent default = 6000;
- callback attribute maximumChargeCurrent default = 0;
- callback attribute maximumDischargeCurrent default = 0;
- callback attribute userMaximumChargeCurrent default = 0;
- callback attribute randomizationDelayWindow default = 600;
+ callback attribute state;
+ callback attribute supplyState;
+ callback attribute faultState;
+ callback attribute chargingEnabledUntil;
+ callback attribute dischargingEnabledUntil;
+ callback attribute circuitCapacity;
+ callback attribute minimumChargeCurrent;
+ callback attribute maximumChargeCurrent;
+ callback attribute maximumDischargeCurrent;
+ callback attribute userMaximumChargeCurrent;
+ callback attribute randomizationDelayWindow;
callback attribute numberOfWeeklyTargets default = 0;
callback attribute numberOfDailyTargets default = 1;
callback attribute nextChargeStartTime;
callback attribute nextChargeTargetTime;
callback attribute nextChargeRequiredEnergy;
callback attribute nextChargeTargetSoC;
- callback attribute approximateEVEfficiency default = 0xFFFF;
+ callback attribute approximateEVEfficiency;
callback attribute stateOfCharge;
callback attribute batteryCapacity;
callback attribute vehicleID;
@@ -7472,7 +7978,7 @@ endpoint 1 {
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
- ram attribute featureMap default = 0;
+ callback attribute featureMap;
ram attribute clusterRevision default = 2;
handle command GetTargetsResponse;
@@ -7578,6 +8084,19 @@ endpoint 1 {
ram attribute minSetpointDeadBand default = 0x19;
ram attribute controlSequenceOfOperation default = 0x04;
ram attribute systemMode default = 0x01;
+ callback attribute presetTypes;
+ callback attribute scheduleTypes;
+ ram attribute numberOfPresets default = 0;
+ ram attribute numberOfSchedules default = 0;
+ ram attribute numberOfScheduleTransitionPerDay default = 0xFF;
+ ram attribute activePresetHandle;
+ ram attribute activeScheduleHandle;
+ callback attribute presets;
+ callback attribute schedules;
+ ram attribute presetsSchedulesEditable;
+ ram attribute temperatureSetpointHoldPolicy default = 0;
+ ram attribute setpointHoldExpiryTimestamp;
+ callback attribute queuedPreset;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
@@ -7586,6 +8105,13 @@ endpoint 1 {
ram attribute clusterRevision default = 6;
handle command SetpointRaiseLower;
+ handle command SetActiveScheduleRequest;
+ handle command SetActivePresetRequest;
+ handle command StartPresetsSchedulesEditRequest;
+ handle command CancelPresetsSchedulesEditRequest;
+ handle command CommitPresetsSchedulesRequest;
+ handle command CancelSetActivePresetRequest;
+ handle command SetTemperatureSetpointHoldPolicy;
}
server cluster FanControl {
@@ -8143,39 +8669,6 @@ endpoint 2 {
handle command AddGroupIfIdentifying;
}
- server cluster Scenes {
- ram attribute nameSupport default = 0x80;
- ram attribute lastConfiguredBy;
- ram attribute sceneTableSize default = 16;
- callback attribute fabricSceneInfo;
- callback attribute generatedCommandList;
- callback attribute acceptedCommandList;
- callback attribute eventList;
- callback attribute attributeList;
- ram attribute featureMap default = 15;
- ram attribute clusterRevision default = 5;
-
- handle command AddScene;
- handle command AddSceneResponse;
- handle command ViewScene;
- handle command ViewSceneResponse;
- handle command RemoveScene;
- handle command RemoveSceneResponse;
- handle command RemoveAllScenes;
- handle command RemoveAllScenesResponse;
- handle command StoreScene;
- handle command StoreSceneResponse;
- handle command RecallScene;
- handle command GetSceneMembership;
- handle command GetSceneMembershipResponse;
- handle command EnhancedAddScene;
- handle command EnhancedAddSceneResponse;
- handle command EnhancedViewScene;
- handle command EnhancedViewSceneResponse;
- handle command CopyScene;
- handle command CopySceneResponse;
- }
-
server cluster OnOff {
ram attribute onOff default = 0x00;
ram attribute globalSceneControl default = 1;
@@ -8227,6 +8720,39 @@ endpoint 2 {
ram attribute clusterRevision default = 2;
}
+ server cluster ScenesManagement {
+ ram attribute nameSupport default = 0x80;
+ ram attribute lastConfiguredBy;
+ ram attribute sceneTableSize default = 16;
+ callback attribute fabricSceneInfo;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 15;
+ ram attribute clusterRevision default = 5;
+
+ handle command AddScene;
+ handle command AddSceneResponse;
+ handle command ViewScene;
+ handle command ViewSceneResponse;
+ handle command RemoveScene;
+ handle command RemoveSceneResponse;
+ handle command RemoveAllScenes;
+ handle command RemoveAllScenesResponse;
+ handle command StoreScene;
+ handle command StoreSceneResponse;
+ handle command RecallScene;
+ handle command GetSceneMembership;
+ handle command GetSceneMembershipResponse;
+ handle command EnhancedAddScene;
+ handle command EnhancedAddSceneResponse;
+ handle command EnhancedViewScene;
+ handle command EnhancedViewSceneResponse;
+ handle command CopyScene;
+ handle command CopySceneResponse;
+ }
+
server cluster OccupancySensing {
ram attribute occupancy;
ram attribute occupancySensorType;
diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
index 0c14d72717e091..45499b5d44ce3e 100644
--- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
+++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
@@ -17,12 +17,6 @@
}
],
"package": [
- {
- "pathRelativity": "relativeToZap",
- "path": "../../../src/app/zap-templates/app-templates.json",
- "type": "gen-templates-json",
- "version": "chip-v1"
- },
{
"pathRelativity": "relativeToZap",
"path": "../../../src/app/zap-templates/zcl/zcl-with-test-extensions.json",
@@ -30,6 +24,12 @@
"category": "matter",
"version": 1,
"description": "Matter SDK ZCL data with some extensions"
+ },
+ {
+ "pathRelativity": "relativeToZap",
+ "path": "../../../src/app/zap-templates/app-templates.json",
+ "type": "gen-templates-json",
+ "version": "chip-v1"
}
],
"endpointTypes": [
@@ -2562,6 +2562,54 @@
"maxInterval": 65534,
"reportableChange": 0
},
+ {
+ "name": "SupportedWiFiBands",
+ "code": 8,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "SupportedThreadFeatures",
+ "code": 9,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ThreadCapabilitiesBitmap",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ThreadVersion",
+ "code": 10,
+ "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,
@@ -6464,8 +6512,8 @@
]
},
{
- "name": "Scenes",
- "code": 5,
+ "name": "Scenes Management",
+ "code": 98,
"mfgCode": null,
"define": "SCENES_CLUSTER",
"side": "server",
@@ -8427,7 +8475,7 @@
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -8459,7 +8507,7 @@
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -8475,7 +8523,7 @@
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -8491,7 +8539,7 @@
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -8507,7 +8555,7 @@
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -11214,6 +11262,14 @@
"source": "server",
"isIncoming": 0,
"isEnabled": 1
+ },
+ {
+ "name": "GoHome",
+ "code": 128,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
}
],
"attributes": [
@@ -11804,89 +11860,155 @@
]
},
{
- "name": "Electrical Energy Measurement",
- "code": 145,
+ "name": "Boolean State Configuration",
+ "code": 128,
"mfgCode": null,
- "define": "ELECTRICAL_ENERGY_MEASUREMENT_CLUSTER",
+ "define": "BOOLEAN_STATE_CONFIGURATION_CLUSTER",
"side": "server",
"enabled": 1,
"apiMaturity": "provisional",
+ "commands": [
+ {
+ "name": "SuppressAlarm",
+ "code": 0,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "EnableDisableAlarm",
+ "code": 1,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ }
+ ],
"attributes": [
{
- "name": "Accuracy",
+ "name": "CurrentSensitivityLevel",
"code": 0,
"mfgCode": null,
"side": "server",
- "type": "MeasurementAccuracyStruct",
+ "type": "int8u",
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": null,
+ "defaultValue": "2",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "CumulativeEnergyImported",
+ "name": "SupportedSensitivityLevels",
"code": 1,
"mfgCode": null,
"side": "server",
- "type": "EnergyMeasurementStruct",
+ "type": "int8u",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": null,
+ "defaultValue": "3",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "CumulativeEnergyExported",
+ "name": "DefaultSensitivityLevel",
"code": 2,
"mfgCode": null,
"side": "server",
- "type": "EnergyMeasurementStruct",
+ "type": "int8u",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": null,
+ "defaultValue": "2",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "PeriodicEnergyImported",
+ "name": "AlarmsActive",
"code": 3,
"mfgCode": null,
"side": "server",
- "type": "EnergyMeasurementStruct",
+ "type": "AlarmModeBitmap",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": null,
+ "defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "PeriodicEnergyExported",
+ "name": "AlarmsSuppressed",
"code": 4,
"mfgCode": null,
"side": "server",
- "type": "EnergyMeasurementStruct",
+ "type": "AlarmModeBitmap",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": null,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AlarmsEnabled",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "AlarmModeBitmap",
+ "included": 1,
+ "storageOption": "NVM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AlarmsSupported",
+ "code": 6,
+ "mfgCode": null,
+ "side": "server",
+ "type": "AlarmModeBitmap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x03",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "SensorFault",
+ "code": 7,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SensorFaultBitmap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -11966,7 +12088,7 @@
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0x000F",
+ "defaultValue": "0x0F",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
@@ -11991,14 +12113,14 @@
],
"events": [
{
- "name": "CumulativeEnergyMeasured",
+ "name": "AlarmsStateChanged",
"code": 0,
"mfgCode": null,
"side": "server",
"included": 1
},
{
- "name": "PeriodicEnergyMeasured",
+ "name": "SensorFault",
"code": 1,
"mfgCode": null,
"side": "server",
@@ -12007,73 +12129,25 @@
]
},
{
- "name": "Energy EVSE",
- "code": 153,
+ "name": "Valve Configuration and Control",
+ "code": 129,
"mfgCode": null,
- "define": "ENERGY_EVSE_CLUSTER",
+ "define": "VALVE_CONFIGURATION_AND_CONTROL_CLUSTER",
"side": "server",
"enabled": 1,
"apiMaturity": "provisional",
"commands": [
{
- "name": "GetTargetsResponse",
+ "name": "Open",
"code": 0,
"mfgCode": null,
- "source": "server",
- "isIncoming": 0,
- "isEnabled": 1
- },
- {
- "name": "Disable",
- "code": 1,
- "mfgCode": null,
- "source": "client",
- "isIncoming": 1,
- "isEnabled": 1
- },
- {
- "name": "EnableCharging",
- "code": 2,
- "mfgCode": null,
- "source": "client",
- "isIncoming": 1,
- "isEnabled": 1
- },
- {
- "name": "EnableDischarging",
- "code": 3,
- "mfgCode": null,
- "source": "client",
- "isIncoming": 1,
- "isEnabled": 1
- },
- {
- "name": "StartDiagnostics",
- "code": 4,
- "mfgCode": null,
- "source": "client",
- "isIncoming": 1,
- "isEnabled": 1
- },
- {
- "name": "SetTargets",
- "code": 5,
- "mfgCode": null,
- "source": "client",
- "isIncoming": 1,
- "isEnabled": 1
- },
- {
- "name": "GetTargets",
- "code": 6,
- "mfgCode": null,
"source": "client",
"isIncoming": 1,
"isEnabled": 1
},
{
- "name": "ClearTargets",
- "code": 7,
+ "name": "Close",
+ "code": 1,
"mfgCode": null,
"source": "client",
"isIncoming": 1,
@@ -12082,91 +12156,966 @@
],
"attributes": [
{
- "name": "State",
+ "name": "OpenDuration",
"code": 0,
"mfgCode": null,
"side": "server",
- "type": "StateEnum",
+ "type": "elapsed_s",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "SupplyState",
+ "name": "DefaultOpenDuration",
"code": 1,
"mfgCode": null,
"side": "server",
- "type": "SupplyStateEnum",
+ "type": "elapsed_s",
"included": 1,
- "storageOption": "External",
+ "storageOption": "NVM",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "FaultState",
+ "name": "AutoCloseTime",
"code": 2,
"mfgCode": null,
"side": "server",
- "type": "FaultStateEnum",
+ "type": "epoch_us",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "ChargingEnabledUntil",
+ "name": "RemainingDuration",
"code": 3,
"mfgCode": null,
"side": "server",
- "type": "epoch_s",
+ "type": "elapsed_s",
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "DischargingEnabledUntil",
+ "name": "CurrentState",
"code": 4,
"mfgCode": null,
"side": "server",
- "type": "epoch_s",
+ "type": "ValveStateEnum",
"included": 1,
- "storageOption": "External",
+ "storageOption": "RAM",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
- "name": "CircuitCapacity",
+ "name": "TargetState",
"code": 5,
"mfgCode": null,
"side": "server",
- "type": "amperage_ma",
+ "type": "ValveStateEnum",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "CurrentLevel",
+ "code": 6,
+ "mfgCode": null,
+ "side": "server",
+ "type": "percent",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "TargetLevel",
+ "code": 7,
+ "mfgCode": null,
+ "side": "server",
+ "type": "percent",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "DefaultOpenLevel",
+ "code": 8,
+ "mfgCode": null,
+ "side": "server",
+ "type": "percent",
+ "included": 1,
+ "storageOption": "NVM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "100",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ValveFault",
+ "code": 9,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ValveFaultBitmap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LevelStep",
+ "code": 10,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ }
+ ],
+ "events": [
+ {
+ "name": "ValveStateChanged",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "ValveFault",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ }
+ ]
+ },
+ {
+ "name": "Electrical Energy Measurement",
+ "code": 145,
+ "mfgCode": null,
+ "define": "ELECTRICAL_ENERGY_MEASUREMENT_CLUSTER",
+ "side": "server",
+ "enabled": 1,
+ "apiMaturity": "provisional",
+ "attributes": [
+ {
+ "name": "Accuracy",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "MeasurementAccuracyStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "CumulativeEnergyImported",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "EnergyMeasurementStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "CumulativeEnergyExported",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "EnergyMeasurementStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PeriodicEnergyImported",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "type": "EnergyMeasurementStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PeriodicEnergyExported",
+ "code": 4,
+ "mfgCode": null,
+ "side": "server",
+ "type": "EnergyMeasurementStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": "0x000F",
+ "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
+ }
+ ],
+ "events": [
+ {
+ "name": "CumulativeEnergyMeasured",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "PeriodicEnergyMeasured",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ }
+ ]
+ },
+ {
+ "name": "Device Energy Management",
+ "code": 152,
+ "mfgCode": null,
+ "define": "DEVICE_ENERGY_MANAGEMENT_CLUSTER",
+ "side": "server",
+ "enabled": 1,
+ "apiMaturity": "provisional",
+ "commands": [
+ {
+ "name": "PowerAdjustRequest",
+ "code": 0,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "CancelPowerAdjustRequest",
+ "code": 1,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "StartTimeAdjustRequest",
+ "code": 2,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "PauseRequest",
+ "code": 3,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "ResumeRequest",
+ "code": 4,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "ModifyForecastRequest",
+ "code": 5,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "RequestConstraintBasedForecast",
+ "code": 6,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ }
+ ],
+ "attributes": [
+ {
+ "name": "ESAType",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ESATypeEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ESACanGenerate",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ESAState",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ESAStateEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AbsMinPower",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AbsMaxPower",
+ "code": 4,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PowerAdjustmentCapability",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Forecast",
+ "code": 6,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ForecastStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": null,
+ "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": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "2",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ }
+ ],
+ "events": [
+ {
+ "name": "PowerAdjustStart",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "PowerAdjustEnd",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "Paused",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "Resumed",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ }
+ ]
+ },
+ {
+ "name": "Energy EVSE",
+ "code": 153,
+ "mfgCode": null,
+ "define": "ENERGY_EVSE_CLUSTER",
+ "side": "server",
+ "enabled": 1,
+ "apiMaturity": "provisional",
+ "commands": [
+ {
+ "name": "GetTargetsResponse",
+ "code": 0,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "Disable",
+ "code": 1,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "EnableCharging",
+ "code": 2,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "EnableDischarging",
+ "code": 3,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "StartDiagnostics",
+ "code": 4,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "SetTargets",
+ "code": 5,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "GetTargets",
+ "code": 6,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "ClearTargets",
+ "code": 7,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ }
+ ],
+ "attributes": [
+ {
+ "name": "State",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "StateEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "SupplyState",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SupplyStateEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "FaultState",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "FaultStateEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ChargingEnabledUntil",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "type": "epoch_s",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "DischargingEnabledUntil",
+ "code": 4,
+ "mfgCode": null,
+ "side": "server",
+ "type": "epoch_s",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "CircuitCapacity",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
"included": 1,
"storageOption": "External",
"singleton": 0,
@@ -12552,7 +13501,7 @@
"side": "server",
"type": "bitmap32",
"included": 1,
- "storageOption": "RAM",
+ "storageOption": "External",
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
@@ -13629,6 +14578,78 @@
"source": "client",
"isIncoming": 1,
"isEnabled": 1
+ },
+ {
+ "name": "GetRelayStatusLogResponse",
+ "code": 1,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 0
+ },
+ {
+ "name": "GetRelayStatusLog",
+ "code": 4,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "SetActiveScheduleRequest",
+ "code": 5,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "SetActivePresetRequest",
+ "code": 6,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "StartPresetsSchedulesEditRequest",
+ "code": 7,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "CancelPresetsSchedulesEditRequest",
+ "code": 8,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "CommitPresetsSchedulesRequest",
+ "code": 9,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "CancelSetActivePresetRequest",
+ "code": 10,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
+ },
+ {
+ "name": "SetTemperatureSetpointHoldPolicy",
+ "code": 11,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 0
}
],
"attributes": [
@@ -13856,6 +14877,214 @@
"maxInterval": 65344,
"reportableChange": 0
},
+ {
+ "name": "PresetTypes",
+ "code": 72,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ScheduleTypes",
+ "code": 73,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "NumberOfPresets",
+ "code": 74,
+ "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": "NumberOfSchedules",
+ "code": 75,
+ "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": "NumberOfScheduleTransitionPerDay",
+ "code": 77,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFF",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ActivePresetHandle",
+ "code": 78,
+ "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": "ActiveScheduleHandle",
+ "code": 79,
+ "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": "Presets",
+ "code": 80,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Schedules",
+ "code": 81,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PresetsSchedulesEditable",
+ "code": 82,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "TemperatureSetpointHoldPolicy",
+ "code": 83,
+ "mfgCode": null,
+ "side": "server",
+ "type": "TemperatureSetpointHoldPolicyBitmap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "SetpointHoldExpiryTimestamp",
+ "code": 84,
+ "mfgCode": null,
+ "side": "server",
+ "type": "epoch_s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "QueuedPreset",
+ "code": 85,
+ "mfgCode": null,
+ "side": "server",
+ "type": "QueuedPresetStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
{
"name": "GeneratedCommandList",
"code": 65528,
@@ -21220,8 +22449,8 @@
]
},
{
- "name": "Scenes",
- "code": 5,
+ "name": "Scenes Management",
+ "code": 98,
"mfgCode": null,
"define": "SCENES_CLUSTER",
"side": "server",
diff --git a/examples/all-clusters-app/all-clusters-common/include/operational-state-delegate-impl.h b/examples/all-clusters-app/all-clusters-common/include/operational-state-delegate-impl.h
index c8d63c2bb6efc2..0bcb76f324a1da 100644
--- a/examples/all-clusters-app/all-clusters-common/include/operational-state-delegate-impl.h
+++ b/examples/all-clusters-app/all-clusters-common/include/operational-state-delegate-impl.h
@@ -111,38 +111,11 @@ class OperationalStateDelegate : public GenericOperationalStateDelegateImpl
}
};
-void Shutdown();
-
-} // namespace OperationalState
-
-namespace RvcOperationalState {
-
-// This is an application level delegate to handle operational state commands according to the specific business logic.
-class RvcOperationalStateDelegate : public OperationalState::GenericOperationalStateDelegateImpl
-{
-private:
- const OperationalState::GenericOperationalState rvcOpStateList[7] = {
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kPaused)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kError)),
- OperationalState::GenericOperationalState(
- to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kSeekingCharger)),
- OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kCharging)),
- OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kDocked)),
- };
-
-public:
- RvcOperationalStateDelegate()
- {
- GenericOperationalStateDelegateImpl::mOperationalStateList =
- Span(rvcOpStateList);
- }
-};
+Instance * GetOperationalStateInstance();
void Shutdown();
-} // namespace RvcOperationalState
+} // namespace OperationalState
} // namespace Clusters
} // namespace app
} // namespace chip
diff --git a/examples/all-clusters-app/ameba/main/include/OperationalStateManager.h b/examples/all-clusters-app/all-clusters-common/include/rvc-operational-state-delegate-impl.h
similarity index 64%
rename from examples/all-clusters-app/ameba/main/include/OperationalStateManager.h
rename to examples/all-clusters-app/all-clusters-common/include/rvc-operational-state-delegate-impl.h
index 2183e92078e6c7..89a3e69c5b8bed 100644
--- a/examples/all-clusters-app/ameba/main/include/OperationalStateManager.h
+++ b/examples/all-clusters-app/all-clusters-common/include/rvc-operational-state-delegate-impl.h
@@ -23,20 +23,34 @@
#include
#include
-void getOperationalStateSet(u8 state);
-
namespace chip {
namespace app {
namespace Clusters {
-namespace OperationalState {
-
-Instance * GetOperationalStateInstance();
+namespace RvcOperationalState {
// This is an application level delegate to handle operational state commands according to the specific business logic.
-class GenericOperationalStateDelegateImpl : public Delegate
+class RvcOperationalStateDelegate : public Delegate
{
+private:
+ const Clusters::OperationalState::GenericOperationalState rvcOpStateList[7] = {
+ OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped)),
+ OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning)),
+ OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kPaused)),
+ OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kError)),
+ OperationalState::GenericOperationalState(
+ to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kSeekingCharger)),
+ OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kCharging)),
+ OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kDocked)),
+ };
+
+ Span mOperationalStateList =
+ Span(rvcOpStateList);
+ Span mOperationalPhaseList;
+
public:
+ RvcOperationalStateDelegate() {}
+
/**
* Get the countdown time. This attribute is not used in this application.
* @return The current countdown time.
@@ -51,19 +65,15 @@ class GenericOperationalStateDelegateImpl : public Delegate
* @param index The index of the state, with 0 representing the first state.
* @param operationalState The GenericOperationalState is filled.
*/
- CHIP_ERROR GetOperationalStateAtIndex(size_t index, GenericOperationalState & operationalState) override;
+ CHIP_ERROR GetOperationalStateAtIndex(size_t index, OperationalState::GenericOperationalState & operationalState) override;
/**
- * Fills in the provided MutableCharSpan with the phase at index `index` if there is one,
+ * Fills in the provided GenericOperationalPhase with the phase at index `index` if there is one,
* or returns CHIP_ERROR_NOT_FOUND if the index is out of range for the list of phases.
- *
- * If CHIP_ERROR_NOT_FOUND is returned for index 0, that indicates that the PhaseList attribute is null
- * (there are no phases defined at all).
- *
* Note: This is used by the SDK to populate the phase list attribute. If the contents of this list changes, the
* device SHALL call the Instance's ReportPhaseListChange method to report that this attribute has changed.
* @param index The index of the phase, with 0 representing the first phase.
- * @param operationalPhase The MutableCharSpan is filled.
+ * @param operationalPhase The GenericOperationalPhase is filled.
*/
CHIP_ERROR GetOperationalPhaseAtIndex(size_t index, MutableCharSpan & operationalPhase) override;
@@ -72,82 +82,37 @@ class GenericOperationalStateDelegateImpl : public Delegate
* Handle Command Callback in application: Pause
* @param[out] get operational error after callback.
*/
- void HandlePauseStateCallback(GenericOperationalError & err) override;
+ void HandlePauseStateCallback(OperationalState::GenericOperationalError & err) override;
/**
* Handle Command Callback in application: Resume
* @param[out] get operational error after callback.
*/
- void HandleResumeStateCallback(GenericOperationalError & err) override;
+ void HandleResumeStateCallback(OperationalState::GenericOperationalError & err) override;
/**
* Handle Command Callback in application: Start
* @param[out] get operational error after callback.
*/
- void HandleStartStateCallback(GenericOperationalError & err) override;
+ void HandleStartStateCallback(OperationalState::GenericOperationalError & err) override;
/**
* Handle Command Callback in application: Stop
* @param[out] get operational error after callback.
*/
- void HandleStopStateCallback(GenericOperationalError & err) override;
-
-protected:
- Span mOperationalStateList;
- Span mOperationalPhaseList;
-};
-
-// This is an application level delegate to handle operational state commands according to the specific business logic.
-class OperationalStateDelegate : public GenericOperationalStateDelegateImpl
-{
-private:
- const GenericOperationalState opStateList[4] = {
- GenericOperationalState(to_underlying(OperationalStateEnum::kStopped)),
- GenericOperationalState(to_underlying(OperationalStateEnum::kRunning)),
- GenericOperationalState(to_underlying(OperationalStateEnum::kPaused)),
- GenericOperationalState(to_underlying(OperationalStateEnum::kError)),
- };
+ void HandleStopStateCallback(OperationalState::GenericOperationalError & err) override;
-public:
- OperationalStateDelegate()
- {
- GenericOperationalStateDelegateImpl::mOperationalStateList = Span(opStateList);
- }
+ /**
+ * Handle the GoHome command.
+ * @param err
+ */
+ void HandleGoHomeCommandCallback(OperationalState::GenericOperationalError & err) override;
};
void Shutdown();
-} // namespace OperationalState
-
-namespace RvcOperationalState {
-
Instance * GetRvcOperationalStateInstance();
-// This is an application level delegate to handle operational state commands according to the specific business logic.
-class RvcOperationalStateDelegate : public OperationalState::GenericOperationalStateDelegateImpl
-{
-private:
- const OperationalState::GenericOperationalState rvcOpStateList[7] = {
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kPaused)),
- OperationalState::GenericOperationalState(to_underlying(OperationalState::OperationalStateEnum::kError)),
- OperationalState::GenericOperationalState(
- to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kSeekingCharger)),
- OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kCharging)),
- OperationalState::GenericOperationalState(to_underlying(Clusters::RvcOperationalState::OperationalStateEnum::kDocked)),
- };
-
-public:
- RvcOperationalStateDelegate()
- {
- GenericOperationalStateDelegateImpl::mOperationalStateList =
- Span(rvcOpStateList);
- }
-};
-
-void Shutdown();
-
} // namespace RvcOperationalState
} // namespace Clusters
} // namespace app
diff --git a/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp b/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp
index c78f34e9a8f31f..9297cd79960b89 100644
--- a/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp
@@ -1,3 +1,20 @@
+/*
+ *
+ * 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
+ *
+ * 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
using namespace chip::app::Clusters;
diff --git a/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp
new file mode 100644
index 00000000000000..36716ec69ce52e
--- /dev/null
+++ b/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp
@@ -0,0 +1,49 @@
+/*
+ *
+ * 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
+ *
+ * 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
+#include
+
+#include
+
+using namespace chip;
+using namespace chip::app::Clusters::BooleanStateConfiguration;
+using namespace chip::DeviceLayer;
+
+bool HandleBooleanStateConfigurationTestEventTrigger(uint64_t eventTrigger)
+{
+ BooleanStateConfigurationTrigger trigger = static_cast(eventTrigger);
+
+ switch (trigger)
+ {
+ case BooleanStateConfigurationTrigger::kSensorTrigger:
+ ChipLogProgress(Support, "[BooleanStateConfiguration-Test-Event] => Trigger sensor");
+ SetAllEnabledAlarmsActive(1);
+ break;
+
+ case BooleanStateConfigurationTrigger::kSensorUntrigger:
+ ChipLogProgress(Support, "[BooleanStateConfiguration-Test-Event] => Untrigger sensor");
+ ClearAllAlarms(1);
+ break;
+
+ default:
+
+ return false;
+ }
+
+ return true;
+}
diff --git a/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp
new file mode 100644
index 00000000000000..385c1cfa43c8ee
--- /dev/null
+++ b/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp
@@ -0,0 +1,73 @@
+/*
+ *
+ * Copyright (c) 2023 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
+
+using namespace chip;
+using namespace chip::app;
+using namespace chip::app::Clusters;
+using namespace chip::app::Clusters::DeviceEnergyManagement;
+
+static std::unique_ptr gDelegate;
+static std::unique_ptr gInstance;
+
+void emberAfDeviceEnergyManagementClusterInitCallback(chip::EndpointId endpointId)
+{
+ VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
+ VerifyOrDie(gInstance == nullptr);
+
+ CHIP_ERROR err;
+
+ if (gDelegate || gInstance)
+ {
+ ChipLogError(AppServer, "DEM Instance or Delegate already exist.");
+ return;
+ }
+
+ gDelegate = std::make_unique();
+ if (!gDelegate)
+ {
+ ChipLogError(AppServer, "Failed to allocate memory for DeviceEnergyManagementDelegate");
+ return;
+ }
+
+ /* Manufacturer may optionally not support all features, commands & attributes */
+ gInstance = std::make_unique(
+ endpointId, *gDelegate,
+ BitMask(
+ DeviceEnergyManagement::Feature::kPowerForecastReporting, DeviceEnergyManagement::Feature::kStateForecastReporting,
+ DeviceEnergyManagement::Feature::kPowerAdjustment, DeviceEnergyManagement::Feature::kForecastAdjustment),
+ BitMask(OptionalCommands::kSupportsModifyForecastRequest,
+ OptionalCommands::kSupportsRequestConstraintBasedForecast));
+
+ if (!gInstance)
+ {
+ ChipLogError(AppServer, "Failed to allocate memory for DeviceEnergyManagementManager");
+ gDelegate.reset();
+ return;
+ }
+
+ err = gInstance->Init(); /* Register Attribute & Command handlers */
+ if (err != CHIP_NO_ERROR)
+ {
+ ChipLogError(AppServer, "Init failed on gInstance");
+ gInstance.reset();
+ gDelegate.reset();
+ return;
+ }
+}
diff --git a/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp
index a0773de104c187..f9983d47883852 100644
--- a/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp
@@ -22,25 +22,26 @@ using namespace chip;
using namespace chip::app::Clusters;
using namespace chip::app::Clusters::EnergyEvse;
-static EnergyEvseDelegate * gDelegate = nullptr;
-static EnergyEvseManager * gInstance = nullptr;
+static std::unique_ptr gDelegate;
+static std::unique_ptr gInstance;
void emberAfEnergyEvseClusterInitCallback(chip::EndpointId endpointId)
{
VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
- VerifyOrDie(gInstance == nullptr);
- gDelegate = new EnergyEvseDelegate();
- if (gDelegate != nullptr)
+ VerifyOrDie(!gInstance);
+
+ gDelegate = std::make_unique();
+ if (gDelegate)
{
- gInstance =
- new EnergyEvseManager(endpointId, *gDelegate,
- BitMask(
- EnergyEvse::Feature::kChargingPreferences, EnergyEvse::Feature::kPlugAndCharge,
- EnergyEvse::Feature::kRfid, EnergyEvse::Feature::kSoCReporting, EnergyEvse::Feature::kV2x),
- BitMask(OptionalAttributes::kSupportsUserMaximumChargingCurrent,
- OptionalAttributes::kSupportsRandomizationWindow,
- OptionalAttributes::kSupportsApproximateEvEfficiency),
- BitMask(OptionalCommands::kSupportsStartDiagnostics));
+ gInstance = std::make_unique(
+ endpointId, *gDelegate,
+ BitMask(EnergyEvse::Feature::kChargingPreferences, EnergyEvse::Feature::kPlugAndCharge,
+ EnergyEvse::Feature::kRfid, EnergyEvse::Feature::kSoCReporting,
+ EnergyEvse::Feature::kV2x),
+ BitMask(OptionalAttributes::kSupportsUserMaximumChargingCurrent,
+ OptionalAttributes::kSupportsRandomizationWindow,
+ OptionalAttributes::kSupportsApproximateEvEfficiency),
+ BitMask(OptionalCommands::kSupportsStartDiagnostics));
gInstance->Init(); /* Register Attribute & Command handlers */
}
diff --git a/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp b/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp
index 02bcd4a775a07e..3370d75bd65f35 100644
--- a/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp
@@ -103,6 +103,11 @@ void GenericOperationalStateDelegateImpl::HandleStopStateCallback(GenericOperati
static OperationalState::Instance * gOperationalStateInstance = nullptr;
static OperationalStateDelegate * gOperationalStateDelegate = nullptr;
+OperationalState::Instance * OperationalState::GetOperationalStateInstance()
+{
+ return gOperationalStateInstance;
+}
+
void OperationalState::Shutdown()
{
if (gOperationalStateInstance != nullptr)
@@ -130,36 +135,3 @@ void emberAfOperationalStateClusterInitCallback(chip::EndpointId endpointId)
gOperationalStateInstance->Init();
}
-
-// Init RVC Operational State cluster
-
-static OperationalState::Instance * gRvcOperationalStateInstance = nullptr;
-static RvcOperationalStateDelegate * gRvcOperationalStateDelegate = nullptr;
-
-void RvcOperationalState::Shutdown()
-{
- if (gRvcOperationalStateInstance != nullptr)
- {
- delete gRvcOperationalStateInstance;
- gRvcOperationalStateInstance = nullptr;
- }
- if (gRvcOperationalStateDelegate != nullptr)
- {
- delete gRvcOperationalStateDelegate;
- gRvcOperationalStateDelegate = nullptr;
- }
-}
-
-void emberAfRvcOperationalStateClusterInitCallback(chip::EndpointId endpointId)
-{
- VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
- VerifyOrDie(gRvcOperationalStateInstance == nullptr && gRvcOperationalStateDelegate == nullptr);
-
- gRvcOperationalStateDelegate = new RvcOperationalStateDelegate;
- EndpointId operationalStateEndpoint = 0x01;
- gRvcOperationalStateInstance = new RvcOperationalState::Instance(gRvcOperationalStateDelegate, operationalStateEndpoint);
-
- gRvcOperationalStateInstance->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped));
-
- gRvcOperationalStateInstance->Init();
-}
diff --git a/examples/all-clusters-app/ameba/main/OperationalStateManager.cpp b/examples/all-clusters-app/all-clusters-common/src/rvc-operational-state-delegate-impl.cpp
similarity index 53%
rename from examples/all-clusters-app/ameba/main/OperationalStateManager.cpp
rename to examples/all-clusters-app/all-clusters-common/src/rvc-operational-state-delegate-impl.cpp
index 8dbeda60d75526..946110bb18906c 100644
--- a/examples/all-clusters-app/ameba/main/OperationalStateManager.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/rvc-operational-state-delegate-impl.cpp
@@ -15,15 +15,15 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#include
+#include
using namespace chip;
using namespace chip::app;
using namespace chip::app::Clusters;
-using namespace chip::app::Clusters::OperationalState;
using namespace chip::app::Clusters::RvcOperationalState;
-CHIP_ERROR GenericOperationalStateDelegateImpl::GetOperationalStateAtIndex(size_t index, GenericOperationalState & operationalState)
+CHIP_ERROR RvcOperationalStateDelegate::GetOperationalStateAtIndex(size_t index,
+ OperationalState::GenericOperationalState & operationalState)
{
if (index >= mOperationalStateList.size())
{
@@ -33,7 +33,7 @@ CHIP_ERROR GenericOperationalStateDelegateImpl::GetOperationalStateAtIndex(size_
return CHIP_NO_ERROR;
}
-CHIP_ERROR GenericOperationalStateDelegateImpl::GetOperationalPhaseAtIndex(size_t index, MutableCharSpan & operationalPhase)
+CHIP_ERROR RvcOperationalStateDelegate::GetOperationalPhaseAtIndex(size_t index, MutableCharSpan & operationalPhase)
{
if (index >= mOperationalPhaseList.size())
{
@@ -42,98 +42,76 @@ CHIP_ERROR GenericOperationalStateDelegateImpl::GetOperationalPhaseAtIndex(size_
return CopyCharSpanToMutableCharSpan(mOperationalPhaseList[index], operationalPhase);
}
-void GenericOperationalStateDelegateImpl::HandlePauseStateCallback(GenericOperationalError & err)
+void RvcOperationalStateDelegate::HandlePauseStateCallback(OperationalState::GenericOperationalError & err)
{
+ // placeholder implementation
auto error = GetInstance()->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kPaused));
if (error == CHIP_NO_ERROR)
{
- err.Set(to_underlying(ErrorStateEnum::kNoError));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kNoError));
}
else
{
- err.Set(to_underlying(ErrorStateEnum::kUnableToCompleteOperation));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kUnableToCompleteOperation));
}
}
-void GenericOperationalStateDelegateImpl::HandleResumeStateCallback(GenericOperationalError & err)
+void RvcOperationalStateDelegate::HandleResumeStateCallback(OperationalState::GenericOperationalError & err)
{
- auto error = GetInstance()->SetOperationalState(to_underlying(OperationalStateEnum::kRunning));
+ // placeholder implementation
+ auto error = GetInstance()->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning));
if (error == CHIP_NO_ERROR)
{
- err.Set(to_underlying(ErrorStateEnum::kNoError));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kNoError));
}
else
{
- err.Set(to_underlying(ErrorStateEnum::kUnableToCompleteOperation));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kUnableToCompleteOperation));
}
}
-void GenericOperationalStateDelegateImpl::HandleStartStateCallback(GenericOperationalError & err)
+void RvcOperationalStateDelegate::HandleStartStateCallback(OperationalState::GenericOperationalError & err)
{
- auto error = GetInstance()->SetOperationalState(to_underlying(OperationalStateEnum::kRunning));
+ // placeholder implementation
+ auto error = GetInstance()->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning));
if (error == CHIP_NO_ERROR)
{
- err.Set(to_underlying(ErrorStateEnum::kNoError));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kNoError));
}
else
{
- err.Set(to_underlying(ErrorStateEnum::kUnableToCompleteOperation));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kUnableToCompleteOperation));
}
}
-void GenericOperationalStateDelegateImpl::HandleStopStateCallback(GenericOperationalError & err)
+void RvcOperationalStateDelegate::HandleStopStateCallback(OperationalState::GenericOperationalError & err)
{
- auto error = GetInstance()->SetOperationalState(to_underlying(OperationalStateEnum::kStopped));
+ // placeholder implementation
+ auto error = GetInstance()->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped));
if (error == CHIP_NO_ERROR)
{
- err.Set(to_underlying(ErrorStateEnum::kNoError));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kNoError));
}
else
{
- err.Set(to_underlying(ErrorStateEnum::kUnableToCompleteOperation));
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kUnableToCompleteOperation));
}
}
-// Init Operational State cluster
-
-static OperationalState::Instance * gOperationalStateInstance = nullptr;
-static OperationalStateDelegate * gOperationalStateDelegate = nullptr;
-
-void OperationalState::Shutdown()
+void RvcOperationalStateDelegate::HandleGoHomeCommandCallback(OperationalState::GenericOperationalError & err)
{
- if (gOperationalStateInstance != nullptr)
+ // placeholder implementation
+ auto error = GetInstance()->SetOperationalState(to_underlying(OperationalStateEnum::kSeekingCharger));
+ if (error == CHIP_NO_ERROR)
{
- delete gOperationalStateInstance;
- gOperationalStateInstance = nullptr;
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kNoError));
}
- if (gOperationalStateDelegate != nullptr)
+ else
{
- delete gOperationalStateDelegate;
- gOperationalStateDelegate = nullptr;
+ err.Set(to_underlying(OperationalState::ErrorStateEnum::kUnableToCompleteOperation));
}
}
-OperationalState::Instance * OperationalState::GetOperationalStateInstance()
-{
- return gOperationalStateInstance;
-}
-
-void emberAfOperationalStateClusterInitCallback(chip::EndpointId endpointId)
-{
- VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
- VerifyOrDie(gOperationalStateInstance == nullptr && gOperationalStateDelegate == nullptr);
-
- gOperationalStateDelegate = new OperationalStateDelegate;
- EndpointId operationalStateEndpoint = 0x01;
- gOperationalStateInstance = new OperationalState::Instance(gOperationalStateDelegate, operationalStateEndpoint);
-
- gOperationalStateInstance->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped));
-
- gOperationalStateInstance->Init();
-}
-
-// Init RVC Operational State cluster
-
static RvcOperationalState::Instance * gRvcOperationalStateInstance = nullptr;
static RvcOperationalStateDelegate * gRvcOperationalStateDelegate = nullptr;
diff --git a/examples/all-clusters-app/ameba/chip_main.cmake b/examples/all-clusters-app/ameba/chip_main.cmake
index e68398afdf625d..6cc76ad25e7dd8 100755
--- a/examples/all-clusters-app/ameba/chip_main.cmake
+++ b/examples/all-clusters-app/ameba/chip_main.cmake
@@ -156,6 +156,7 @@ list(
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp
+ ${chip_dir}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp
@@ -165,16 +166,19 @@ list(
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp
${chip_dir}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp
+ ${chip_dir}/examples/all-clusters-app/all-clusters-common/src/operational-state-delegate-impl.cpp
+ ${chip_dir}/examples/all-clusters-app/all-clusters-common/src/rvc-operational-state-delegate-impl.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/chipinterface.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/BindingHandler.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/DeviceCallbacks.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/CHIPDeviceManager.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/Globals.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/LEDWidget.cpp
- ${chip_dir}/examples/all-clusters-app/ameba/main/OperationalStateManager.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/ManualOperationCommand.cpp
${chip_dir}/examples/all-clusters-app/ameba/main/SmokeCOAlarmManager.cpp
+ ${chip_dir}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp
+ ${chip_dir}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp
${chip_dir}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp
${chip_dir}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp
diff --git a/examples/all-clusters-app/ameba/main/include/ManualOperationalStateCommand.h b/examples/all-clusters-app/ameba/main/include/ManualOperationalStateCommand.h
index 5d4373597a2d00..fc2825576e6b72 100644
--- a/examples/all-clusters-app/ameba/main/include/ManualOperationalStateCommand.h
+++ b/examples/all-clusters-app/ameba/main/include/ManualOperationalStateCommand.h
@@ -18,7 +18,8 @@
#include "controller/InvokeInteraction.h"
#include "controller/ReadInteraction.h"
-#include
+#include "operational-state-delegate-impl.h"
+#include "rvc-operational-state-delegate-impl.h"
#if CONFIG_ENABLE_CHIP_SHELL
#include "lib/shell/Engine.h"
diff --git a/examples/all-clusters-app/asr/BUILD.gn b/examples/all-clusters-app/asr/BUILD.gn
index 1c23617af66262..263bd8cf7734b7 100755
--- a/examples/all-clusters-app/asr/BUILD.gn
+++ b/examples/all-clusters-app/asr/BUILD.gn
@@ -74,6 +74,7 @@ asr_executable("clusters_app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -81,6 +82,8 @@ asr_executable("clusters_app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"${examples_plat_dir}/ButtonHandler.cpp",
diff --git a/examples/all-clusters-app/cc13x2x7_26x2x7/BUILD.gn b/examples/all-clusters-app/cc13x2x7_26x2x7/BUILD.gn
index 26c0f67e389a0c..6ec6202ea21209 100644
--- a/examples/all-clusters-app/cc13x2x7_26x2x7/BUILD.gn
+++ b/examples/all-clusters-app/cc13x2x7_26x2x7/BUILD.gn
@@ -79,6 +79,7 @@ ti_simplelink_executable("all-clusters-app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/binding-handler.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -86,6 +87,8 @@ ti_simplelink_executable("all-clusters-app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"${chip_root}/examples/providers/DeviceInfoProviderImpl.cpp",
diff --git a/examples/all-clusters-app/cc13x4_26x4/BUILD.gn b/examples/all-clusters-app/cc13x4_26x4/BUILD.gn
index e9492d7a223f42..02dbebf7e6d8c9 100644
--- a/examples/all-clusters-app/cc13x4_26x4/BUILD.gn
+++ b/examples/all-clusters-app/cc13x4_26x4/BUILD.gn
@@ -82,6 +82,7 @@ ti_simplelink_executable("all-clusters-app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/binding-handler.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -89,6 +90,8 @@ ti_simplelink_executable("all-clusters-app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"${chip_root}/examples/providers/DeviceInfoProviderImpl.cpp",
diff --git a/examples/all-clusters-app/esp32/main/CMakeLists.txt b/examples/all-clusters-app/esp32/main/CMakeLists.txt
index c5d40048308c2d..f2f432a60d615a 100644
--- a/examples/all-clusters-app/esp32/main/CMakeLists.txt
+++ b/examples/all-clusters-app/esp32/main/CMakeLists.txt
@@ -28,6 +28,8 @@ set(SRC_DIRS_LIST
"${CMAKE_CURRENT_LIST_DIR}"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/zzz_generated/app-common/app-common/zap-generated/attributes"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/zzz_generated/app-common/app-common/zap-generated"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/all-clusters-app/all-clusters-common/src"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/energy-management-app/energy-management-common/src"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/providers"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/platform/esp32/ota"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/platform/esp32/common"
@@ -38,8 +40,11 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/util"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/reporting"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/administrator-commissioning-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/air-quality-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/test-cluster-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/boolean-state-configuration-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/descriptor"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/energy-evse-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/fault-injection-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/fan-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/fixed-label-server"
@@ -55,6 +60,7 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/groups-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/color-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/operational-credentials-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/operational-state-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/mode-select-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/mode-base-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/low-power-server"
@@ -74,6 +80,7 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/icd-management-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/diagnostic-logs-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/occupancy-sensor-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/device-energy-management-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/energy-evse-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/ethernet-network-diagnostics-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/localization-configuration-server"
@@ -86,10 +93,10 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/resource-monitoring-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/temperature-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/time-synchronization-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/valve-configuration-and-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/dishwasher-alarm-server"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/laundry-washer-controls-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/laundry-washer-controls-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/laundry-dryer-controls-server"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/all-clusters-app/all-clusters-common/src"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/electrical-energy-measurement-server"
)
diff --git a/examples/all-clusters-app/infineon/psoc6/BUILD.gn b/examples/all-clusters-app/infineon/psoc6/BUILD.gn
index f4469b9c7bc290..f2b9ab939d6f38 100644
--- a/examples/all-clusters-app/infineon/psoc6/BUILD.gn
+++ b/examples/all-clusters-app/infineon/psoc6/BUILD.gn
@@ -110,6 +110,7 @@ psoc6_executable("clusters_app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -117,6 +118,8 @@ psoc6_executable("clusters_app") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"${examples_plat_dir}/LEDWidget.cpp",
diff --git a/examples/all-clusters-app/linux/BUILD.gn b/examples/all-clusters-app/linux/BUILD.gn
index 343372676bd8fc..3b93e7605d5c65 100644
--- a/examples/all-clusters-app/linux/BUILD.gn
+++ b/examples/all-clusters-app/linux/BUILD.gn
@@ -23,8 +23,10 @@ source_set("chip-all-clusters-common") {
sources = [
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/binding-handler.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/dishwasher-alarm-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/dishwasher-mode.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
@@ -37,14 +39,18 @@ source_set("chip-all-clusters-common") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/resource-monitoring-delegates.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/rvc-operational-state-delegate-impl.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/tcc-mode.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"AllClustersCommandDelegate.cpp",
"AppOptions.cpp",
+ "ValveControlDelegate.cpp",
"WindowCoveringManager.cpp",
"include/tv-callbacks.cpp",
"include/tv-callbacks.h",
diff --git a/examples/all-clusters-app/linux/ValveControlDelegate.cpp b/examples/all-clusters-app/linux/ValveControlDelegate.cpp
new file mode 100644
index 00000000000000..9c51aff63101f5
--- /dev/null
+++ b/examples/all-clusters-app/linux/ValveControlDelegate.cpp
@@ -0,0 +1,76 @@
+/**
+ *
+ * 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
+ *
+ * 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 "ValveControlDelegate.h"
+#include
+#include
+
+using namespace chip;
+using namespace chip::app;
+using namespace chip::app::Clusters::ValveConfigurationAndControl;
+using namespace chip::app::Clusters::TimeSynchronization;
+
+static chip::Percent sLevel = 1;
+static uint32_t sLastOpenDuration = 0;
+static constexpr EndpointId kValveEndpoint = 1;
+
+DataModel::Nullable ValveControlDelegate::HandleOpenValve(DataModel::Nullable level)
+{
+ chip::Percent currentLevel = sLevel;
+ sLevel = level.IsNull() ? 100 : level.Value();
+ sLastOpenDuration = 0;
+ ChipLogProgress(NotSpecified, "Valve openinig from level: %d to %d", currentLevel, sLevel);
+
+ // In this demo application, the trasition is considered instant,
+ // so current level is set to the requested level and current state is set to kOpen.
+ currentLevel = sLevel;
+ Attributes::CurrentState::Set(kValveEndpoint, ValveConfigurationAndControl::ValveStateEnum::kOpen);
+
+ return DataModel::Nullable(currentLevel);
+}
+
+CHIP_ERROR ValveControlDelegate::HandleCloseValve()
+{
+ sLastOpenDuration = 0;
+ sLevel = 0;
+ ReturnErrorOnFailure(ValveConfigurationAndControl::UpdateCurrentLevel(kValveEndpoint, sLevel));
+ ReturnErrorOnFailure(
+ ValveConfigurationAndControl::UpdateCurrentState(kValveEndpoint, ValveConfigurationAndControl::ValveStateEnum::kClosed));
+ ChipLogProgress(NotSpecified, "Valve closed");
+ return CHIP_NO_ERROR;
+}
+
+void ValveControlDelegate::HandleRemainingDurationTick(uint32_t duration)
+{
+ ChipLogProgress(NotSpecified, "Valve remaining duration ticking: %dsec level: %d duration %d", duration, sLevel,
+ sLastOpenDuration);
+ if (sLastOpenDuration == 0)
+ {
+ VerifyOrReturn(CHIP_NO_ERROR == ValveConfigurationAndControl::UpdateCurrentLevel(kValveEndpoint, sLevel),
+ ChipLogError(NotSpecified, "Updating current level failed"));
+ VerifyOrReturn(CHIP_NO_ERROR ==
+ ValveConfigurationAndControl::UpdateCurrentState(kValveEndpoint,
+ ValveConfigurationAndControl::ValveStateEnum::kOpen),
+ ChipLogError(NotSpecified, "Updating current state failed"));
+ }
+ sLastOpenDuration = duration;
+}
+
+void ExtendedTimeSyncDelegate::UTCTimeChanged(uint64_t time)
+{
+ ValveConfigurationAndControl::UpdateAutoCloseTime(time);
+}
diff --git a/examples/all-clusters-app/linux/ValveControlDelegate.h b/examples/all-clusters-app/linux/ValveControlDelegate.h
new file mode 100644
index 00000000000000..76f0f17a8fdfd1
--- /dev/null
+++ b/examples/all-clusters-app/linux/ValveControlDelegate.h
@@ -0,0 +1,49 @@
+/**
+ *
+ * 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
+ *
+ * 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.
+ */
+
+#pragma once
+
+#include
+#include
+
+namespace chip {
+namespace app {
+namespace Clusters {
+namespace ValveConfigurationAndControl {
+
+class ValveControlDelegate : public Delegate
+{
+public:
+ DataModel::Nullable HandleOpenValve(DataModel::Nullable level) override;
+ CHIP_ERROR HandleCloseValve() override;
+ void HandleRemainingDurationTick(uint32_t duration) override;
+};
+
+} // namespace ValveConfigurationAndControl
+
+namespace TimeSynchronization {
+
+class ExtendedTimeSyncDelegate : public DefaultTimeSyncDelegate
+{
+public:
+ void UTCTimeChanged(uint64_t time) override;
+};
+
+} // namespace TimeSynchronization
+} // namespace Clusters
+} // namespace app
+} // namespace chip
diff --git a/examples/all-clusters-app/linux/args.gni b/examples/all-clusters-app/linux/args.gni
index 1bcd86f18843b8..d414ad5dedaf5d 100644
--- a/examples/all-clusters-app/linux/args.gni
+++ b/examples/all-clusters-app/linux/args.gni
@@ -28,3 +28,4 @@ matter_enable_tracing_support = true
matter_log_json_payload_decode_full = true
matter_log_json_payload_hex = true
chip_enable_smoke_co_trigger = true
+chip_enable_boolean_state_configuration_trigger = true
diff --git a/examples/all-clusters-app/linux/main-common.cpp b/examples/all-clusters-app/linux/main-common.cpp
index 05435df44e81b8..a3040c39d0d175 100644
--- a/examples/all-clusters-app/linux/main-common.cpp
+++ b/examples/all-clusters-app/linux/main-common.cpp
@@ -17,6 +17,7 @@
*/
#include "AllClustersCommandDelegate.h"
+#include "ValveControlDelegate.h"
#include "WindowCoveringManager.h"
#include "air-quality-instance.h"
#include "dishwasher-mode.h"
@@ -29,6 +30,7 @@
#include "oven-modes.h"
#include "resource-monitoring-delegates.h"
#include "rvc-modes.h"
+#include "rvc-operational-state-delegate-impl.h"
#include "tcc-mode.h"
#include
#include
@@ -38,6 +40,8 @@
#include
#include
#include
+#include
+#include
#include
#include
#include
@@ -64,6 +68,8 @@ AllClustersCommandDelegate sAllClustersCommandDelegate;
Clusters::WindowCovering::WindowCoveringManager sWindowCoveringManager;
Clusters::TemperatureControl::AppSupportedTemperatureLevelsDelegate sAppSupportedTemperatureLevelsDelegate;
+Clusters::ValveConfigurationAndControl::ValveControlDelegate sValveDelegate;
+Clusters::TimeSynchronization::ExtendedTimeSyncDelegate sTimeSyncDelegate;
// Please refer to https://github.com/CHIP-Specifications/connectedhomeip-spec/blob/master/src/namespaces
constexpr const uint8_t kNamespaceCommon = 7;
@@ -218,6 +224,9 @@ void ApplicationInit()
#endif
Clusters::TemperatureControl::SetInstance(&sAppSupportedTemperatureLevelsDelegate);
+ Clusters::ValveConfigurationAndControl::SetDefaultDelegate(chip::EndpointId(1), &sValveDelegate);
+ Clusters::TimeSynchronization::SetDefaultDelegate(&sTimeSyncDelegate);
+
SetTagList(/* endpoint= */ 0, Span(gEp0TagList));
SetTagList(/* endpoint= */ 1, Span(gEp1TagList));
SetTagList(/* endpoint= */ 2, Span(gEp2TagList));
diff --git a/examples/all-clusters-app/mbed/CMakeLists.txt b/examples/all-clusters-app/mbed/CMakeLists.txt
index 28104e85f0c3b1..f2b6d9f5e88d27 100644
--- a/examples/all-clusters-app/mbed/CMakeLists.txt
+++ b/examples/all-clusters-app/mbed/CMakeLists.txt
@@ -65,6 +65,7 @@ target_sources(${APP_TARGET} PRIVATE
${ALL_CLUSTERS_COMMON}/src/air-quality-instance.cpp
${ALL_CLUSTERS_COMMON}/src/concentration-measurement-instances.cpp
${ALL_CLUSTERS_COMMON}/src/fan-stub.cpp
+ ${ALL_CLUSTERS_COMMON}/src/device-energy-management-stub.cpp
${ALL_CLUSTERS_COMMON}/src/energy-evse-stub.cpp
${ALL_CLUSTERS_COMMON}/src/oven-modes.cpp
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-delegates.cpp
@@ -73,6 +74,9 @@ target_sources(${APP_TARGET} PRIVATE
${ALL_CLUSTERS_COMMON}/src/static-supported-temperature-levels.cpp
${ENERGY_MANAGEMENT_COMMON}/src/EnergyEvseDelegateImpl.cpp
${ENERGY_MANAGEMENT_COMMON}/src/EnergyEvseManager.cpp
+ ${ENERGY_MANAGEMENT_COMMON}/src/DeviceEnergyManagementDelegateImpl.cpp
+ ${ENERGY_MANAGEMENT_COMMON}/src/DeviceEnergyManagementManager.cpp
+
)
chip_configure_data_model(${APP_TARGET}
diff --git a/examples/all-clusters-app/nrfconnect/CMakeLists.txt b/examples/all-clusters-app/nrfconnect/CMakeLists.txt
index 48499c29712d40..49bf4fb7f95e3a 100644
--- a/examples/all-clusters-app/nrfconnect/CMakeLists.txt
+++ b/examples/all-clusters-app/nrfconnect/CMakeLists.txt
@@ -65,10 +65,13 @@ target_sources(app PRIVATE
${ALL_CLUSTERS_COMMON_DIR}/src/fan-stub.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/oven-modes.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/energy-evse-stub.cpp
+ ${ALL_CLUSTERS_COMMON_DIR}/src/device-energy-management-stub.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/binding-handler.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/air-quality-instance.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/concentration-measurement-instances.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-delegates.cpp
+ ${ENERGY_MANAGEMENT_COMMON_DIR}/src/DeviceEnergyManagementDelegateImpl.cpp
+ ${ENERGY_MANAGEMENT_COMMON_DIR}/src/DeviceEnergyManagementManager.cpp
${ENERGY_MANAGEMENT_COMMON_DIR}/src/EnergyEvseDelegateImpl.cpp
${ENERGY_MANAGEMENT_COMMON_DIR}/src/EnergyEvseManager.cpp
${NRFCONNECT_COMMON}/util/LEDWidget.cpp)
diff --git a/examples/all-clusters-app/nxp/mw320/BUILD.gn b/examples/all-clusters-app/nxp/mw320/BUILD.gn
index 01bba26479a7af..a858c18e87fed2 100644
--- a/examples/all-clusters-app/nxp/mw320/BUILD.gn
+++ b/examples/all-clusters-app/nxp/mw320/BUILD.gn
@@ -78,6 +78,7 @@ mw320_executable("shell_mw320") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/air-quality-instance.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -85,6 +86,8 @@ mw320_executable("shell_mw320") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
"${chip_root}/src/lib/shell/streamer_mw320.cpp",
diff --git a/examples/all-clusters-app/openiotsdk/CMakeLists.txt b/examples/all-clusters-app/openiotsdk/CMakeLists.txt
index 60b5bdddf40740..3b50f286b1683b 100644
--- a/examples/all-clusters-app/openiotsdk/CMakeLists.txt
+++ b/examples/all-clusters-app/openiotsdk/CMakeLists.txt
@@ -60,12 +60,15 @@ target_sources(${APP_TARGET}
${ALL_CLUSTERS_COMMON}/src/concentration-measurement-instances.cpp
${ALL_CLUSTERS_COMMON}/src/fan-stub.cpp
${ALL_CLUSTERS_COMMON}/src/oven-modes.cpp
+ ${ALL_CLUSTERS_COMMON}/src/device-energy-management-stub.cpp
${ALL_CLUSTERS_COMMON}/src/energy-evse-stub.cpp
${ALL_CLUSTERS_COMMON}/src/resource-monitoring-delegates.cpp
${ALL_CLUSTERS_COMMON}/src/static-supported-modes-manager.cpp
${ALL_CLUSTERS_COMMON}/src/binding-handler.cpp
${ENERGY_MANAGEMENT_COMMON}/src/EnergyEvseDelegateImpl.cpp
${ENERGY_MANAGEMENT_COMMON}/src/EnergyEvseManager.cpp
+ ${ENERGY_MANAGEMENT_COMMON}/src/DeviceEnergyManagementDelegateImpl.cpp
+ ${ENERGY_MANAGEMENT_COMMON}/src/DeviceEnergyManagementManager.cpp
)
target_link_libraries(${APP_TARGET}
diff --git a/examples/all-clusters-app/telink/CMakeLists.txt b/examples/all-clusters-app/telink/CMakeLists.txt
index 7448fd76c4d91f..ae715a8c41ebfb 100644
--- a/examples/all-clusters-app/telink/CMakeLists.txt
+++ b/examples/all-clusters-app/telink/CMakeLists.txt
@@ -72,10 +72,6 @@ target_include_directories(app PRIVATE
${TELINK_COMMON}/common/include
${TELINK_COMMON}/util/include)
-add_definitions(
- "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER="
-)
-
target_sources(app PRIVATE
src/AppTask.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/smco-stub.cpp
@@ -86,10 +82,13 @@ target_sources(app PRIVATE
${ALL_CLUSTERS_COMMON_DIR}/src/air-quality-instance.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/concentration-measurement-instances.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/fan-stub.cpp
+ ${ALL_CLUSTERS_COMMON_DIR}/src/device-energy-management-stub.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/energy-evse-stub.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/resource-monitoring-delegates.cpp
${ENERGY_MANAGEMENT_COMMON_DIR}/src/EnergyEvseDelegateImpl.cpp
${ENERGY_MANAGEMENT_COMMON_DIR}/src/EnergyEvseManager.cpp
+ ${ENERGY_MANAGEMENT_COMMON_DIR}/src/DeviceEnergyManagementDelegateImpl.cpp
+ ${ENERGY_MANAGEMENT_COMMON_DIR}/src/DeviceEnergyManagementManager.cpp
${TELINK_COMMON}/common/src/mainCommon.cpp
${TELINK_COMMON}/common/src/AppTaskCommon.cpp
${TELINK_COMMON}/util/src/LEDWidget.cpp
@@ -101,3 +100,7 @@ chip_configure_data_model(app
INCLUDE_SERVER
ZAP_FILE ${ALL_CLUSTERS_COMMON_DIR}/all-clusters-app.zap
)
+
+if(CONFIG_BOOTLOADER_MCUBOOT)
+ target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp)
+endif()
diff --git a/examples/all-clusters-app/tizen/BUILD.gn b/examples/all-clusters-app/tizen/BUILD.gn
index 202d288f87053c..e9bb7f56e4bfaa 100644
--- a/examples/all-clusters-app/tizen/BUILD.gn
+++ b/examples/all-clusters-app/tizen/BUILD.gn
@@ -27,6 +27,7 @@ source_set("chip-all-clusters-common") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/binding-handler.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
@@ -34,6 +35,8 @@ source_set("chip-all-clusters-common") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-modes-manager.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/static-supported-temperature-levels.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementDelegateImpl.cpp",
+ "${chip_root}/examples/energy-management-app/energy-management-common/src/DeviceEnergyManagementManager.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseDelegateImpl.cpp",
"${chip_root}/examples/energy-management-app/energy-management-common/src/EnergyEvseManager.cpp",
]
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 22ca859b26a104..ee5f558431657e 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
@@ -128,199 +128,6 @@ cluster Groups = 4 {
fabric command access(invoke: manage) AddGroupIfIdentifying(AddGroupIfIdentifyingRequest): DefaultSuccess = 5;
}
-/** Attributes and commands for scene configuration and manipulation. */
-provisional cluster Scenes = 5 {
- revision 5;
-
- bitmap CopyModeBitmap : bitmap8 {
- kCopyAllScenes = 0x1;
- }
-
- bitmap Feature : bitmap32 {
- kSceneNames = 0x1;
- kExplicit = 0x2;
- kTableSize = 0x4;
- kFabricScenes = 0x8;
- }
-
- bitmap NameSupportBitmap : bitmap8 {
- kSceneNames = 0x80;
- }
-
- struct AttributeValuePair {
- attrib_id attributeID = 0;
- int32u attributeValue = 1;
- }
-
- struct ExtensionFieldSet {
- cluster_id clusterID = 0;
- AttributeValuePair attributeValueList[] = 1;
- }
-
- fabric_scoped struct SceneInfoStruct {
- int8u sceneCount = 0;
- fabric_sensitive int8u currentScene = 1;
- fabric_sensitive group_id currentGroup = 2;
- fabric_sensitive boolean sceneValid = 3;
- int8u remainingCapacity = 4;
- fabric_idx fabricIndex = 254;
- }
-
- readonly attribute optional int8u sceneCount = 0;
- readonly attribute optional int8u currentScene = 1;
- readonly attribute optional group_id currentGroup = 2;
- readonly attribute optional boolean sceneValid = 3;
- readonly attribute NameSupportBitmap nameSupport = 4;
- readonly attribute optional nullable node_id lastConfiguredBy = 5;
- readonly attribute int16u sceneTableSize = 6;
- readonly attribute SceneInfoStruct fabricSceneInfo[] = 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 AddSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- int16u transitionTime = 2;
- char_string sceneName = 3;
- ExtensionFieldSet extensionFieldSets[] = 4;
- }
-
- response struct AddSceneResponse = 0 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct ViewSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct ViewSceneResponse = 1 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- optional int16u transitionTime = 3;
- optional char_string sceneName = 4;
- optional ExtensionFieldSet extensionFieldSets[] = 5;
- }
-
- request struct RemoveSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct RemoveSceneResponse = 2 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct RemoveAllScenesRequest {
- group_id groupID = 0;
- }
-
- response struct RemoveAllScenesResponse = 3 {
- status status = 0;
- group_id groupID = 1;
- }
-
- request struct StoreSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct StoreSceneResponse = 4 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct RecallSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- optional nullable int16u transitionTime = 2;
- }
-
- request struct GetSceneMembershipRequest {
- group_id groupID = 0;
- }
-
- response struct GetSceneMembershipResponse = 6 {
- status status = 0;
- nullable int8u capacity = 1;
- group_id groupID = 2;
- optional int8u sceneList[] = 3;
- }
-
- request struct EnhancedAddSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- int16u transitionTime = 2;
- char_string sceneName = 3;
- ExtensionFieldSet extensionFieldSets[] = 4;
- }
-
- response struct EnhancedAddSceneResponse = 64 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- }
-
- request struct EnhancedViewSceneRequest {
- group_id groupID = 0;
- int8u sceneID = 1;
- }
-
- response struct EnhancedViewSceneResponse = 65 {
- status status = 0;
- group_id groupID = 1;
- int8u sceneID = 2;
- optional int16u transitionTime = 3;
- optional char_string sceneName = 4;
- optional ExtensionFieldSet extensionFieldSets[] = 5;
- }
-
- request struct CopySceneRequest {
- CopyModeBitmap mode = 0;
- group_id groupIdentifierFrom = 1;
- int8u sceneIdentifierFrom = 2;
- group_id groupIdentifierTo = 3;
- int8u sceneIdentifierTo = 4;
- }
-
- response struct CopySceneResponse = 66 {
- status status = 0;
- group_id groupIdentifierFrom = 1;
- int8u sceneIdentifierFrom = 2;
- }
-
- /** Add a scene to the scene table. Extension field sets are supported, and are inputed as '{"ClusterID": VALUE, "AttributeValueList":[{"AttributeId": VALUE, "AttributeValue": VALUE}]}' */
- fabric command access(invoke: manage) AddScene(AddSceneRequest): AddSceneResponse = 0;
- /** Retrieves the requested scene entry from its Scene table. */
- fabric command ViewScene(ViewSceneRequest): ViewSceneResponse = 1;
- /** Removes the requested scene entry, corresponding to the value of the GroupID field, from its Scene Table */
- fabric command access(invoke: manage) RemoveScene(RemoveSceneRequest): RemoveSceneResponse = 2;
- /** Remove all scenes, corresponding to the value of the GroupID field, from its Scene Table */
- fabric command access(invoke: manage) RemoveAllScenes(RemoveAllScenesRequest): RemoveAllScenesResponse = 3;
- /** Adds the scene entry into its Scene Table along with all extension field sets corresponding to the current state of other clusters on the same endpoint */
- fabric command access(invoke: manage) StoreScene(StoreSceneRequest): StoreSceneResponse = 4;
- /** Set the attributes and corresponding state for each other cluster implemented on the endpoint accordingly to the resquested scene entry in the Scene Table */
- fabric command RecallScene(RecallSceneRequest): DefaultSuccess = 5;
- /** Get an unused scene identifier when no commissioning tool is in the network, or for a commissioning tool to get the used scene identifiers within a certain group */
- fabric command GetSceneMembership(GetSceneMembershipRequest): GetSceneMembershipResponse = 6;
- /** Allows a scene to be added using a finer scene transition time than the AddScene command. */
- fabric command EnhancedAddScene(EnhancedAddSceneRequest): EnhancedAddSceneResponse = 64;
- /** Allows a scene to be retrieved using a finer scene transition time than the ViewScene command */
- fabric command EnhancedViewScene(EnhancedViewSceneRequest): EnhancedViewSceneResponse = 65;
- /** Allows a client to efficiently copy scenes from one group/scene identifier pair to another group/scene identifier pair. */
- fabric command CopyScene(CopySceneRequest): CopySceneResponse = 66;
-}
-
/** Attributes and commands for switching devices between 'On' and 'Off' states. */
cluster OnOff = 6 {
revision 6;
@@ -2521,72 +2328,265 @@ cluster BooleanState = 69 {
cluster ModeSelect = 80 {
revision 2;
- bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ bitmap Feature : bitmap32 {
+ kOnOff = 0x1;
+ }
+
+ struct SemanticTagStruct {
+ vendor_id mfgCode = 0;
+ enum16 value = 1;
+ }
+
+ struct ModeOptionStruct {
+ char_string<64> label = 0;
+ int8u mode = 1;
+ SemanticTagStruct semanticTags[] = 2;
+ }
+
+ readonly attribute char_string<64> description = 0;
+ readonly attribute nullable enum16 standardNamespace = 1;
+ readonly attribute ModeOptionStruct supportedModes[] = 2;
+ readonly attribute int8u currentMode = 3;
+ attribute optional nullable int8u startUpMode = 4;
+ attribute optional nullable int8u onMode = 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 ChangeToModeRequest {
+ int8u newMode = 0;
+ }
+
+ /** On receipt of this command, if the NewMode field matches the Mode field in an entry of the SupportedModes list, the server SHALL set the CurrentMode attribute to the NewMode value, otherwise, the server SHALL respond with an INVALID_COMMAND status response. */
+ command ChangeToMode(ChangeToModeRequest): DefaultSuccess = 0;
+}
+
+/** Attributes and commands for configuring the temperature control, and reporting temperature. */
+cluster TemperatureControl = 86 {
+ revision 1; // NOTE: Default/not specifically set
+
+ bitmap Feature : bitmap32 {
+ kTemperatureNumber = 0x1;
+ kTemperatureLevel = 0x2;
+ kTemperatureStep = 0x4;
+ }
+
+ readonly attribute optional temperature temperatureSetpoint = 0;
+ readonly attribute optional temperature minTemperature = 1;
+ readonly attribute optional temperature maxTemperature = 2;
+ readonly attribute optional temperature step = 3;
+ readonly attribute optional int8u selectedTemperatureLevel = 4;
+ readonly attribute optional char_string supportedTemperatureLevels[] = 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 SetTemperatureRequest {
+ optional temperature targetTemperature = 0;
+ optional int8u targetTemperatureLevel = 1;
+ }
+
+ /** Set Temperature */
+ command SetTemperature(SetTemperatureRequest): DefaultSuccess = 0;
+}
+
+/** Attributes and commands for scene configuration and manipulation. */
+provisional cluster ScenesManagement = 98 {
+ revision 5;
+
+ bitmap CopyModeBitmap : bitmap8 {
+ kCopyAllScenes = 0x1;
+ }
+
+ bitmap Feature : bitmap32 {
+ kSceneNames = 0x1;
+ kExplicit = 0x2;
+ kTableSize = 0x4;
+ kFabricScenes = 0x8;
+ }
+
+ bitmap NameSupportBitmap : bitmap8 {
+ kSceneNames = 0x80;
+ }
+
+ struct AttributeValuePair {
+ attrib_id attributeID = 0;
+ int32u attributeValue = 1;
+ }
+
+ struct ExtensionFieldSet {
+ cluster_id clusterID = 0;
+ AttributeValuePair attributeValueList[] = 1;
+ }
+
+ fabric_scoped struct SceneInfoStruct {
+ int8u sceneCount = 0;
+ fabric_sensitive int8u currentScene = 1;
+ fabric_sensitive group_id currentGroup = 2;
+ fabric_sensitive boolean sceneValid = 3;
+ int8u remainingCapacity = 4;
+ fabric_idx fabricIndex = 254;
+ }
+
+ readonly attribute optional int8u sceneCount = 0;
+ readonly attribute optional int8u currentScene = 1;
+ readonly attribute optional group_id currentGroup = 2;
+ readonly attribute optional boolean sceneValid = 3;
+ readonly attribute NameSupportBitmap nameSupport = 4;
+ readonly attribute optional nullable node_id lastConfiguredBy = 5;
+ readonly attribute int16u sceneTableSize = 6;
+ readonly attribute SceneInfoStruct fabricSceneInfo[] = 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 AddSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ int16u transitionTime = 2;
+ char_string sceneName = 3;
+ ExtensionFieldSet extensionFieldSets[] = 4;
+ }
+
+ response struct AddSceneResponse = 0 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct ViewSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct ViewSceneResponse = 1 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ optional int16u transitionTime = 3;
+ optional char_string sceneName = 4;
+ optional ExtensionFieldSet extensionFieldSets[] = 5;
+ }
+
+ request struct RemoveSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ }
+
+ response struct RemoveSceneResponse = 2 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
+
+ request struct RemoveAllScenesRequest {
+ group_id groupID = 0;
+ }
+
+ response struct RemoveAllScenesResponse = 3 {
+ status status = 0;
+ group_id groupID = 1;
+ }
+
+ request struct StoreSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
}
- struct SemanticTagStruct {
- vendor_id mfgCode = 0;
- enum16 value = 1;
+ response struct StoreSceneResponse = 4 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
}
- struct ModeOptionStruct {
- char_string<64> label = 0;
- int8u mode = 1;
- SemanticTagStruct semanticTags[] = 2;
+ request struct RecallSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ optional nullable int16u transitionTime = 2;
}
- readonly attribute char_string<64> description = 0;
- readonly attribute nullable enum16 standardNamespace = 1;
- readonly attribute ModeOptionStruct supportedModes[] = 2;
- readonly attribute int8u currentMode = 3;
- attribute optional nullable int8u startUpMode = 4;
- attribute optional nullable int8u onMode = 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 GetSceneMembershipRequest {
+ group_id groupID = 0;
+ }
- request struct ChangeToModeRequest {
- int8u newMode = 0;
+ response struct GetSceneMembershipResponse = 6 {
+ status status = 0;
+ nullable int8u capacity = 1;
+ group_id groupID = 2;
+ optional int8u sceneList[] = 3;
}
- /** On receipt of this command, if the NewMode field matches the Mode field in an entry of the SupportedModes list, the server SHALL set the CurrentMode attribute to the NewMode value, otherwise, the server SHALL respond with an INVALID_COMMAND status response. */
- command ChangeToMode(ChangeToModeRequest): DefaultSuccess = 0;
-}
+ request struct EnhancedAddSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
+ int16u transitionTime = 2;
+ char_string sceneName = 3;
+ ExtensionFieldSet extensionFieldSets[] = 4;
+ }
-/** Attributes and commands for configuring the temperature control, and reporting temperature. */
-cluster TemperatureControl = 86 {
- revision 1; // NOTE: Default/not specifically set
+ response struct EnhancedAddSceneResponse = 64 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ }
- bitmap Feature : bitmap32 {
- kTemperatureNumber = 0x1;
- kTemperatureLevel = 0x2;
- kTemperatureStep = 0x4;
+ request struct EnhancedViewSceneRequest {
+ group_id groupID = 0;
+ int8u sceneID = 1;
}
- readonly attribute optional temperature temperatureSetpoint = 0;
- readonly attribute optional temperature minTemperature = 1;
- readonly attribute optional temperature maxTemperature = 2;
- readonly attribute optional temperature step = 3;
- readonly attribute optional int8u selectedTemperatureLevel = 4;
- readonly attribute optional char_string supportedTemperatureLevels[] = 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;
+ response struct EnhancedViewSceneResponse = 65 {
+ status status = 0;
+ group_id groupID = 1;
+ int8u sceneID = 2;
+ optional int16u transitionTime = 3;
+ optional char_string sceneName = 4;
+ optional ExtensionFieldSet extensionFieldSets[] = 5;
+ }
- request struct SetTemperatureRequest {
- optional temperature targetTemperature = 0;
- optional int8u targetTemperatureLevel = 1;
+ request struct CopySceneRequest {
+ CopyModeBitmap mode = 0;
+ group_id groupIdentifierFrom = 1;
+ int8u sceneIdentifierFrom = 2;
+ group_id groupIdentifierTo = 3;
+ int8u sceneIdentifierTo = 4;
}
- /** Set Temperature */
- command SetTemperature(SetTemperatureRequest): DefaultSuccess = 0;
+ response struct CopySceneResponse = 66 {
+ status status = 0;
+ group_id groupIdentifierFrom = 1;
+ int8u sceneIdentifierFrom = 2;
+ }
+
+ /** Add a scene to the scene table. Extension field sets are supported, and are inputed as '{"ClusterID": VALUE, "AttributeValueList":[{"AttributeId": VALUE, "AttributeValue": VALUE}]}' */
+ fabric command access(invoke: manage) AddScene(AddSceneRequest): AddSceneResponse = 0;
+ /** Retrieves the requested scene entry from its Scene table. */
+ fabric command ViewScene(ViewSceneRequest): ViewSceneResponse = 1;
+ /** Removes the requested scene entry, corresponding to the value of the GroupID field, from its Scene Table */
+ fabric command access(invoke: manage) RemoveScene(RemoveSceneRequest): RemoveSceneResponse = 2;
+ /** Remove all scenes, corresponding to the value of the GroupID field, from its Scene Table */
+ fabric command access(invoke: manage) RemoveAllScenes(RemoveAllScenesRequest): RemoveAllScenesResponse = 3;
+ /** Adds the scene entry into its Scene Table along with all extension field sets corresponding to the current state of other clusters on the same endpoint */
+ fabric command access(invoke: manage) StoreScene(StoreSceneRequest): StoreSceneResponse = 4;
+ /** Set the attributes and corresponding state for each other cluster implemented on the endpoint accordingly to the resquested scene entry in the Scene Table */
+ fabric command RecallScene(RecallSceneRequest): DefaultSuccess = 5;
+ /** Get an unused scene identifier when no commissioning tool is in the network, or for a commissioning tool to get the used scene identifiers within a certain group */
+ fabric command GetSceneMembership(GetSceneMembershipRequest): GetSceneMembershipResponse = 6;
+ /** Allows a scene to be added using a finer scene transition time than the AddScene command. */
+ fabric command EnhancedAddScene(EnhancedAddSceneRequest): EnhancedAddSceneResponse = 64;
+ /** Allows a scene to be retrieved using a finer scene transition time than the ViewScene command */
+ fabric command EnhancedViewScene(EnhancedViewSceneRequest): EnhancedViewSceneResponse = 65;
+ /** Allows a client to efficiently copy scenes from one group/scene identifier pair to another group/scene identifier pair. */
+ fabric command CopyScene(CopySceneRequest): CopySceneResponse = 66;
}
/** An interface to a generic way to secure a door */
@@ -3564,6 +3564,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -3625,6 +3635,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -3634,6 +3648,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -3672,6 +3691,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -3727,6 +3802,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -3758,14 +3847,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
@@ -5692,7 +5812,8 @@ internal cluster UnitTesting = 4294048773 {
int8u fillCharacter = 2;
}
- /** Simple command without any parameters and without a specific response */
+ /** Simple command without any parameters and without a specific response.
+ To aid in unit testing, this command will re-initialize attribute storage to defaults. */
command Test(): DefaultSuccess = 0;
/** Simple command without any parameters and without a specific response not handled by the server */
command TestNotHandled(): DefaultSuccess = 1;
@@ -5940,6 +6061,9 @@ endpoint 0 {
ram attribute lastNetworkingStatus;
ram attribute lastNetworkID;
ram attribute lastConnectErrorValue;
+ callback attribute supportedWiFiBands;
+ callback attribute supportedThreadFeatures;
+ callback attribute threadVersion;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
@@ -6158,33 +6282,6 @@ endpoint 1 {
handle command AddGroupIfIdentifying;
}
- server cluster Scenes {
- ram attribute nameSupport default = 0x80;
- ram attribute lastConfiguredBy;
- ram attribute sceneTableSize default = 16;
- callback attribute fabricSceneInfo;
- callback attribute generatedCommandList;
- callback attribute acceptedCommandList;
- callback attribute eventList;
- callback attribute attributeList;
- ram attribute featureMap default = 15;
- ram attribute clusterRevision default = 5;
-
- handle command AddScene;
- handle command AddSceneResponse;
- handle command ViewScene;
- handle command ViewSceneResponse;
- handle command RemoveScene;
- handle command RemoveSceneResponse;
- handle command RemoveAllScenes;
- handle command RemoveAllScenesResponse;
- handle command StoreScene;
- handle command StoreSceneResponse;
- handle command RecallScene;
- handle command GetSceneMembership;
- handle command GetSceneMembershipResponse;
- }
-
server cluster OnOff {
persist attribute onOff default = 0x00;
ram attribute globalSceneControl default = 0x01;
@@ -6315,6 +6412,33 @@ endpoint 1 {
handle command SetTemperature;
}
+ server cluster ScenesManagement {
+ ram attribute nameSupport default = 0x80;
+ ram attribute lastConfiguredBy;
+ ram attribute sceneTableSize default = 16;
+ callback attribute fabricSceneInfo;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 15;
+ ram attribute clusterRevision default = 5;
+
+ handle command AddScene;
+ handle command AddSceneResponse;
+ handle command ViewScene;
+ handle command ViewSceneResponse;
+ handle command RemoveScene;
+ handle command RemoveSceneResponse;
+ handle command RemoveAllScenes;
+ handle command RemoveAllScenesResponse;
+ handle command StoreScene;
+ handle command StoreSceneResponse;
+ handle command RecallScene;
+ handle command GetSceneMembership;
+ handle command GetSceneMembershipResponse;
+ }
+
server cluster DoorLock {
emits event DoorLockAlarm;
emits event LockOperation;
@@ -6718,32 +6842,6 @@ endpoint 2 {
handle command AddGroupIfIdentifying;
}
- server cluster Scenes {
- ram attribute nameSupport default = 0x80;
- ram attribute sceneTableSize default = 16;
- callback attribute fabricSceneInfo;
- callback attribute generatedCommandList;
- callback attribute acceptedCommandList;
- callback attribute eventList;
- callback attribute attributeList;
- ram attribute featureMap default = 15;
- ram attribute clusterRevision default = 5;
-
- handle command AddScene;
- handle command AddSceneResponse;
- handle command ViewScene;
- handle command ViewSceneResponse;
- handle command RemoveScene;
- handle command RemoveSceneResponse;
- handle command RemoveAllScenes;
- handle command RemoveAllScenesResponse;
- handle command StoreScene;
- handle command StoreSceneResponse;
- handle command RecallScene;
- handle command GetSceneMembership;
- handle command GetSceneMembershipResponse;
- }
-
server cluster OnOff {
ram attribute onOff default = 0x00;
ram attribute globalSceneControl default = 1;
@@ -6791,6 +6889,32 @@ endpoint 2 {
ram attribute clusterRevision default = 2;
}
+ server cluster ScenesManagement {
+ ram attribute nameSupport default = 0x80;
+ ram attribute sceneTableSize default = 16;
+ callback attribute fabricSceneInfo;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ ram attribute featureMap default = 15;
+ ram attribute clusterRevision default = 5;
+
+ handle command AddScene;
+ handle command AddSceneResponse;
+ handle command ViewScene;
+ handle command ViewSceneResponse;
+ handle command RemoveScene;
+ handle command RemoveSceneResponse;
+ handle command RemoveAllScenes;
+ handle command RemoveAllScenesResponse;
+ handle command StoreScene;
+ handle command StoreSceneResponse;
+ handle command RecallScene;
+ handle command GetSceneMembership;
+ handle command GetSceneMembershipResponse;
+ }
+
server cluster OccupancySensing {
ram attribute occupancy;
ram attribute occupancySensorType;
diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap
index 2ca83ff224c938..5aff52c41cca6b 100644
--- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap
+++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap
@@ -2235,6 +2235,54 @@
"maxInterval": 65534,
"reportableChange": 0
},
+ {
+ "name": "SupportedWiFiBands",
+ "code": 8,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "SupportedThreadFeatures",
+ "code": 9,
+ "mfgCode": null,
+ "side": "server",
+ "type": "ThreadCapabilitiesBitmap",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ThreadVersion",
+ "code": 10,
+ "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,
@@ -4551,8 +4599,8 @@
]
},
{
- "name": "Scenes",
- "code": 5,
+ "name": "Scenes Management",
+ "code": 98,
"mfgCode": null,
"define": "SCENES_CLUSTER",
"side": "server",
@@ -6851,7 +6899,7 @@
"code": 0,
"mfgCode": null,
"side": "server",
- "type": "int16s",
+ "type": "temperature",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
@@ -6899,7 +6947,7 @@
"code": 28,
"mfgCode": null,
"side": "server",
- "type": "enum8",
+ "type": "SystemModeEnum",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
@@ -10787,8 +10835,8 @@
]
},
{
- "name": "Scenes",
- "code": 5,
+ "name": "Scenes Management",
+ "code": 98,
"mfgCode": null,
"define": "SCENES_CLUSTER",
"side": "server",
diff --git a/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt b/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt
index cb38515a1a8770..cae8b64315a232 100644
--- a/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt
+++ b/examples/all-clusters-minimal-app/esp32/main/CMakeLists.txt
@@ -81,6 +81,7 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/diagnostic-logs-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/door-lock-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/occupancy-sensor-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/device-energy-management-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/energy-evse-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/ethernet-network-diagnostics-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/localization-configuration-server"
diff --git a/examples/all-clusters-minimal-app/telink/CMakeLists.txt b/examples/all-clusters-minimal-app/telink/CMakeLists.txt
index a7bb51ba0e67fe..a68471e379a842 100644
--- a/examples/all-clusters-minimal-app/telink/CMakeLists.txt
+++ b/examples/all-clusters-minimal-app/telink/CMakeLists.txt
@@ -70,10 +70,6 @@ target_include_directories(app PRIVATE
${TELINK_COMMON}/common/include
${TELINK_COMMON}/util/include)
-add_definitions(
- "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER="
-)
-
target_sources(app PRIVATE
src/AppTask.cpp
${ALL_CLUSTERS_COMMON_DIR}/src/smco-stub.cpp
@@ -90,3 +86,7 @@ chip_configure_data_model(app
INCLUDE_SERVER
ZAP_FILE ${CMAKE_CURRENT_SOURCE_DIR}/../all-clusters-common/all-clusters-minimal-app.zap
)
+
+if(CONFIG_BOOTLOADER_MCUBOOT)
+ target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp)
+endif()
diff --git a/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/SelectActionFragment.kt b/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/SelectActionFragment.kt
index a597bd934514e7..f935ab37926927 100644
--- a/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/SelectActionFragment.kt
+++ b/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/SelectActionFragment.kt
@@ -172,7 +172,7 @@ class SelectActionFragment : Fragment() {
/** Notifies listener of Scan QR code button click. */
private fun handleScanQrCodeClicked() {
- showFragment(BarcodeFragment.newInstance(), false)
+ showFragment(BarcodeFragment.newInstance())
}
/** Notifies listener of Light On/Off & Level Cluster button click. */
@@ -221,24 +221,24 @@ class SelectActionFragment : Fragment() {
}
private fun handleOTAProviderClicked() {
- showFragment(OtaProviderClientFragment.newInstance(), false)
+ showFragment(OtaProviderClientFragment.newInstance())
}
/** Notifies listener of provision-WiFi-credentials button click. */
private fun handleProvisionWiFiCredentialsClicked() {
getCallback()?.SetNetworkType(ProvisionNetworkType.WIFI)
- showFragment(BarcodeFragment.newInstance(), false)
+ showFragment(BarcodeFragment.newInstance())
}
/** Notifies listener of provision-Thread-credentials button click. */
private fun handleProvisionThreadCredentialsClicked() {
getCallback()?.SetNetworkType(ProvisionNetworkType.THREAD)
- showFragment(BarcodeFragment.newInstance(), false)
+ showFragment(BarcodeFragment.newInstance())
}
/** Notifies listener of provision-custom-flow button click. */
private fun handleProvisionCustomFlowClicked() {
- showFragment(BarcodeFragment.newInstance(), false)
+ showFragment(BarcodeFragment.newInstance())
}
private fun handleGroupSettingClicked() {
diff --git a/examples/bridge-app/telink/CMakeLists.txt b/examples/bridge-app/telink/CMakeLists.txt
index 1b65dc3bf543e7..f4da959953def8 100644
--- a/examples/bridge-app/telink/CMakeLists.txt
+++ b/examples/bridge-app/telink/CMakeLists.txt
@@ -69,11 +69,6 @@ target_include_directories(app PRIVATE
${TELINK_COMMON}/util/include
${TELINK_COMMON}/app/include)
-add_definitions(
- "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER="
- -DCHIP_DEVICE_CONFIG_DYNAMIC_ENDPOINT_COUNT=16
-)
-
target_sources(app PRIVATE
src/AppTask.cpp
src/ZclCallbacks.cpp
@@ -90,3 +85,7 @@ chip_configure_data_model(app
INCLUDE_SERVER
ZAP_FILE ${CMAKE_CURRENT_SOURCE_DIR}/../bridge-common/bridge-app.zap
)
+
+if(CONFIG_BOOTLOADER_MCUBOOT)
+ target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp)
+endif()
diff --git a/examples/chef/common/chef-fan-control-manager.cpp b/examples/chef/common/chef-fan-control-manager.cpp
index 3be024c33d4d5b..56576febd693d4 100644
--- a/examples/chef/common/chef-fan-control-manager.cpp
+++ b/examples/chef/common/chef-fan-control-manager.cpp
@@ -96,7 +96,7 @@ Status ChefFanControlManager::HandleStep(StepDirectionEnum aDirection, bool aWra
status = SpeedSetting::Get(mEndpoint, speedSetting);
VerifyOrReturnError(EMBER_ZCL_STATUS_SUCCESS == status, Status::InvalidCommand);
- uint8_t newSpeedSetting;
+ uint8_t newSpeedSetting = speedSetting.ValueOr(0);
uint8_t speedValue = speedSetting.ValueOr(speedCurrent);
const uint8_t kLowestSpeed = aLowestOff ? 0 : 1;
diff --git a/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.matter b/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.matter
index 6066dc34eedb2e..df276f6ab3fce3 100644
--- a/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.matter
+++ b/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.matter
@@ -1177,6 +1177,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -1238,6 +1248,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -1247,6 +1261,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -1285,6 +1304,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -1340,6 +1415,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1371,14 +1460,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
diff --git a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter
index 741d7b25fef7db..ed16842ca4a281 100644
--- a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter
+++ b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter
@@ -1534,6 +1534,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -1595,6 +1605,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -1604,6 +1618,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -1642,6 +1661,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -1697,6 +1772,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1728,14 +1817,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
diff --git a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
index fb79f75aa6244a..fa836fe8b0c5e2 100644
--- a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
+++ b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
@@ -1005,6 +1005,7 @@ cluster RvcRunMode = 84 {
enum ModeTag : enum16 {
kIdle = 16384;
kCleaning = 16385;
+ kMapping = 16386;
}
enum StatusCode : enum8 {
@@ -1177,6 +1178,8 @@ cluster RvcOperationalState = 97 {
command Start(): OperationalCommandResponse = 2;
/** Upon receipt, the device SHALL resume its operation from the point it was at when it received the Pause command, or from the point when it was paused by means outside of this cluster (for example by manual button press). */
command Resume(): OperationalCommandResponse = 3;
+ /** On receipt of this command, the device SHALL start seeking the charging dock, if possible in the current state of the device. */
+ command GoHome(): OperationalCommandResponse = 128;
}
endpoint 0 {
diff --git a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter
index af70a8875073c9..6797456a6b6091 100644
--- a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter
+++ b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter
@@ -1117,6 +1117,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -1178,6 +1188,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -1187,6 +1201,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -1225,6 +1244,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -1280,6 +1355,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1311,14 +1400,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
diff --git a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter
index 26bd437442d209..30163a05f14a9a 100644
--- a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter
+++ b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter
@@ -1337,6 +1337,16 @@ cluster Thermostat = 513 {
kCoolingAndHeatingWithReheat = 5;
}
+ enum PresetScenarioEnum : enum8 {
+ kUnspecified = 0;
+ kOccupied = 1;
+ kUnoccupied = 2;
+ kSleep = 3;
+ kWake = 4;
+ kVacation = 5;
+ kUserDefined = 6;
+ }
+
enum SetpointChangeSourceEnum : enum8 {
kManual = 0;
kSchedule = 1;
@@ -1398,6 +1408,10 @@ cluster Thermostat = 513 {
kSetback = 0x10;
kAutoMode = 0x20;
kLocalTemperatureNotExposed = 0x40;
+ kMatterScheduleConfiguration = 0x80;
+ kPresets = 0x100;
+ kSetpoints = 0x200;
+ kQueuedPresetsSupported = 0x400;
}
bitmap HVACSystemTypeBitmap : bitmap8 {
@@ -1407,6 +1421,11 @@ cluster Thermostat = 513 {
kHeatingUsesFuel = 0x20;
}
+ bitmap PresetTypeFeaturesBitmap : bitmap16 {
+ kAutomatic = 0x1;
+ kSupportsNames = 0x2;
+ }
+
bitmap ProgrammingOperationModeBitmap : bitmap8 {
kScheduleActive = 0x1;
kAutoRecovery = 0x2;
@@ -1445,6 +1464,62 @@ cluster Thermostat = 513 {
kCoolSetpointPresent = 0x2;
}
+ bitmap ScheduleTypeFeaturesBitmap : bitmap16 {
+ kSupportsPresets = 0x1;
+ kSupportsSetpoints = 0x2;
+ kSupportsNames = 0x4;
+ kSupportsOff = 0x8;
+ }
+
+ bitmap TemperatureSetpointHoldPolicyBitmap : bitmap8 {
+ kHoldDurationElapsed = 0x1;
+ kHoldDurationElapsedOrPresetChanged = 0x2;
+ }
+
+ struct ScheduleTransitionStruct {
+ ScheduleDayOfWeekBitmap dayOfWeek = 0;
+ int16u transitionTime = 1;
+ optional octet_string<16> presetHandle = 2;
+ optional SystemModeEnum systemMode = 3;
+ optional temperature coolingSetpoint = 4;
+ optional temperature heatingSetpoint = 5;
+ }
+
+ struct ScheduleStruct {
+ nullable octet_string<16> scheduleHandle = 0;
+ SystemModeEnum systemMode = 1;
+ optional char_string<64> name = 2;
+ optional octet_string<16> presetHandle = 3;
+ ScheduleTransitionStruct transitions[] = 4;
+ optional nullable boolean builtIn = 5;
+ }
+
+ struct PresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ PresetScenarioEnum presetScenario = 1;
+ optional nullable char_string<64> name = 2;
+ optional temperature coolingSetpoint = 3;
+ optional temperature heatingSetpoint = 4;
+ nullable boolean builtIn = 5;
+ }
+
+ struct PresetTypeStruct {
+ PresetScenarioEnum presetScenario = 0;
+ int8u numberOfPresets = 1;
+ PresetTypeFeaturesBitmap presetTypeFeatures = 2;
+ }
+
+ struct QueuedPresetStruct {
+ nullable octet_string<16> presetHandle = 0;
+ nullable epoch_s transitionTimestamp = 1;
+ }
+
+ struct ScheduleTypeStruct {
+ SystemModeEnum systemMode = 0;
+ int8u numberOfSchedules = 1;
+ ScheduleTypeFeaturesBitmap scheduleTypeFeatures = 2;
+ }
+
struct WeeklyScheduleTransitionStruct {
int16u transitionTime = 0;
nullable temperature heatSetpoint = 1;
@@ -1500,6 +1575,20 @@ cluster Thermostat = 513 {
attribute access(write: manage) optional ACLouverPositionEnum ACLouverPosition = 69;
readonly attribute optional nullable temperature ACCoilTemperature = 70;
attribute access(write: manage) optional ACCapacityFormatEnum ACCapacityformat = 71;
+ readonly attribute optional PresetTypeStruct presetTypes[] = 72;
+ readonly attribute optional ScheduleTypeStruct scheduleTypes[] = 73;
+ readonly attribute optional int8u numberOfPresets = 74;
+ readonly attribute optional int8u numberOfSchedules = 75;
+ readonly attribute optional int8u numberOfScheduleTransitions = 76;
+ readonly attribute optional nullable int8u numberOfScheduleTransitionPerDay = 77;
+ readonly attribute optional nullable octet_string<16> activePresetHandle = 78;
+ readonly attribute optional nullable octet_string<16> activeScheduleHandle = 79;
+ attribute access(write: manage) optional PresetStruct presets[] = 80;
+ attribute access(write: manage) optional ScheduleStruct schedules[] = 81;
+ readonly attribute optional boolean presetsSchedulesEditable = 82;
+ readonly attribute optional TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 83;
+ readonly attribute optional nullable epoch_s setpointHoldExpiryTimestamp = 84;
+ readonly attribute optional nullable QueuedPresetStruct queuedPreset = 85;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1531,14 +1620,45 @@ cluster Thermostat = 513 {
ScheduleModeBitmap modeToReturn = 1;
}
+ request struct SetActiveScheduleRequestRequest {
+ octet_string<16> scheduleHandle = 0;
+ }
+
+ request struct SetActivePresetRequestRequest {
+ octet_string<16> presetHandle = 0;
+ optional int16u delayMinutes = 1;
+ }
+
+ request struct StartPresetsSchedulesEditRequestRequest {
+ int16u timeoutSeconds = 0;
+ }
+
+ request struct SetTemperatureSetpointHoldPolicyRequest {
+ TemperatureSetpointHoldPolicyBitmap temperatureSetpointHoldPolicy = 0;
+ }
+
/** Command description for SetpointRaiseLower */
command SetpointRaiseLower(SetpointRaiseLowerRequest): DefaultSuccess = 0;
/** Command description for SetWeeklySchedule */
command access(invoke: manage) SetWeeklySchedule(SetWeeklyScheduleRequest): DefaultSuccess = 1;
/** Command description for GetWeeklySchedule */
command GetWeeklySchedule(GetWeeklyScheduleRequest): GetWeeklyScheduleResponse = 2;
- /** The Clear Weekly Schedule command is used to clear the weekly schedule. */
+ /** This command is used to clear the weekly schedule. The ClearWeeklySchedule command has no payload. */
command access(invoke: manage) ClearWeeklySchedule(): DefaultSuccess = 3;
+ /** This command is used to set the active schedule. */
+ command SetActiveScheduleRequest(SetActiveScheduleRequestRequest): DefaultSuccess = 5;
+ /** This command is used to set the active preset. */
+ command SetActivePresetRequest(SetActivePresetRequestRequest): DefaultSuccess = 6;
+ /** This command is used to start editing the presets and schedules. */
+ command access(invoke: manage) StartPresetsSchedulesEditRequest(StartPresetsSchedulesEditRequestRequest): DefaultSuccess = 7;
+ /** This command is used to cancel editing presets and schedules. */
+ command access(invoke: manage) CancelPresetsSchedulesEditRequest(): DefaultSuccess = 8;
+ /** This command is used to notify the server that all edits are done and should be committed. */
+ command access(invoke: manage) CommitPresetsSchedulesRequest(): DefaultSuccess = 9;
+ /** This command is sent to cancel a queued preset. */
+ command access(invoke: manage) CancelSetActivePresetRequest(): DefaultSuccess = 10;
+ /** This command sets the set point hold policy. */
+ command SetTemperatureSetpointHoldPolicy(SetTemperatureSetpointHoldPolicyRequest): DefaultSuccess = 11;
}
/** An interface for controlling a fan in a heating/cooling system. */
diff --git a/examples/chef/devices/template.zap b/examples/chef/devices/template.zap
index c53936a568b663..7987c79179e375 100644
--- a/examples/chef/devices/template.zap
+++ b/examples/chef/devices/template.zap
@@ -2276,8 +2276,8 @@
]
},
{
- "name": "Scenes",
- "code": 5,
+ "name": "Scenes Management",
+ "code": 98,
"mfgCode": null,
"define": "SCENES_CLUSTER",
"side": "server",
diff --git a/examples/chef/telink/CMakeLists.txt b/examples/chef/telink/CMakeLists.txt
index 7722f26a11d96e..5d30d424ea3dfd 100755
--- a/examples/chef/telink/CMakeLists.txt
+++ b/examples/chef/telink/CMakeLists.txt
@@ -92,10 +92,6 @@ if (CONFIG_CHIP_LIB_SHELL)
)
endif()
-add_definitions(
- "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER="
-)
-
target_sources(app PRIVATE
src/AppTask.cpp
${TELINK_COMMON}/common/src/mainCommon.cpp
@@ -113,6 +109,10 @@ chip_configure_data_model(app
ZAP_FILE ${CHEF}/devices/${SAMPLE_NAME}.zap
)
+if(CONFIG_BOOTLOADER_MCUBOOT)
+ target_sources(app PRIVATE ${TELINK_COMMON}/util/src/OTAUtil.cpp)
+endif()
+
if (CONFIG_CHIP_PW_RPC)
# Make all targets created below depend on zephyr_interface to inherit MCU-related compilation flags
diff --git a/examples/common/pigweed/rpc_console/py/BUILD.gn b/examples/common/pigweed/rpc_console/py/BUILD.gn
index d250129dca13c5..5c74b7b2599544 100644
--- a/examples/common/pigweed/rpc_console/py/BUILD.gn
+++ b/examples/common/pigweed/rpc_console/py/BUILD.gn
@@ -37,6 +37,7 @@ pw_python_package("chip_rpc") {
"$dir_pw_log_tokenized/py",
"$dir_pw_protobuf_compiler/py",
"$dir_pw_rpc/py",
+ "$dir_pw_system/py",
"$dir_pw_tokenizer/py",
"${chip_root}/examples/common/pigweed:attributes_service.python",
"${chip_root}/examples/common/pigweed:button_service.python",
diff --git a/examples/common/pigweed/rpc_console/py/chip_rpc/console.py b/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
index 7880d579fccf52..6d2b06fd73208f 100644
--- a/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
+++ b/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
@@ -29,35 +29,20 @@
rpcs - used to invoke RPCs
device - the serial device used for communication
- client - the pw_rpc.Client
+ client - the HDLC rpc client
protos - protocol buffer messages indexed by proto package
An example RPC command:
- rpcs.chip.rpc.DeviceCommon.GetDeviceInfo()
+ rpcs.chip.rpc.Device.GetDeviceInfo()
+ device.rpcs.chip.rpc.Device.GetDeviceInfo()
"""
-
import argparse
-import logging
-import re
import sys
-import threading
-from collections import namedtuple
-from concurrent.futures import ThreadPoolExecutor
-from inspect import cleandoc
-from typing import Any, BinaryIO, Callable, Collection
+from pathlib import Path
+from typing import Any, Collection
-import pw_cli.log
-from chip_rpc.plugins.device_toolbar import DeviceToolbar
-from chip_rpc.plugins.helper_scripts import HelperScripts
-from pw_console import PwConsoleEmbed, socket_client
-from pw_console.__main__ import create_temp_log_file
-from pw_console.pyserial_wrapper import SerialWithLogging
-from pw_hdlc.rpc import HdlcRpcClient, SelectableReader, SerialReader, default_channels
-from pw_rpc import callback_client
-from pw_rpc.console_tools.console import ClientInfo, flattened_rpc_completions
-from pw_tokenizer import tokens
-from pw_tokenizer.database import LoadTokenDatabases
-from pw_tokenizer.detokenize import Detokenizer
+import pw_system.console
+from pw_hdlc import rpc
# Protos
# isort: off
@@ -72,24 +57,6 @@
from thread_service import thread_service_pb2
from wifi_service import wifi_service_pb2
-_LOG = logging.getLogger(__name__)
-_DEVICE_LOG = logging.getLogger('rpc_device')
-
-PW_RPC_MAX_PACKET_SIZE = 256
-SOCKET_SERVER = 'localhost'
-SOCKET_PORT = 33000
-
-PROTOS = [attributes_service_pb2,
- button_service_pb2,
- descriptor_service_pb2,
- device_service_pb2,
- echo_pb2,
- lighting_service_pb2,
- locking_service_pb2,
- ot_cli_service_pb2,
- thread_service_pb2,
- wifi_service_pb2]
-
def _parse_args():
"""Parses and returns the command line arguments."""
@@ -116,7 +83,7 @@ def _parse_args():
parser.add_argument("--token-databases",
metavar='elf_or_token_database',
nargs="+",
- action=LoadTokenDatabases,
+ type=Path,
help="Path to tokenizer database csv file(s).")
group.add_argument('-s',
'--socket-addr',
@@ -126,227 +93,55 @@ def _parse_args():
return parser.parse_args()
-def _start_ipython_raw_terminal() -> None:
- """Starts an interactive IPython terminal with preset variables. This raw
- terminal does not use HDLC and provides no RPC functionality, this is
- just a serial log viewer."""
- local_variables = dict(
- LOG=_DEVICE_LOG,
- )
-
- welcome_message = cleandoc("""
- Welcome to the CHIP Console!
-
- This has been started in raw serial mode,
- and all RPC functionality is disabled.
-
- Press F1 for help.
- """)
-
- interactive_console = PwConsoleEmbed(
- global_vars=local_variables,
- local_vars=None,
- loggers={
- 'Device Logs': [_DEVICE_LOG],
- 'Host Logs': [logging.getLogger()],
- 'Serial Debug': [logging.getLogger('pw_console.serial_debug_logger')],
- },
- repl_startup_message=welcome_message,
- help_text=__doc__,
- app_title="CHIP Console",
- )
-
- interactive_console.hide_windows('Host Logs')
- interactive_console.hide_windows('Serial Debug')
- interactive_console.hide_windows('Python Repl')
-
- # Setup Python logger propagation
- interactive_console.setup_python_logging()
- # Don't send device logs to the root logger.
- _DEVICE_LOG.propagate = False
- interactive_console.embed()
-
-
-def _start_ipython_hdlc_terminal(client: HdlcRpcClient) -> None:
- """Starts an interactive IPython terminal with preset variables."""
- local_variables = dict(
- client=client,
- channel_client=client.client.channel(1),
- rpcs=client.client.channel(1).rpcs,
- scripts=HelperScripts(client.client.channel(1).rpcs),
- protos=client.protos.packages,
- # Include the active pane logger for creating logs in the repl.
- LOG=_DEVICE_LOG,
- )
-
- client_info = ClientInfo('channel_client',
- client.client.channel(1).rpcs, client.client)
- completions = flattened_rpc_completions([client_info])
-
- welcome_message = cleandoc("""
- Welcome to the CHIP RPC Console!
-
- Press F1 for help.
- Example commands:
-
- rpcs.chip.rpc.Device.GetDeviceInfo()
-
- LOG.warning('Message appears console log window.')
- """)
-
- interactive_console = PwConsoleEmbed(
- global_vars=local_variables,
- local_vars=None,
- loggers={
- 'Device Logs': [_DEVICE_LOG],
- 'Host Logs': [logging.getLogger()],
- 'Serial Debug': [logging.getLogger('pw_console.serial_debug_logger')],
- },
- repl_startup_message=welcome_message,
- help_text=__doc__,
- app_title="CHIP Console",
- )
-
- interactive_console.add_sentence_completer(completions)
- interactive_console.add_bottom_toolbar(
- DeviceToolbar(client.client.channel(1).rpcs))
-
- interactive_console.hide_windows('Host Logs')
- interactive_console.hide_windows('Serial Debug')
-
- # Setup Python logger propagation
- interactive_console.setup_python_logging()
- # Don't send device logs to the root logger.
- _DEVICE_LOG.propagate = False
- with client:
- interactive_console.embed()
-
-
-def write_to_output(data: bytes,
- unused_output: BinaryIO = sys.stdout.buffer,
- detokenizer=None):
- log_line = data
- RegexStruct = namedtuple('RegexStruct', 'platform type regex match_num')
- LEVEL_MAPPING = {"I": logging.INFO, "W": logging.WARNING, "P": logging.INFO,
- "E": logging.ERROR, "F": logging.FATAL, "V": logging.DEBUG, "D": logging.DEBUG,
- "": logging.INFO, "": logging.DEBUG, "": logging.ERROR,
- "": logging.INFO, "": logging.WARNING,
- "": logging.ERROR, "": logging.DEBUG,
- "ERR": logging.ERROR, "DBG": logging.DEBUG, "INF": logging.INFO}
-
- ESP_CHIP_REGEX = r"(?P[IWEFV]) \((?P