From d165f6274a813ce7e471fd6822a5ad80dc7f3477 Mon Sep 17 00:00:00 2001 From: Tennessee Carmel-Veilleux Date: Tue, 31 Oct 2023 10:50:04 -0400 Subject: [PATCH] Add general diagnostics cluster Matter 1.3 XML changes (#30091) - Added TimeSnapshot command - Added necessary comments about other changes needed - Regenerated zap - Put necessary scaffolding for TimeSnapshot command - Updated TC-DGEN-1.1/TC-DGEN-2.1 tests to work with updated revision Issue #30096 --------- Co-authored-by: tennessee.carmelveilleux@gmail.com Co-authored-by: Restyled.io --- .../air-purifier-app.matter | 10 +- .../air-purifier-common/air-purifier-app.zap | 18 +- .../air-quality-sensor-app.matter | 10 +- .../air-quality-sensor-app.zap | 18 +- .../all-clusters-app.matter | 10 +- .../all-clusters-common/all-clusters-app.zap | 18 +- .../all-clusters-minimal-app.matter | 12 +- .../all-clusters-minimal-app.zap | 34 +++- .../bridge-common/bridge-app.matter | 10 +- .../bridge-app/bridge-common/bridge-app.zap | 18 +- ...p_rootnode_dimmablelight_bCwGYSDpoe.matter | 10 +- ...noip_rootnode_dimmablelight_bCwGYSDpoe.zap | 18 +- ...umiditysensor_thermostat_56de3d5f45.matter | 10 +- ...r_humiditysensor_thermostat_56de3d5f45.zap | 18 +- ...ootnode_airqualitysensor_e63187f6c9.matter | 10 +- .../rootnode_airqualitysensor_e63187f6c9.zap | 18 +- ...ootnode_basicvideoplayer_0ff86e943b.matter | 10 +- .../rootnode_basicvideoplayer_0ff86e943b.zap | 18 +- ...de_colortemperaturelight_hbUnzYVeyn.matter | 10 +- ...tnode_colortemperaturelight_hbUnzYVeyn.zap | 18 +- .../rootnode_contactsensor_lFAGG1bfRO.matter | 10 +- .../rootnode_contactsensor_lFAGG1bfRO.zap | 18 +- .../rootnode_dimmablelight_bCwGYSDpoe.matter | 10 +- .../rootnode_dimmablelight_bCwGYSDpoe.zap | 18 +- .../rootnode_dishwasher_cc105034fe.matter | 10 +- .../rootnode_dishwasher_cc105034fe.zap | 18 +- .../rootnode_doorlock_aNKYAreMXE.matter | 10 +- .../devices/rootnode_doorlock_aNKYAreMXE.zap | 18 +- ...tnode_extendedcolorlight_8lcaaYJVAa.matter | 10 +- ...rootnode_extendedcolorlight_8lcaaYJVAa.zap | 18 +- .../devices/rootnode_fan_7N2TobIlOX.matter | 10 +- .../chef/devices/rootnode_fan_7N2TobIlOX.zap | 18 +- .../rootnode_flowsensor_1zVxHedlaV.matter | 10 +- .../rootnode_flowsensor_1zVxHedlaV.zap | 18 +- .../rootnode_genericswitch_9866e35d0b.matter | 10 +- .../rootnode_genericswitch_9866e35d0b.zap | 18 +- ...tnode_heatingcoolingunit_ncdGai1E5a.matter | 10 +- ...rootnode_heatingcoolingunit_ncdGai1E5a.zap | 18 +- .../rootnode_humiditysensor_Xyj4gda6Hb.matter | 10 +- .../rootnode_humiditysensor_Xyj4gda6Hb.zap | 18 +- .../rootnode_laundrywasher_fb10d238c8.matter | 10 +- .../rootnode_laundrywasher_fb10d238c8.zap | 18 +- .../rootnode_lightsensor_lZQycTFcJK.matter | 10 +- .../rootnode_lightsensor_lZQycTFcJK.zap | 18 +- ...rootnode_occupancysensor_iHyVgifZuo.matter | 10 +- .../rootnode_occupancysensor_iHyVgifZuo.zap | 18 +- .../rootnode_onofflight_bbs1b7IaOV.matter | 10 +- .../rootnode_onofflight_bbs1b7IaOV.zap | 18 +- .../rootnode_onofflight_samplemei.matter | 10 +- .../devices/rootnode_onofflight_samplemei.zap | 18 +- ...ootnode_onofflightswitch_FsPlMr090Q.matter | 10 +- .../rootnode_onofflightswitch_FsPlMr090Q.zap | 18 +- ...rootnode_onoffpluginunit_Wtf8ss5EBY.matter | 10 +- .../rootnode_onoffpluginunit_Wtf8ss5EBY.zap | 18 +- .../rootnode_pressuresensor_s0qC9wLH4k.matter | 10 +- .../rootnode_pressuresensor_s0qC9wLH4k.zap | 18 +- .../devices/rootnode_pump_5f904818cc.matter | 12 +- .../chef/devices/rootnode_pump_5f904818cc.zap | 34 +++- .../devices/rootnode_pump_a811bb33a0.matter | 12 +- .../chef/devices/rootnode_pump_a811bb33a0.zap | 34 +++- ...eraturecontrolledcabinet_ffdb696680.matter | 10 +- ...emperaturecontrolledcabinet_ffdb696680.zap | 18 +- ...ode_roboticvacuumcleaner_1807ff0c49.matter | 10 +- ...otnode_roboticvacuumcleaner_1807ff0c49.zap | 18 +- ...tnode_roomairconditioner_9cf3607804.matter | 10 +- ...rootnode_roomairconditioner_9cf3607804.zap | 18 +- .../rootnode_smokecoalarm_686fe0dcb8.matter | 10 +- .../rootnode_smokecoalarm_686fe0dcb8.zap | 18 +- .../rootnode_speaker_RpzeXdimqA.matter | 10 +- .../devices/rootnode_speaker_RpzeXdimqA.zap | 18 +- ...otnode_temperaturesensor_Qy1zkNW7c3.matter | 10 +- .../rootnode_temperaturesensor_Qy1zkNW7c3.zap | 18 +- .../rootnode_thermostat_bm3fb8dhYi.matter | 10 +- .../rootnode_thermostat_bm3fb8dhYi.zap | 18 +- .../rootnode_windowcovering_RLCxaGi9Yx.matter | 10 +- .../rootnode_windowcovering_RLCxaGi9Yx.zap | 18 +- examples/chef/devices/template.zap | 18 +- .../test_files/sample_zap_file.zap | 2 +- .../contact-sensor-app.matter | 10 +- .../contact-sensor-app.zap | 18 +- .../dishwasher-common/dishwasher-app.matter | 10 +- .../dishwasher-common/dishwasher-app.zap | 18 +- .../light-switch-app.matter | 10 +- .../light-switch-common/light-switch-app.zap | 18 +- .../data_model/lighting-app-ethernet.matter | 10 +- .../data_model/lighting-app-ethernet.zap | 18 +- .../data_model/lighting-app-thread.matter | 10 +- .../data_model/lighting-app-thread.zap | 18 +- .../data_model/lighting-app-wifi.matter | 10 +- .../data_model/lighting-app-wifi.zap | 18 +- .../lighting-common/lighting-app.matter | 10 +- .../lighting-common/lighting-app.zap | 18 +- .../nxp/zap/lighting-on-off.matter | 12 +- .../lighting-app/nxp/zap/lighting-on-off.zap | 34 +++- examples/lighting-app/qpg/zap/light.matter | 10 +- examples/lighting-app/qpg/zap/light.zap | 18 +- .../data_model/lighting-thread-app.matter | 10 +- .../silabs/data_model/lighting-thread-app.zap | 18 +- .../data_model/lighting-wifi-app.matter | 10 +- .../silabs/data_model/lighting-wifi-app.zap | 18 +- examples/lock-app/lock-common/lock-app.matter | 10 +- examples/lock-app/lock-common/lock-app.zap | 18 +- examples/lock-app/nxp/zap/lock-app.matter | 12 +- examples/lock-app/nxp/zap/lock-app.zap | 34 +++- examples/lock-app/qpg/zap/lock.matter | 10 +- examples/lock-app/qpg/zap/lock.zap | 18 +- .../ota-provider-app.matter | 10 +- .../ota-provider-common/ota-provider-app.zap | 18 +- .../ota-requestor-app.matter | 10 +- .../ota-requestor-app.zap | 18 +- .../placeholder/linux/apps/app1/config.matter | 10 +- .../placeholder/linux/apps/app1/config.zap | 18 +- .../placeholder/linux/apps/app2/config.matter | 10 +- .../placeholder/linux/apps/app2/config.zap | 18 +- examples/pump-app/pump-common/pump-app.matter | 12 +- examples/pump-app/pump-common/pump-app.zap | 34 +++- .../silabs/data_model/pump-thread-app.matter | 12 +- .../silabs/data_model/pump-thread-app.zap | 34 +++- .../silabs/data_model/pump-wifi-app.matter | 12 +- .../silabs/data_model/pump-wifi-app.zap | 34 +++- .../pump-controller-app.matter | 12 +- .../pump-controller-app.zap | 34 +++- .../refrigerator-app.matter | 10 +- .../refrigerator-common/refrigerator-app.zap | 18 +- .../resource-monitoring-app.matter | 10 +- .../resource-monitoring-app.zap | 18 +- examples/rvc-app/rvc-common/rvc-app.matter | 10 +- examples/rvc-app/rvc-common/rvc-app.zap | 18 +- .../smoke-co-alarm-app.matter | 10 +- .../smoke-co-alarm-app.zap | 18 +- .../temperature-measurement.matter | 10 +- .../temperature-measurement.zap | 18 +- .../nxp/zap/thermostat_matter_thread.matter | 10 +- .../nxp/zap/thermostat_matter_thread.zap | 18 +- .../nxp/zap/thermostat_matter_wifi.matter | 10 +- .../nxp/zap/thermostat_matter_wifi.zap | 18 +- .../thermostat-common/thermostat.matter | 10 +- .../thermostat-common/thermostat.zap | 18 +- examples/tv-app/tv-common/tv-app.matter | 10 +- examples/tv-app/tv-common/tv-app.zap | 18 +- .../tv-casting-common/tv-casting-app.matter | 10 +- .../tv-casting-common/tv-casting-app.zap | 18 +- .../virtual-device-app.matter | 10 +- .../virtual-device-app.zap | 18 +- examples/window-app/common/window-app.matter | 10 +- examples/window-app/common/window-app.zap | 18 +- .../general-diagnostics-server.cpp | 9 + .../certification/Test_TC_DGGEN_1_1.yaml | 11 +- .../certification/Test_TC_DGGEN_2_1.yaml | 4 - .../chip/general-diagnostics-cluster.xml | 34 ++-- .../data_model/controller-clusters.matter | 7 + .../chip/devicecontroller/ChipClusters.java | 15 ++ .../devicecontroller/ClusterIDMapping.java | 3 +- .../devicecontroller/ClusterInfoMapping.java | 36 ++++ .../zap-generated/CHIPInvokeCallbacks.cpp | 75 ++++++++ .../java/zap-generated/CHIPInvokeCallbacks.h | 15 ++ .../python/chip/clusters/CHIPClusters.py | 6 + .../python/chip/clusters/Objects.py | 31 ++++ .../CHIP/zap-generated/MTRBaseClusters.h | 8 + .../CHIP/zap-generated/MTRBaseClusters.mm | 28 +++ .../CHIP/zap-generated/MTRClusterConstants.h | 2 + .../CHIP/zap-generated/MTRClusters.h | 3 + .../CHIP/zap-generated/MTRClusters.mm | 31 ++++ .../zap-generated/MTRCommandPayloadsObjc.h | 49 ++++++ .../zap-generated/MTRCommandPayloadsObjc.mm | 162 ++++++++++++++++++ .../MTRCommandPayloads_Internal.h | 12 ++ .../app-common/zap-generated/callback.h | 6 + .../zap-generated/cluster-objects.cpp | 59 +++++++ .../zap-generated/cluster-objects.h | 73 ++++++++ .../app-common/zap-generated/ids/Commands.h | 8 + .../zap-generated/cluster/Commands.h | 39 +++++ .../cluster/logging/DataModelLogger.cpp | 20 +++ .../cluster/logging/DataModelLogger.h | 2 + .../zap-generated/cluster/Commands.h | 52 ++++++ .../zap-generated/test/Commands.h | 18 +- 175 files changed, 2839 insertions(+), 177 deletions(-) diff --git a/examples/air-purifier-app/air-purifier-common/air-purifier-app.matter b/examples/air-purifier-app/air-purifier-common/air-purifier-app.matter index 1f912fcd64e643..d8eae9ae77ced3 100644 --- a/examples/air-purifier-app/air-purifier-common/air-purifier-app.matter +++ b/examples/air-purifier-app/air-purifier-common/air-purifier-app.matter @@ -739,7 +739,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1883,9 +1889,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/air-purifier-app/air-purifier-common/air-purifier-app.zap b/examples/air-purifier-app/air-purifier-common/air-purifier-app.zap index c1f47b4d162a51..cc96cb04983fc4 100644 --- a/examples/air-purifier-app/air-purifier-common/air-purifier-app.zap +++ b/examples/air-purifier-app/air-purifier-common/air-purifier-app.zap @@ -1379,6 +1379,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1552,7 +1568,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.matter b/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.matter index 736803eaad9c70..ca74840f26cdd7 100644 --- a/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.matter +++ b/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.matter @@ -696,7 +696,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1886,9 +1892,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.zap b/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.zap index 13bfc7a3777a90..f459cfa6521060 100644 --- a/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.zap +++ b/examples/air-quality-sensor-app/air-quality-sensor-common/air-quality-sensor-app.zap @@ -1327,6 +1327,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1500,7 +1516,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, 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 a27629bc4da66d..ca2f4ed0bda4ab 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 @@ -1669,7 +1669,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -5399,9 +5405,11 @@ endpoint 0 { callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { 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 24e0df516f1b12..c5045d193a6d82 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 @@ -2695,6 +2695,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2932,7 +2948,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, 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 5a4a521d090db2..d80602ebfc5633 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 @@ -1475,6 +1475,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -1488,7 +1489,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -4189,15 +4196,18 @@ endpoint 0 { server cluster GeneralDiagnostics { callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { 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 b5931df6f9ca27..50ab55464e0526 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 @@ -2368,6 +2368,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2403,6 +2419,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -2509,7 +2541,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/bridge-app/bridge-common/bridge-app.matter b/examples/bridge-app/bridge-common/bridge-app.matter index 63f5eb56aa9021..694b7de74c9f38 100644 --- a/examples/bridge-app/bridge-common/bridge-app.matter +++ b/examples/bridge-app/bridge-common/bridge-app.matter @@ -1006,7 +1006,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1787,9 +1793,11 @@ endpoint 0 { callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/bridge-app/bridge-common/bridge-app.zap b/examples/bridge-app/bridge-common/bridge-app.zap index a317c4f078917e..9570644c62188a 100644 --- a/examples/bridge-app/bridge-common/bridge-app.zap +++ b/examples/bridge-app/bridge-common/bridge-app.zap @@ -1797,6 +1797,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2018,7 +2034,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter index 35637f909cfcd7..8dfc00959b33d3 100644 --- a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter +++ b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter @@ -878,7 +878,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1599,9 +1605,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.zap b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.zap index 25ac5369207196..8a9d8d4e42c31d 100644 --- a/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.zap +++ b/examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.zap @@ -1299,6 +1299,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1472,7 +1488,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, 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 7e202205baad3c..a44002cc3ca5e6 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 @@ -659,7 +659,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1848,9 +1854,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.zap b/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.zap index 972a203fbb2822..8e8c9a404ce37c 100644 --- a/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.zap +++ b/examples/chef/devices/rootnode_airpurifier_airqualitysensor_temperaturesensor_humiditysensor_thermostat_56de3d5f45.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.matter b/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.matter index 25c89264dc5cc4..7ab39684ed63a8 100644 --- a/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.matter +++ b/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.matter @@ -788,7 +788,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1823,9 +1829,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.zap b/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.zap index 9bcbe3d733ef4d..8df2dae41dc7d8 100644 --- a/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.zap +++ b/examples/chef/devices/rootnode_airqualitysensor_e63187f6c9.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter index 552d72bad13b31..a9e79fa2f29573 100644 --- a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter +++ b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.matter @@ -793,7 +793,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1593,9 +1599,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.zap b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.zap index 5f7070767c1420..f9b6772b58d4f2 100644 --- a/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.zap +++ b/examples/chef/devices/rootnode_basicvideoplayer_0ff86e943b.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter index f34d41305c3231..05203e0729239f 100644 --- a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter +++ b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.matter @@ -970,7 +970,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1644,9 +1650,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.zap b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.zap index 54a5668ca54ea3..4c96f6708498f9 100644 --- a/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.zap +++ b/examples/chef/devices/rootnode_colortemperaturelight_hbUnzYVeyn.zap @@ -1379,6 +1379,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1552,7 +1568,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter index 1f48ef322092f0..39ac6b08dba8f3 100644 --- a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter +++ b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter @@ -876,7 +876,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1320,9 +1326,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.zap b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.zap index 57d85478f48039..49c9fe342f96be 100644 --- a/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.zap +++ b/examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter index 590adf953259f3..f503073da064bb 100644 --- a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter +++ b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter @@ -1026,7 +1026,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1496,9 +1502,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.zap b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.zap index b5d2ed8cfb1508..ae7f9833be6028 100644 --- a/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.zap +++ b/examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.zap @@ -1575,6 +1575,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1748,7 +1764,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_dishwasher_cc105034fe.matter b/examples/chef/devices/rootnode_dishwasher_cc105034fe.matter index b3273daa5b68c6..45c904f19f693a 100644 --- a/examples/chef/devices/rootnode_dishwasher_cc105034fe.matter +++ b/examples/chef/devices/rootnode_dishwasher_cc105034fe.matter @@ -631,7 +631,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1165,9 +1171,11 @@ endpoint 0 { callback attribute acceptedCommandList default = 0; callback attribute attributeList default = 0; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/chef/devices/rootnode_dishwasher_cc105034fe.zap b/examples/chef/devices/rootnode_dishwasher_cc105034fe.zap index e50c640463cb6d..25a0d0d1be222b 100644 --- a/examples/chef/devices/rootnode_dishwasher_cc105034fe.zap +++ b/examples/chef/devices/rootnode_dishwasher_cc105034fe.zap @@ -1786,6 +1786,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2007,7 +2023,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter index db8fafe7e33ab9..ab0f572eb982ad 100644 --- a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter +++ b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter @@ -876,7 +876,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1792,9 +1798,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap index 6e55ee26b2f95c..fc97739ea6ec98 100644 --- a/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap +++ b/examples/chef/devices/rootnode_doorlock_aNKYAreMXE.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter index 4055d3f91948f7..5502974d07c632 100644 --- a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter +++ b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter @@ -1026,7 +1026,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1723,9 +1729,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.zap b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.zap index 5d3000d8b3ab71..62689b778ce654 100644 --- a/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.zap +++ b/examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter b/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter index 37361893fd2449..bb154d3af5b762 100644 --- a/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter +++ b/examples/chef/devices/rootnode_fan_7N2TobIlOX.matter @@ -863,7 +863,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1363,9 +1369,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_fan_7N2TobIlOX.zap b/examples/chef/devices/rootnode_fan_7N2TobIlOX.zap index 6d93d50076731c..f410f56974d928 100644 --- a/examples/chef/devices/rootnode_fan_7N2TobIlOX.zap +++ b/examples/chef/devices/rootnode_fan_7N2TobIlOX.zap @@ -1559,6 +1559,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1732,7 +1748,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter index 430af0dd820338..2ddd9204315b8e 100644 --- a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter +++ b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1325,9 +1331,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.zap b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.zap index 3ad57c090834ff..d193bb5d236e2b 100644 --- a/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.zap +++ b/examples/chef/devices/rootnode_flowsensor_1zVxHedlaV.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_genericswitch_9866e35d0b.matter b/examples/chef/devices/rootnode_genericswitch_9866e35d0b.matter index 3305b751649ce5..de09288e6eaf13 100644 --- a/examples/chef/devices/rootnode_genericswitch_9866e35d0b.matter +++ b/examples/chef/devices/rootnode_genericswitch_9866e35d0b.matter @@ -590,7 +590,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** This cluster exposes interactions with a switch device, for the purpose of using those interactions by other devices. @@ -990,9 +996,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_genericswitch_9866e35d0b.zap b/examples/chef/devices/rootnode_genericswitch_9866e35d0b.zap index 1f3613a429ed18..568708c64ea1ad 100644 --- a/examples/chef/devices/rootnode_genericswitch_9866e35d0b.zap +++ b/examples/chef/devices/rootnode_genericswitch_9866e35d0b.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter index 08aa21400773f2..03c9febba23c21 100644 --- a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter +++ b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.matter @@ -1020,7 +1020,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1672,9 +1678,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.zap b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.zap index 3995dfe9782e6a..40ea29e55ac961 100644 --- a/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.zap +++ b/examples/chef/devices/rootnode_heatingcoolingunit_ncdGai1E5a.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter index 3078ca5196ed87..a3c8e66c387718 100644 --- a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter +++ b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1325,9 +1331,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.zap b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.zap index 0e56fbaa2449b8..9837d64370ea7f 100644 --- a/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.zap +++ b/examples/chef/devices/rootnode_humiditysensor_Xyj4gda6Hb.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.matter b/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.matter index 2e9b45c1f90b23..9657c9b28e6909 100644 --- a/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.matter +++ b/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.matter @@ -631,7 +631,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1163,9 +1169,11 @@ endpoint 0 { callback attribute acceptedCommandList default = 0; callback attribute attributeList default = 0; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.zap b/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.zap index 798ae3307bd2e0..c33f7639fe02d9 100644 --- a/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.zap +++ b/examples/chef/devices/rootnode_laundrywasher_fb10d238c8.zap @@ -1786,6 +1786,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2007,7 +2023,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter index 6a9dd8678eaf30..3110d0f02c255d 100644 --- a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter +++ b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1330,9 +1336,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.zap b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.zap index a33119d44de291..4628663d2048eb 100644 --- a/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.zap +++ b/examples/chef/devices/rootnode_lightsensor_lZQycTFcJK.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter index 14000155c0a0bc..17d359a6a8e4cc 100644 --- a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter +++ b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1341,9 +1347,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.zap b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.zap index 6646443a09e65b..e0a1133e2b10c7 100644 --- a/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.zap +++ b/examples/chef/devices/rootnode_occupancysensor_iHyVgifZuo.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter index ca7dd727790bcc..fb6bcf3d62788d 100644 --- a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter +++ b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.matter @@ -1026,7 +1026,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1455,9 +1461,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.zap b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.zap index e89d7311babe0a..cce6ae448e774e 100644 --- a/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.zap +++ b/examples/chef/devices/rootnode_onofflight_bbs1b7IaOV.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_onofflight_samplemei.matter b/examples/chef/devices/rootnode_onofflight_samplemei.matter index 85933c93474d4b..69ee3097aba335 100644 --- a/examples/chef/devices/rootnode_onofflight_samplemei.matter +++ b/examples/chef/devices/rootnode_onofflight_samplemei.matter @@ -1026,7 +1026,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1478,9 +1484,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_onofflight_samplemei.zap b/examples/chef/devices/rootnode_onofflight_samplemei.zap index 5b983849ca4f2f..83f44eebd1907d 100644 --- a/examples/chef/devices/rootnode_onofflight_samplemei.zap +++ b/examples/chef/devices/rootnode_onofflight_samplemei.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter index e226808c56b944..da912ef77108a1 100644 --- a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter +++ b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.matter @@ -990,7 +990,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1419,9 +1425,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.zap b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.zap index e2e1d77b241f90..801d9c4fd2de67 100644 --- a/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.zap +++ b/examples/chef/devices/rootnode_onofflightswitch_FsPlMr090Q.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter index 0a7f8aabd6adc2..08003bcfe2384a 100644 --- a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter +++ b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.matter @@ -925,7 +925,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1354,9 +1360,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.zap b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.zap index 24052570e77c22..66744fe2fc879e 100644 --- a/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.zap +++ b/examples/chef/devices/rootnode_onoffpluginunit_Wtf8ss5EBY.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter index dd1a2f16349f05..eb125b89e48971 100644 --- a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter +++ b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1344,9 +1350,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.zap b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.zap index 1b0028275e2b40..4ed304754c594f 100644 --- a/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.zap +++ b/examples/chef/devices/rootnode_pressuresensor_s0qC9wLH4k.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_pump_5f904818cc.matter b/examples/chef/devices/rootnode_pump_5f904818cc.matter index a5bd2bf03297bb..a28ab46f769944 100644 --- a/examples/chef/devices/rootnode_pump_5f904818cc.matter +++ b/examples/chef/devices/rootnode_pump_5f904818cc.matter @@ -648,6 +648,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -661,7 +662,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1176,14 +1183,17 @@ endpoint 0 { server cluster GeneralDiagnostics { callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_pump_5f904818cc.zap b/examples/chef/devices/rootnode_pump_5f904818cc.zap index 131da70f467974..ca969c6222fabe 100644 --- a/examples/chef/devices/rootnode_pump_5f904818cc.zap +++ b/examples/chef/devices/rootnode_pump_5f904818cc.zap @@ -1511,6 +1511,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1546,6 +1562,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1636,7 +1668,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_pump_a811bb33a0.matter b/examples/chef/devices/rootnode_pump_a811bb33a0.matter index 44e81fb472dc0c..ed9c708770e43f 100644 --- a/examples/chef/devices/rootnode_pump_a811bb33a0.matter +++ b/examples/chef/devices/rootnode_pump_a811bb33a0.matter @@ -648,6 +648,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -661,7 +662,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1128,14 +1135,17 @@ endpoint 0 { server cluster GeneralDiagnostics { callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_pump_a811bb33a0.zap b/examples/chef/devices/rootnode_pump_a811bb33a0.zap index 49a4e51fd9a20e..c4ce099577de7a 100644 --- a/examples/chef/devices/rootnode_pump_a811bb33a0.zap +++ b/examples/chef/devices/rootnode_pump_a811bb33a0.zap @@ -1511,6 +1511,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1546,6 +1562,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1636,7 +1668,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.matter b/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.matter index 745eb917c8b8bd..789ab736372331 100644 --- a/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.matter +++ b/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.matter @@ -631,7 +631,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1130,9 +1136,11 @@ endpoint 0 { callback attribute acceptedCommandList default = 0; callback attribute attributeList default = 0; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.zap b/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.zap index 6d0189f25a769a..f63a0072d3fc7e 100644 --- a/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.zap +++ b/examples/chef/devices/rootnode_refrigerator_temperaturecontrolledcabinet_temperaturecontrolledcabinet_ffdb696680.zap @@ -1786,6 +1786,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2007,7 +2023,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter index a5a8b6afc1c7a0..b776749b7e2699 100644 --- a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter +++ b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter @@ -659,7 +659,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1172,9 +1178,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.zap b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.zap index dad96cd186033a..b12960c0ad7c65 100644 --- a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.zap +++ b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter index 3f2fb5857276cc..6a2b4649a021c0 100644 --- a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter +++ b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.matter @@ -704,7 +704,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1217,9 +1223,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.zap b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.zap index 81b7dd94bb90f1..22078ba8f841f7 100644 --- a/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.zap +++ b/examples/chef/devices/rootnode_roomairconditioner_9cf3607804.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.matter b/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.matter index 1c026bb8c31c30..2742d918b4aa9d 100644 --- a/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.matter +++ b/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.matter @@ -891,7 +891,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1348,9 +1354,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.zap b/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.zap index ac52e9a00e295e..9fdb65c8035573 100644 --- a/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.zap +++ b/examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter index 5fc393ff48f607..c2a65154372e18 100644 --- a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter +++ b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.matter @@ -951,7 +951,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1380,9 +1386,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.zap b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.zap index dd5e63a06d5bfd..28f47070e93356 100644 --- a/examples/chef/devices/rootnode_speaker_RpzeXdimqA.zap +++ b/examples/chef/devices/rootnode_speaker_RpzeXdimqA.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter index 8eb9c77b6fc45e..7c3771e7222915 100644 --- a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter +++ b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter @@ -882,7 +882,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1324,9 +1330,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.zap b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.zap index 28e1691e0d9387..e16ee3fcca8420 100644 --- a/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.zap +++ b/examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter index 73d5d7df7262a2..5e63942dde6df5 100644 --- a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter +++ b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter @@ -876,7 +876,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1573,9 +1579,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.zap b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.zap index fc6192274b30ac..fbe5c0f9c50a56 100644 --- a/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.zap +++ b/examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter index 7a1f5a750e1747..7b2e347b0ed662 100644 --- a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter +++ b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter @@ -876,7 +876,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1449,9 +1455,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.zap b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.zap index 981a417a84f735..0d68f07eccb7a1 100644 --- a/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.zap +++ b/examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/devices/template.zap b/examples/chef/devices/template.zap index 0f7cf1a1d63a13..bf77da05ea3d05 100644 --- a/examples/chef/devices/template.zap +++ b/examples/chef/devices/template.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/chef/sample_app_util/test_files/sample_zap_file.zap b/examples/chef/sample_app_util/test_files/sample_zap_file.zap index eff6a00671d5b0..1359eea30b9791 100644 --- a/examples/chef/sample_app_util/test_files/sample_zap_file.zap +++ b/examples/chef/sample_app_util/test_files/sample_zap_file.zap @@ -1830,7 +1830,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter index 2d0308f0c81741..847c827d4fe086 100644 --- a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter +++ b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.matter @@ -863,7 +863,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1646,9 +1652,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.zap b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.zap index 0fa6b11ed229eb..1a7ff846ae75a0 100644 --- a/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.zap +++ b/examples/contact-sensor-app/contact-sensor-common/contact-sensor-app.zap @@ -1683,6 +1683,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1856,7 +1872,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/dishwasher-app/dishwasher-common/dishwasher-app.matter b/examples/dishwasher-app/dishwasher-common/dishwasher-app.matter index 1cac116c4efef6..fa10fd83dd7c77 100644 --- a/examples/dishwasher-app/dishwasher-common/dishwasher-app.matter +++ b/examples/dishwasher-app/dishwasher-common/dishwasher-app.matter @@ -719,7 +719,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1270,9 +1276,11 @@ endpoint 0 { callback attribute acceptedCommandList default = 0; callback attribute attributeList default = 0; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/dishwasher-app/dishwasher-common/dishwasher-app.zap b/examples/dishwasher-app/dishwasher-common/dishwasher-app.zap index 35e670751458f5..be3add8ed70a6a 100644 --- a/examples/dishwasher-app/dishwasher-common/dishwasher-app.zap +++ b/examples/dishwasher-app/dishwasher-common/dishwasher-app.zap @@ -1926,6 +1926,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2147,7 +2163,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/light-switch-app/light-switch-common/light-switch-app.matter b/examples/light-switch-app/light-switch-common/light-switch-app.matter index f8962a2ac437d7..74028e4ef9f8ae 100644 --- a/examples/light-switch-app/light-switch-common/light-switch-app.matter +++ b/examples/light-switch-app/light-switch-common/light-switch-app.matter @@ -1177,7 +1177,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2459,9 +2465,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/light-switch-app/light-switch-common/light-switch-app.zap b/examples/light-switch-app/light-switch-common/light-switch-app.zap index a92321ae63ca0c..0e3857c0ef3747 100644 --- a/examples/light-switch-app/light-switch-common/light-switch-app.zap +++ b/examples/light-switch-app/light-switch-common/light-switch-app.zap @@ -1601,6 +1601,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1774,7 +1790,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.matter b/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.matter index 8ab0257efa2b41..7a3be88505e300 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.matter +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.matter @@ -1034,7 +1034,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1797,9 +1803,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.zap b/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.zap index 3fbf144422e576..964c28d2394697 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.zap +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-ethernet.zap @@ -1437,6 +1437,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1610,7 +1626,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter index f7bb7e5544d04e..3475808b741751 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter @@ -1034,7 +1034,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1929,9 +1935,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap index cb06c41a042700..01561c14d6dd33 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter index 98e9f875aebe99..c389aafb01efc5 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter @@ -1034,7 +1034,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1839,9 +1845,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap index c24ec8d3bc8eaf..b5a5f6165d0016 100644 --- a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap +++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/lighting-common/lighting-app.matter b/examples/lighting-app/lighting-common/lighting-app.matter index f39d6580d31f65..3ff6f8d4ede74f 100644 --- a/examples/lighting-app/lighting-common/lighting-app.matter +++ b/examples/lighting-app/lighting-common/lighting-app.matter @@ -1181,7 +1181,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2255,9 +2261,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/lighting-common/lighting-app.zap b/examples/lighting-app/lighting-common/lighting-app.zap index c4f3572ec96857..1eb4d7a701f432 100644 --- a/examples/lighting-app/lighting-common/lighting-app.zap +++ b/examples/lighting-app/lighting-common/lighting-app.zap @@ -1543,6 +1543,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1716,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/nxp/zap/lighting-on-off.matter b/examples/lighting-app/nxp/zap/lighting-on-off.matter index 879cdadd19a22f..4ac1ee3eca2f63 100644 --- a/examples/lighting-app/nxp/zap/lighting-on-off.matter +++ b/examples/lighting-app/nxp/zap/lighting-on-off.matter @@ -901,6 +901,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -914,7 +915,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1442,11 +1449,14 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/nxp/zap/lighting-on-off.zap b/examples/lighting-app/nxp/zap/lighting-on-off.zap index 4da6db3bf6d93b..908dfc6bc2ac66 100644 --- a/examples/lighting-app/nxp/zap/lighting-on-off.zap +++ b/examples/lighting-app/nxp/zap/lighting-on-off.zap @@ -1191,6 +1191,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1226,6 +1242,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1268,7 +1300,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/qpg/zap/light.matter b/examples/lighting-app/qpg/zap/light.matter index 7c055058372faf..d0f37c17c22356 100644 --- a/examples/lighting-app/qpg/zap/light.matter +++ b/examples/lighting-app/qpg/zap/light.matter @@ -975,7 +975,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1877,9 +1883,11 @@ endpoint 0 { callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/qpg/zap/light.zap b/examples/lighting-app/qpg/zap/light.zap index ffd306791f7f40..a3b56ebb02d1cb 100644 --- a/examples/lighting-app/qpg/zap/light.zap +++ b/examples/lighting-app/qpg/zap/light.zap @@ -1715,6 +1715,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1936,7 +1952,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/silabs/data_model/lighting-thread-app.matter b/examples/lighting-app/silabs/data_model/lighting-thread-app.matter index 31c6acf21d6c38..551342811a2428 100644 --- a/examples/lighting-app/silabs/data_model/lighting-thread-app.matter +++ b/examples/lighting-app/silabs/data_model/lighting-thread-app.matter @@ -1438,7 +1438,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2308,9 +2314,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/silabs/data_model/lighting-thread-app.zap b/examples/lighting-app/silabs/data_model/lighting-thread-app.zap index 00e4fc3dc68664..f9bedf8f98ceee 100644 --- a/examples/lighting-app/silabs/data_model/lighting-thread-app.zap +++ b/examples/lighting-app/silabs/data_model/lighting-thread-app.zap @@ -1497,6 +1497,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1670,7 +1686,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lighting-app/silabs/data_model/lighting-wifi-app.matter b/examples/lighting-app/silabs/data_model/lighting-wifi-app.matter index 293faf071dbb16..404029c1978ca1 100644 --- a/examples/lighting-app/silabs/data_model/lighting-wifi-app.matter +++ b/examples/lighting-app/silabs/data_model/lighting-wifi-app.matter @@ -1417,7 +1417,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2198,9 +2204,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lighting-app/silabs/data_model/lighting-wifi-app.zap b/examples/lighting-app/silabs/data_model/lighting-wifi-app.zap index 76f4fde26b1b09..9fdd90c26099db 100644 --- a/examples/lighting-app/silabs/data_model/lighting-wifi-app.zap +++ b/examples/lighting-app/silabs/data_model/lighting-wifi-app.zap @@ -1497,6 +1497,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1670,7 +1686,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lock-app/lock-common/lock-app.matter b/examples/lock-app/lock-common/lock-app.matter index b3f6f1c74593a3..ea7d73c4282cb2 100644 --- a/examples/lock-app/lock-common/lock-app.matter +++ b/examples/lock-app/lock-common/lock-app.matter @@ -1100,7 +1100,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2516,9 +2522,11 @@ endpoint 0 { callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lock-app/lock-common/lock-app.zap b/examples/lock-app/lock-common/lock-app.zap index e079f41ed81adf..5dddf5b3075d14 100644 --- a/examples/lock-app/lock-common/lock-app.zap +++ b/examples/lock-app/lock-common/lock-app.zap @@ -2284,6 +2284,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2521,7 +2537,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lock-app/nxp/zap/lock-app.matter b/examples/lock-app/nxp/zap/lock-app.matter index 9b030c237fb074..9481cb27c858d3 100644 --- a/examples/lock-app/nxp/zap/lock-app.matter +++ b/examples/lock-app/nxp/zap/lock-app.matter @@ -519,6 +519,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -532,7 +533,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1515,11 +1522,14 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lock-app/nxp/zap/lock-app.zap b/examples/lock-app/nxp/zap/lock-app.zap index 103c17087eccfd..8e015b083248cb 100644 --- a/examples/lock-app/nxp/zap/lock-app.zap +++ b/examples/lock-app/nxp/zap/lock-app.zap @@ -984,6 +984,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1019,6 +1035,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1061,7 +1093,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/lock-app/qpg/zap/lock.matter b/examples/lock-app/qpg/zap/lock.matter index 5b67875cce9279..573fbe867361c6 100644 --- a/examples/lock-app/qpg/zap/lock.matter +++ b/examples/lock-app/qpg/zap/lock.matter @@ -808,7 +808,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1911,9 +1917,11 @@ endpoint 0 { callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/lock-app/qpg/zap/lock.zap b/examples/lock-app/qpg/zap/lock.zap index e66ddc5a32eac5..c60d090151a3b7 100644 --- a/examples/lock-app/qpg/zap/lock.zap +++ b/examples/lock-app/qpg/zap/lock.zap @@ -1715,6 +1715,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1936,7 +1952,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter b/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter index e5187ffa74eefb..fe849962ec5103 100644 --- a/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter +++ b/examples/ota-provider-app/ota-provider-common/ota-provider-app.matter @@ -706,7 +706,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1110,9 +1116,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap b/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap index 3776092d0b62dd..d445d8a2694769 100644 --- a/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap +++ b/examples/ota-provider-app/ota-provider-common/ota-provider-app.zap @@ -1442,6 +1442,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1615,7 +1631,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter index 583331cd2a86ee..8b95001f4e391b 100644 --- a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter +++ b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.matter @@ -889,7 +889,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1293,9 +1299,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap index e36f3b95848231..f2eae5d5381cfc 100644 --- a/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap +++ b/examples/ota-requestor-app/ota-requestor-common/ota-requestor-app.zap @@ -1491,6 +1491,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1664,7 +1680,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/placeholder/linux/apps/app1/config.matter b/examples/placeholder/linux/apps/app1/config.matter index 1040513cc7c557..8daed1603f891c 100644 --- a/examples/placeholder/linux/apps/app1/config.matter +++ b/examples/placeholder/linux/apps/app1/config.matter @@ -1683,7 +1683,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -6734,9 +6740,11 @@ endpoint 0 { callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/placeholder/linux/apps/app1/config.zap b/examples/placeholder/linux/apps/app1/config.zap index c1166d993338fd..6bb34d3306eac0 100644 --- a/examples/placeholder/linux/apps/app1/config.zap +++ b/examples/placeholder/linux/apps/app1/config.zap @@ -2599,6 +2599,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2836,7 +2852,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/placeholder/linux/apps/app2/config.matter b/examples/placeholder/linux/apps/app2/config.matter index a2662b804165b9..654c6f2fec41de 100644 --- a/examples/placeholder/linux/apps/app2/config.matter +++ b/examples/placeholder/linux/apps/app2/config.matter @@ -1642,7 +1642,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -6694,9 +6700,11 @@ endpoint 0 { callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/placeholder/linux/apps/app2/config.zap b/examples/placeholder/linux/apps/app2/config.zap index 88191b28ef9110..3f19bedb04a28a 100644 --- a/examples/placeholder/linux/apps/app2/config.zap +++ b/examples/placeholder/linux/apps/app2/config.zap @@ -2615,6 +2615,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2852,7 +2868,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/pump-app/pump-common/pump-app.matter b/examples/pump-app/pump-common/pump-app.matter index 97ece6ceda452c..b95b685b2b753e 100644 --- a/examples/pump-app/pump-common/pump-app.matter +++ b/examples/pump-app/pump-common/pump-app.matter @@ -831,6 +831,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -844,7 +845,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ @@ -1535,14 +1542,17 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster ThreadNetworkDiagnostics { diff --git a/examples/pump-app/pump-common/pump-app.zap b/examples/pump-app/pump-common/pump-app.zap index 6e21cc9d3de2cf..73b79af6674e30 100644 --- a/examples/pump-app/pump-common/pump-app.zap +++ b/examples/pump-app/pump-common/pump-app.zap @@ -1575,6 +1575,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1610,6 +1626,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1700,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/pump-app/silabs/data_model/pump-thread-app.matter b/examples/pump-app/silabs/data_model/pump-thread-app.matter index 8112f63eebb16f..0bdb0955fef1bb 100644 --- a/examples/pump-app/silabs/data_model/pump-thread-app.matter +++ b/examples/pump-app/silabs/data_model/pump-thread-app.matter @@ -831,6 +831,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -844,7 +845,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ @@ -1535,14 +1542,17 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster ThreadNetworkDiagnostics { diff --git a/examples/pump-app/silabs/data_model/pump-thread-app.zap b/examples/pump-app/silabs/data_model/pump-thread-app.zap index 30e326a3bf068c..bd3569bc9c42f9 100644 --- a/examples/pump-app/silabs/data_model/pump-thread-app.zap +++ b/examples/pump-app/silabs/data_model/pump-thread-app.zap @@ -1575,6 +1575,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1610,6 +1626,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1700,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/pump-app/silabs/data_model/pump-wifi-app.matter b/examples/pump-app/silabs/data_model/pump-wifi-app.matter index 8112f63eebb16f..0bdb0955fef1bb 100644 --- a/examples/pump-app/silabs/data_model/pump-wifi-app.matter +++ b/examples/pump-app/silabs/data_model/pump-wifi-app.matter @@ -831,6 +831,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -844,7 +845,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ @@ -1535,14 +1542,17 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster ThreadNetworkDiagnostics { diff --git a/examples/pump-app/silabs/data_model/pump-wifi-app.zap b/examples/pump-app/silabs/data_model/pump-wifi-app.zap index 30e326a3bf068c..bd3569bc9c42f9 100644 --- a/examples/pump-app/silabs/data_model/pump-wifi-app.zap +++ b/examples/pump-app/silabs/data_model/pump-wifi-app.zap @@ -1575,6 +1575,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1610,6 +1626,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1700,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter index fd542a29b72f78..a5a9759bf9ae54 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter @@ -756,6 +756,7 @@ server cluster GeneralDiagnostics = 51 { readonly attribute NetworkInterface networkInterfaces[] = 0; readonly attribute int16u rebootCount = 1; + readonly attribute int64u upTime = 2; readonly attribute boolean testEventTriggersEnabled = 8; readonly attribute command_id generatedCommandList[] = 65528; readonly attribute command_id acceptedCommandList[] = 65529; @@ -769,7 +770,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ @@ -1421,14 +1428,17 @@ endpoint 0 { emits event BootReason; callback attribute networkInterfaces; callback attribute rebootCount default = 0x0000; + callback attribute upTime default = 0x0000000000000000; callback attribute testEventTriggersEnabled default = false; callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster ThreadNetworkDiagnostics { diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap b/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap index cb7f4b298c5fbb..0d687d1f4d446c 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.zap @@ -1575,6 +1575,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1610,6 +1626,22 @@ "maxInterval": 65344, "reportableChange": 0 }, + { + "name": "UpTime", + "code": 2, + "mfgCode": null, + "side": "server", + "type": "int64u", + "included": 1, + "storageOption": "External", + "singleton": 0, + "bounded": 0, + "defaultValue": "0x0000000000000000", + "reportable": 1, + "minInterval": 1, + "maxInterval": 65534, + "reportableChange": 0 + }, { "name": "TestEventTriggersEnabled", "code": 8, @@ -1700,7 +1732,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/refrigerator-app/refrigerator-common/refrigerator-app.matter b/examples/refrigerator-app/refrigerator-common/refrigerator-app.matter index d9bc12cf315e95..dbbe4fc7142fdc 100644 --- a/examples/refrigerator-app/refrigerator-common/refrigerator-app.matter +++ b/examples/refrigerator-app/refrigerator-common/refrigerator-app.matter @@ -586,7 +586,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1075,9 +1081,11 @@ endpoint 0 { callback attribute acceptedCommandList default = 0; callback attribute attributeList default = 0; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/refrigerator-app/refrigerator-common/refrigerator-app.zap b/examples/refrigerator-app/refrigerator-common/refrigerator-app.zap index b772acad198770..3d554d6d8ca5ad 100644 --- a/examples/refrigerator-app/refrigerator-common/refrigerator-app.zap +++ b/examples/refrigerator-app/refrigerator-common/refrigerator-app.zap @@ -1694,6 +1694,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1915,7 +1931,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.matter b/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.matter index e8ad6f4689e6d9..4bf471ffc11107 100644 --- a/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.matter +++ b/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.matter @@ -863,7 +863,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1815,9 +1821,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.zap b/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.zap index f9ec6ae993d322..a55f8b6f4abe87 100644 --- a/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.zap +++ b/examples/resource-monitoring-app/resource-monitoring-common/resource-monitoring-app.zap @@ -1683,6 +1683,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1856,7 +1872,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/rvc-app/rvc-common/rvc-app.matter b/examples/rvc-app/rvc-common/rvc-app.matter index 4822febc1d0239..9be857b09ec61b 100644 --- a/examples/rvc-app/rvc-common/rvc-app.matter +++ b/examples/rvc-app/rvc-common/rvc-app.matter @@ -590,7 +590,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** Commands to trigger a Node to allow a new Administrator to commission it. */ @@ -1100,9 +1106,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 0x0001; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster AdministratorCommissioning { diff --git a/examples/rvc-app/rvc-common/rvc-app.zap b/examples/rvc-app/rvc-common/rvc-app.zap index a9f67c56bd7bc8..e5f9e297ad0b19 100644 --- a/examples/rvc-app/rvc-common/rvc-app.zap +++ b/examples/rvc-app/rvc-common/rvc-app.zap @@ -1172,6 +1172,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1345,7 +1361,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0x0001", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.matter b/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.matter index 48642e7abbf947..b8fcae541ac10c 100644 --- a/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.matter +++ b/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.matter @@ -1095,7 +1095,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1871,9 +1877,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.zap b/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.zap index b5fe6c12387788..2507ad7cba4c4b 100644 --- a/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.zap +++ b/examples/smoke-co-alarm-app/smoke-co-alarm-common/smoke-co-alarm-app.zap @@ -1481,6 +1481,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1654,7 +1670,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.matter b/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.matter index 187f8d14112801..2f492c5c2b031d 100644 --- a/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.matter +++ b/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.matter @@ -617,7 +617,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1171,9 +1177,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.zap b/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.zap index 7845ed393315aa..1b4d5b5e83b16f 100644 --- a/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.zap +++ b/examples/temperature-measurement-app/temperature-measurement-common/temperature-measurement.zap @@ -1386,6 +1386,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1559,7 +1575,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/thermostat/nxp/zap/thermostat_matter_thread.matter b/examples/thermostat/nxp/zap/thermostat_matter_thread.matter index a581f1f70d285d..6c00996c41eaca 100644 --- a/examples/thermostat/nxp/zap/thermostat_matter_thread.matter +++ b/examples/thermostat/nxp/zap/thermostat_matter_thread.matter @@ -1264,7 +1264,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Thread Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems */ @@ -1941,9 +1947,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster ThreadNetworkDiagnostics { diff --git a/examples/thermostat/nxp/zap/thermostat_matter_thread.zap b/examples/thermostat/nxp/zap/thermostat_matter_thread.zap index ec8baf4d992228..1db8b2b288b77f 100644 --- a/examples/thermostat/nxp/zap/thermostat_matter_thread.zap +++ b/examples/thermostat/nxp/zap/thermostat_matter_thread.zap @@ -1626,6 +1626,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1799,7 +1815,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/thermostat/nxp/zap/thermostat_matter_wifi.matter b/examples/thermostat/nxp/zap/thermostat_matter_wifi.matter index ede88c2f5677f3..7123a0dadf1874 100644 --- a/examples/thermostat/nxp/zap/thermostat_matter_wifi.matter +++ b/examples/thermostat/nxp/zap/thermostat_matter_wifi.matter @@ -1264,7 +1264,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Wi-Fi Network Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1850,9 +1856,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster WiFiNetworkDiagnostics { diff --git a/examples/thermostat/nxp/zap/thermostat_matter_wifi.zap b/examples/thermostat/nxp/zap/thermostat_matter_wifi.zap index fcc14df85255d3..7a3e1ffbb356ba 100644 --- a/examples/thermostat/nxp/zap/thermostat_matter_wifi.zap +++ b/examples/thermostat/nxp/zap/thermostat_matter_wifi.zap @@ -1626,6 +1626,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1799,7 +1815,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/thermostat/thermostat-common/thermostat.matter b/examples/thermostat/thermostat-common/thermostat.matter index be2a7be5dacc50..d5ed36f49349b8 100644 --- a/examples/thermostat/thermostat-common/thermostat.matter +++ b/examples/thermostat/thermostat-common/thermostat.matter @@ -954,7 +954,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -1799,9 +1805,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/thermostat/thermostat-common/thermostat.zap b/examples/thermostat/thermostat-common/thermostat.zap index 74262e2093f6b1..d22c446eb23fac 100644 --- a/examples/thermostat/thermostat-common/thermostat.zap +++ b/examples/thermostat/thermostat-common/thermostat.zap @@ -1727,6 +1727,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1900,7 +1916,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/tv-app/tv-common/tv-app.matter b/examples/tv-app/tv-common/tv-app.matter index 5d7764d71f36c8..f33bd7a4b364a1 100644 --- a/examples/tv-app/tv-common/tv-app.matter +++ b/examples/tv-app/tv-common/tv-app.matter @@ -1109,7 +1109,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2601,9 +2607,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/tv-app/tv-common/tv-app.zap b/examples/tv-app/tv-common/tv-app.zap index 58a0b469101460..08def3fad76094 100644 --- a/examples/tv-app/tv-common/tv-app.zap +++ b/examples/tv-app/tv-common/tv-app.zap @@ -1754,6 +1754,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1927,7 +1943,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter index a98c4dbf1b207e..88b8b3574f7f48 100644 --- a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter +++ b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter @@ -950,7 +950,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2129,9 +2135,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap b/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap index b231ccb0ec904f..d55da66fab0eba 100644 --- a/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap +++ b/examples/tv-casting-app/tv-casting-common/tv-casting-app.zap @@ -1400,6 +1400,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1573,7 +1589,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/virtual-device-app/virtual-device-common/virtual-device-app.matter b/examples/virtual-device-app/virtual-device-common/virtual-device-app.matter index 0c56f79c581271..41a46c5c47d3ac 100644 --- a/examples/virtual-device-app/virtual-device-common/virtual-device-app.matter +++ b/examples/virtual-device-app/virtual-device-common/virtual-device-app.matter @@ -1244,7 +1244,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2660,9 +2666,11 @@ endpoint 0 { callback attribute activeNetworkFaults; callback attribute testEventTriggersEnabled default = false; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/virtual-device-app/virtual-device-common/virtual-device-app.zap b/examples/virtual-device-app/virtual-device-common/virtual-device-app.zap index ea5776de0b3587..d60d0e3de7f852 100644 --- a/examples/virtual-device-app/virtual-device-common/virtual-device-app.zap +++ b/examples/virtual-device-app/virtual-device-common/virtual-device-app.zap @@ -1552,6 +1552,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -1725,7 +1741,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/window-app/common/window-app.matter b/examples/window-app/common/window-app.matter index f997baf66cfc98..6b5f06125fcf6e 100644 --- a/examples/window-app/common/window-app.matter +++ b/examples/window-app/common/window-app.matter @@ -1084,7 +1084,13 @@ server cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ @@ -2000,9 +2006,11 @@ endpoint 0 { callback attribute eventList; callback attribute attributeList; ram attribute featureMap default = 0; - ram attribute clusterRevision default = 1; + ram attribute clusterRevision default = 0x0002; handle command TestEventTrigger; + handle command TimeSnapshot; + handle command TimeSnapshotResponse; } server cluster SoftwareDiagnostics { diff --git a/examples/window-app/common/window-app.zap b/examples/window-app/common/window-app.zap index a5dcb3b1a3bc2e..3ac0170b1683e6 100644 --- a/examples/window-app/common/window-app.zap +++ b/examples/window-app/common/window-app.zap @@ -2303,6 +2303,22 @@ "source": "client", "isIncoming": 1, "isEnabled": 1 + }, + { + "name": "TimeSnapshot", + "code": 1, + "mfgCode": null, + "source": "client", + "isIncoming": 1, + "isEnabled": 1 + }, + { + "name": "TimeSnapshotResponse", + "code": 2, + "mfgCode": null, + "source": "server", + "isIncoming": 0, + "isEnabled": 1 } ], "attributes": [ @@ -2540,7 +2556,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "1", + "defaultValue": "0x0002", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/src/app/clusters/general-diagnostics-server/general-diagnostics-server.cpp b/src/app/clusters/general-diagnostics-server/general-diagnostics-server.cpp index 994104abf22a75..0ea54f2e2c96b6 100644 --- a/src/app/clusters/general-diagnostics-server/general-diagnostics-server.cpp +++ b/src/app/clusters/general-diagnostics-server/general-diagnostics-server.cpp @@ -384,6 +384,15 @@ bool emberAfGeneralDiagnosticsClusterTestEventTriggerCallback(CommandHandler * c return true; } +bool emberAfGeneralDiagnosticsClusterTimeSnapshotCallback(CommandHandler * commandObj, ConcreteCommandPath const & commandPath, + Commands::TimeSnapshot::DecodableType const & commandData) +{ + // TODO(#30096): Command needs to be implemented. + ChipLogError(Zcl, "TimeSnapshot not yet supported!"); + commandObj->AddStatus(commandPath, Status::InvalidCommand); + return true; +} + void MatterGeneralDiagnosticsPluginServerInitCallback() { BootReasonEnum bootReason; diff --git a/src/app/tests/suites/certification/Test_TC_DGGEN_1_1.yaml b/src/app/tests/suites/certification/Test_TC_DGGEN_1_1.yaml index 1fdcfce09d47ee..147242c5db841e 100644 --- a/src/app/tests/suites/certification/Test_TC_DGGEN_1_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_DGGEN_1_1.yaml @@ -35,7 +35,7 @@ tests: command: "readAttribute" attribute: "ClusterRevision" response: - value: 1 + value: 2 constraints: type: int16u @@ -65,8 +65,9 @@ tests: type: list contains: [0, 1, 8, 65528, 65529, 65531, 65532, 65533] - - label: "Step 4b: Read optional attribute(UpTime) in AttributeList" - PICS: DGGEN.S.A0002 + - label: + "Step 4b: Validate presence of mandatory attribute(UpTime) in + AttributeList" command: "readAttribute" attribute: "AttributeList" response: @@ -168,12 +169,12 @@ tests: response: constraints: type: list - contains: [0] + contains: [0, 1] - label: "Step 7: TH reads GeneratedCommandList from DUT" command: "readAttribute" attribute: "GeneratedCommandList" response: - value: [] + value: [2] constraints: type: list diff --git a/src/app/tests/suites/certification/Test_TC_DGGEN_2_1.yaml b/src/app/tests/suites/certification/Test_TC_DGGEN_2_1.yaml index 22a222055e689f..5b4e7a489a613f 100644 --- a/src/app/tests/suites/certification/Test_TC_DGGEN_2_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_DGGEN_2_1.yaml @@ -183,7 +183,6 @@ tests: - label: "Step 4a: TH reads the Uptime attribute value of DUT. Store the value in uptime1" - PICS: DGGEN.S.A0002 command: "readAttribute" attribute: "UpTime" response: @@ -192,7 +191,6 @@ tests: type: int64u - label: "Wait 10 seconds" - PICS: DGGEN.S.A0002 cluster: "DelayCommands" command: "WaitForMs" arguments: @@ -203,7 +201,6 @@ tests: - label: "Step 4b: TH reads a Uptime attribute value of DUT. Store the value in uptime2. Verify that uptime2 is greater than uptime1." - PICS: DGGEN.S.A0002 command: "readAttribute" attribute: "UpTime" response: @@ -241,7 +238,6 @@ tests: - label: "Step 4c: TH reads a Uptime attribute value of DUT. Store the value in uptime3. Verify that uptime3 is lesser than uptime2." - PICS: DGGEN.S.A0003 command: "readAttribute" attribute: "UpTime" response: diff --git a/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml index 4e0e9b5cafdfe2..0a3c0f12ffd783 100644 --- a/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml @@ -38,7 +38,7 @@ limitations under the License. - + @@ -56,7 +56,7 @@ limitations under the License. - + @@ -67,15 +67,15 @@ limitations under the License. - - - - + + + + - - - - + + + + General @@ -83,8 +83,9 @@ limitations under the License. 0x0033 GENERAL_DIAGNOSTICS_CLUSTER The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. - NetworkInterfaces + NetworkInterfaces RebootCount + UpTime TotalOperationalHours BootReason @@ -92,6 +93,7 @@ limitations under the License. ActiveRadioFaults ActiveNetworkFaults TestEventTriggersEnabled + AverageWearCount @@ -101,6 +103,16 @@ limitations under the License. + + Take a snapshot of system time and epoch time. + + + + Response for the TimeSnapshot command. + + + + Indicate a change in the set of hardware faults currently detected by the Node. diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index d5b1691dc9eb9f..41a318647f425d 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -1795,8 +1795,15 @@ client cluster GeneralDiagnostics = 51 { int64u eventTrigger = 1; } + response struct TimeSnapshotResponse = 2 { + systime_us systemTimeUs = 0; + nullable epoch_us UTCTimeUs = 1; + } + /** Provide a means for certification tests to trigger some test-plan-specific events */ command access(invoke: manage) TestEventTrigger(TestEventTriggerRequest): DefaultSuccess = 0; + /** Take a snapshot of system time and epoch time. */ + command TimeSnapshot(): TimeSnapshotResponse = 1; } /** The Software Diagnostics Cluster provides a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */ diff --git a/src/controller/java/generated/java/chip/devicecontroller/ChipClusters.java b/src/controller/java/generated/java/chip/devicecontroller/ChipClusters.java index 62c12f62001130..006c23aaf1d582 100644 --- a/src/controller/java/generated/java/chip/devicecontroller/ChipClusters.java +++ b/src/controller/java/generated/java/chip/devicecontroller/ChipClusters.java @@ -6062,8 +6062,23 @@ public void testEventTrigger(DefaultClusterCallback callback, byte[] enableKey, testEventTrigger(chipClusterPtr, callback, enableKey, eventTrigger, timedInvokeTimeoutMs); } + public void timeSnapshot(TimeSnapshotResponseCallback callback) { + timeSnapshot(chipClusterPtr, callback, null); + } + + public void timeSnapshot(TimeSnapshotResponseCallback callback, int timedInvokeTimeoutMs) { + timeSnapshot(chipClusterPtr, callback, timedInvokeTimeoutMs); + } + private native void testEventTrigger(long chipClusterPtr, DefaultClusterCallback callback, byte[] enableKey, Long eventTrigger, @Nullable Integer timedInvokeTimeoutMs); + private native void timeSnapshot(long chipClusterPtr, TimeSnapshotResponseCallback callback, @Nullable Integer timedInvokeTimeoutMs); + + public interface TimeSnapshotResponseCallback { + void onSuccess(Long systemTimeUs, @Nullable Long UTCTimeUs); + void onError(Exception error); + } + public interface NetworkInterfacesAttributeCallback { void onSuccess(List value); void onError(Exception ex); diff --git a/src/controller/java/generated/java/chip/devicecontroller/ClusterIDMapping.java b/src/controller/java/generated/java/chip/devicecontroller/ClusterIDMapping.java index 413541bdf799b4..99fa62cef2d0c1 100644 --- a/src/controller/java/generated/java/chip/devicecontroller/ClusterIDMapping.java +++ b/src/controller/java/generated/java/chip/devicecontroller/ClusterIDMapping.java @@ -3800,7 +3800,8 @@ public static Event value(long id) throws NoSuchFieldError { } public enum Command { - TestEventTrigger(0L),; + TestEventTrigger(0L), + TimeSnapshot(1L),; private final long id; Command(long id) { this.id = id; diff --git a/src/controller/java/generated/java/chip/devicecontroller/ClusterInfoMapping.java b/src/controller/java/generated/java/chip/devicecontroller/ClusterInfoMapping.java index a051e4d5b071b8..78cce7dc99f04d 100644 --- a/src/controller/java/generated/java/chip/devicecontroller/ClusterInfoMapping.java +++ b/src/controller/java/generated/java/chip/devicecontroller/ClusterInfoMapping.java @@ -3638,6 +3638,30 @@ public void onError(Exception ex) { } } + + public static class DelegatedGeneralDiagnosticsClusterTimeSnapshotResponseCallback implements ChipClusters.GeneralDiagnosticsCluster.TimeSnapshotResponseCallback, DelegatedClusterCallback { + private ClusterCommandCallback callback; + @Override + public void setCallbackDelegate(ClusterCommandCallback callback) { + this.callback = callback; + } + + @Override + public void onSuccess(Long systemTimeUs, @Nullable Long UTCTimeUs) { + Map responseValues = new LinkedHashMap<>(); + + CommandResponseInfo systemTimeUsResponseValue = new CommandResponseInfo("systemTimeUs", "Long"); + responseValues.put(systemTimeUsResponseValue, systemTimeUs); + CommandResponseInfo UTCTimeUsResponseValue = new CommandResponseInfo("UTCTimeUs", "Long"); + responseValues.put(UTCTimeUsResponseValue, UTCTimeUs); + callback.onSuccess(responseValues); + } + + @Override + public void onError(Exception error) { + callback.onFailure(error); + } + } public static class DelegatedGeneralDiagnosticsClusterNetworkInterfacesAttributeCallback implements ChipClusters.GeneralDiagnosticsCluster.NetworkInterfacesAttributeCallback, DelegatedClusterCallback { private ClusterCommandCallback callback; @Override @@ -18933,6 +18957,18 @@ public Map> getCommandMap() { ); generalDiagnosticsClusterInteractionInfoMap.put("testEventTrigger", generalDiagnosticstestEventTriggerInteractionInfo); + Map generalDiagnosticstimeSnapshotCommandParams = new LinkedHashMap(); + InteractionInfo generalDiagnosticstimeSnapshotInteractionInfo = new InteractionInfo( + (cluster, callback, commandArguments) -> { + ((ChipClusters.GeneralDiagnosticsCluster) cluster) + .timeSnapshot((ChipClusters.GeneralDiagnosticsCluster.TimeSnapshotResponseCallback) callback + ); + }, + () -> new DelegatedGeneralDiagnosticsClusterTimeSnapshotResponseCallback(), + generalDiagnosticstimeSnapshotCommandParams + ); + generalDiagnosticsClusterInteractionInfoMap.put("timeSnapshot", generalDiagnosticstimeSnapshotInteractionInfo); + commandMap.put("generalDiagnostics", generalDiagnosticsClusterInteractionInfoMap); Map softwareDiagnosticsClusterInteractionInfoMap = new LinkedHashMap<>(); diff --git a/src/controller/java/zap-generated/CHIPInvokeCallbacks.cpp b/src/controller/java/zap-generated/CHIPInvokeCallbacks.cpp index f2a81f98fc819b..6c7d8b46e8a37d 100644 --- a/src/controller/java/zap-generated/CHIPInvokeCallbacks.cpp +++ b/src/controller/java/zap-generated/CHIPInvokeCallbacks.cpp @@ -2202,6 +2202,81 @@ void CHIPDiagnosticLogsClusterRetrieveLogsResponseCallback::CallbackFn( env->CallVoidMethod(javaCallbackRef, javaMethod, Status, LogContent, UTCTimeStamp, TimeSinceBoot); } +CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback::CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback( + jobject javaCallback) : Callback::Callback(CallbackFn, this) +{ + JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + return; + } + + javaCallbackRef = env->NewGlobalRef(javaCallback); + if (javaCallbackRef == nullptr) + { + ChipLogError(Zcl, "Could not create global reference for Java callback"); + } +} + +CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback::~CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback() +{ + JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); + if (env == nullptr) + { + ChipLogError(Zcl, "Could not delete global reference for Java callback"); + return; + } + env->DeleteGlobalRef(javaCallbackRef); +}; + +void CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback::CallbackFn( + void * context, const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType & dataResponse) +{ + chip::DeviceLayer::StackUnlock unlock; + CHIP_ERROR err = CHIP_NO_ERROR; + JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread(); + jobject javaCallbackRef; + jmethodID javaMethod; + + VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Error invoking Java callback: no JNIEnv")); + + std::unique_ptr + cppCallback(reinterpret_cast(context), + chip::Platform::Delete); + VerifyOrReturn(cppCallback != nullptr, ChipLogError(Zcl, "Error invoking Java callback: failed to cast native callback")); + + javaCallbackRef = cppCallback->javaCallbackRef; + // Java callback is allowed to be null, exit early if this is the case. + VerifyOrReturn(javaCallbackRef != nullptr); + + err = JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Long;Ljava/lang/Long;)V", + &javaMethod); + VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error invoking Java callback: %s", ErrorStr(err))); + + jobject SystemTimeUs; + std::string SystemTimeUsClassName = "java/lang/Long"; + std::string SystemTimeUsCtorSignature = "(J)V"; + jlong jniSystemTimeUs = static_cast(dataResponse.systemTimeUs); + chip::JniReferences::GetInstance().CreateBoxedObject(SystemTimeUsClassName.c_str(), SystemTimeUsCtorSignature.c_str(), + jniSystemTimeUs, SystemTimeUs); + jobject UTCTimeUs; + if (dataResponse.UTCTimeUs.IsNull()) + { + UTCTimeUs = nullptr; + } + else + { + std::string UTCTimeUsClassName = "java/lang/Long"; + std::string UTCTimeUsCtorSignature = "(J)V"; + jlong jniUTCTimeUs = static_cast(dataResponse.UTCTimeUs.Value()); + chip::JniReferences::GetInstance().CreateBoxedObject(UTCTimeUsClassName.c_str(), UTCTimeUsCtorSignature.c_str(), + jniUTCTimeUs, UTCTimeUs); + } + + env->CallVoidMethod(javaCallbackRef, javaMethod, SystemTimeUs, UTCTimeUs); +} CHIPTimeSynchronizationClusterSetTimeZoneResponseCallback::CHIPTimeSynchronizationClusterSetTimeZoneResponseCallback( jobject javaCallback) : Callback::Callback(CallbackFn, this) { diff --git a/src/controller/java/zap-generated/CHIPInvokeCallbacks.h b/src/controller/java/zap-generated/CHIPInvokeCallbacks.h index 4bb4afe2fe72ba..c6afa9916c41fa 100644 --- a/src/controller/java/zap-generated/CHIPInvokeCallbacks.h +++ b/src/controller/java/zap-generated/CHIPInvokeCallbacks.h @@ -342,6 +342,21 @@ class CHIPDiagnosticLogsClusterRetrieveLogsResponseCallback jobject javaCallbackRef; }; +class CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback + : public Callback::Callback +{ +public: + CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback(jobject javaCallback); + + ~CHIPGeneralDiagnosticsClusterTimeSnapshotResponseCallback(); + + static void CallbackFn(void * context, + const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType & data); + +private: + jobject javaCallbackRef; +}; + class CHIPTimeSynchronizationClusterSetTimeZoneResponseCallback : public Callback::Callback { diff --git a/src/controller/python/chip/clusters/CHIPClusters.py b/src/controller/python/chip/clusters/CHIPClusters.py index efa9adc53cfdab..ea04b2c6cf583d 100644 --- a/src/controller/python/chip/clusters/CHIPClusters.py +++ b/src/controller/python/chip/clusters/CHIPClusters.py @@ -2397,6 +2397,12 @@ class ChipClusters: "eventTrigger": "int", }, }, + 0x00000001: { + "commandId": 0x00000001, + "commandName": "TimeSnapshot", + "args": { + }, + }, }, "attributes": { 0x00000000: { diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py index 38c92ee15ed234..cffb2a70cb56a6 100644 --- a/src/controller/python/chip/clusters/Objects.py +++ b/src/controller/python/chip/clusters/Objects.py @@ -8346,6 +8346,37 @@ def descriptor(cls) -> ClusterObjectDescriptor: enableKey: 'bytes' = b"" eventTrigger: 'uint' = 0 + @dataclass + class TimeSnapshot(ClusterCommand): + cluster_id: typing.ClassVar[int] = 0x00000033 + command_id: typing.ClassVar[int] = 0x00000001 + is_client: typing.ClassVar[bool] = True + response_type: typing.ClassVar[str] = 'TimeSnapshotResponse' + + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields=[ + ]) + + @dataclass + class TimeSnapshotResponse(ClusterCommand): + cluster_id: typing.ClassVar[int] = 0x00000033 + command_id: typing.ClassVar[int] = 0x00000002 + is_client: typing.ClassVar[bool] = False + response_type: typing.ClassVar[str] = None + + @ChipUtility.classproperty + def descriptor(cls) -> ClusterObjectDescriptor: + return ClusterObjectDescriptor( + Fields=[ + ClusterObjectFieldDescriptor(Label="systemTimeUs", Tag=0, Type=uint), + ClusterObjectFieldDescriptor(Label="UTCTimeUs", Tag=1, Type=typing.Union[Nullable, uint]), + ]) + + systemTimeUs: 'uint' = 0 + UTCTimeUs: 'typing.Union[Nullable, uint]' = NullValue + class Attributes: @dataclass class NetworkInterfaces(ClusterAttributeDescriptor): diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h index 7a6c820b64fc67..9a05da483a248f 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h @@ -2619,6 +2619,14 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) * Provide a means for certification tests to trigger some test-plan-specific events */ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +/** + * Command TimeSnapshot + * + * Take a snapshot of system time and epoch time. + */ +- (void)timeSnapshotWithParams:(MTRGeneralDiagnosticsClusterTimeSnapshotParams * _Nullable)params completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; +- (void)timeSnapshotWithCompletion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion + MTR_PROVISIONALLY_AVAILABLE; - (void)readAttributeNetworkInterfacesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); - (void)subscribeAttributeNetworkInterfacesWithParams:(MTRSubscribeParams *)params diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm index ec55b1beca255a..4e04fc5f85c6f5 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.mm @@ -22057,6 +22057,34 @@ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTrigger queue:self.callbackQueue completion:responseHandler]; } +- (void)timeSnapshotWithCompletion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion +{ + [self timeSnapshotWithParams:nil completion:completion]; +} +- (void)timeSnapshotWithParams:(MTRGeneralDiagnosticsClusterTimeSnapshotParams * _Nullable)params completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion +{ + if (params == nil) { + params = [[MTRGeneralDiagnosticsClusterTimeSnapshotParams + alloc] init]; + } + + auto responseHandler = ^(id _Nullable response, NSError * _Nullable error) { + completion(response, error); + }; + + auto * timedInvokeTimeoutMs = params.timedInvokeTimeoutMs; + + using RequestType = GeneralDiagnostics::Commands::TimeSnapshot::Type; + [self.device _invokeKnownCommandWithEndpointID:@(self.endpoint) + clusterID:@(RequestType::GetClusterId()) + commandID:@(RequestType::GetCommandId()) + commandPayload:params + timedInvokeTimeout:timedInvokeTimeoutMs + serverSideProcessingTimeout:params.serverSideProcessingTimeout + responseClass:MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams.class + queue:self.callbackQueue + completion:responseHandler]; +} - (void)readAttributeNetworkInterfacesWithCompletion:(void (^)(NSArray * _Nullable value, NSError * _Nullable error))completion { diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h index c42739771e0925..a0320b33fd3b36 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusterConstants.h @@ -5792,6 +5792,8 @@ typedef NS_ENUM(uint32_t, MTRCommandIDType) { // Cluster GeneralDiagnostics commands MTRCommandIDTypeClusterGeneralDiagnosticsCommandTestEventTriggerID MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)) = 0x00000000, + MTRCommandIDTypeClusterGeneralDiagnosticsCommandTimeSnapshotID MTR_PROVISIONALLY_AVAILABLE = 0x00000001, + MTRCommandIDTypeClusterGeneralDiagnosticsCommandTimeSnapshotResponseID MTR_PROVISIONALLY_AVAILABLE = 0x00000002, // Cluster SoftwareDiagnostics deprecated command id names MTRClusterSoftwareDiagnosticsCommandResetWatermarksID diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h index bbc0a86180ec83..c3c7c512f33813 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.h @@ -1323,6 +1323,9 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @property (nonatomic, readonly) MTRDevice * device MTR_NEWLY_AVAILABLE; - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTriggerParams *)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(MTRStatusCompletion)completion MTR_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4)); +- (void)timeSnapshotWithParams:(MTRGeneralDiagnosticsClusterTimeSnapshotParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedDataValueDictionaries expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion MTR_PROVISIONALLY_AVAILABLE; +- (void)timeSnapshotWithExpectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion + MTR_PROVISIONALLY_AVAILABLE; - (NSDictionary * _Nullable)readAttributeNetworkInterfacesWithParams:(MTRReadParams * _Nullable)params MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm index 9650aaf7d0e7a6..ae12459f547741 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRClusters.mm @@ -4440,6 +4440,37 @@ - (void)testEventTriggerWithParams:(MTRGeneralDiagnosticsClusterTestEventTrigger completion:responseHandler]; } +- (void)timeSnapshotWithExpectedValues:(NSArray *> *)expectedValues expectedValueInterval:(NSNumber *)expectedValueIntervalMs completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion +{ + [self timeSnapshotWithParams:nil expectedValues:expectedValues expectedValueInterval:expectedValueIntervalMs completion:completion]; +} +- (void)timeSnapshotWithParams:(MTRGeneralDiagnosticsClusterTimeSnapshotParams * _Nullable)params expectedValues:(NSArray *> * _Nullable)expectedValues expectedValueInterval:(NSNumber * _Nullable)expectedValueIntervalMs completion:(void (^)(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable data, NSError * _Nullable error))completion +{ + if (params == nil) { + params = [[MTRGeneralDiagnosticsClusterTimeSnapshotParams + alloc] init]; + } + + auto responseHandler = ^(id _Nullable response, NSError * _Nullable error) { + completion(response, error); + }; + + auto * timedInvokeTimeoutMs = params.timedInvokeTimeoutMs; + + using RequestType = GeneralDiagnostics::Commands::TimeSnapshot::Type; + [self.device _invokeKnownCommandWithEndpointID:@(self.endpoint) + clusterID:@(RequestType::GetClusterId()) + commandID:@(RequestType::GetCommandId()) + commandPayload:params + expectedValues:expectedValues + expectedValueInterval:expectedValueIntervalMs + timedInvokeTimeout:timedInvokeTimeoutMs + serverSideProcessingTimeout:params.serverSideProcessingTimeout + responseClass:MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams.class + queue:self.callbackQueue + completion:responseHandler]; +} + - (NSDictionary * _Nullable)readAttributeNetworkInterfacesWithParams:(MTRReadParams * _Nullable)params { return [self.device readAttributeWithEndpointID:@(self.endpoint) clusterID:@(MTRClusterIDTypeGeneralDiagnosticsID) attributeID:@(MTRAttributeIDTypeClusterGeneralDiagnosticsAttributeNetworkInterfacesID) params:params]; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h index 3f1e00bc19794b..6a2bb522b42aad 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.h @@ -3250,6 +3250,55 @@ MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @property (nonatomic, copy, nullable) NSNumber * serverSideProcessingTimeout; @end +MTR_PROVISIONALLY_AVAILABLE +@interface MTRGeneralDiagnosticsClusterTimeSnapshotParams : NSObject +/** + * Controls whether the command is a timed command (using Timed Invoke). + * + * If nil (the default value), a regular invoke is done for commands that do + * not require a timed invoke and a timed invoke with some default timed request + * timeout is done for commands that require a timed invoke. + * + * If not nil, a timed invoke is done, with the provided value used as the timed + * request timeout. The value should be chosen small enough to provide the + * desired security properties but large enough that it will allow a round-trip + * from the sever to the client (for the status response and actual invoke + * request) within the timeout window. + * + */ +@property (nonatomic, copy, nullable) NSNumber * timedInvokeTimeoutMs; + +/** + * Controls how much time, in seconds, we will allow for the server to process the command. + * + * The command will then time out if that much time, plus an allowance for retransmits due to network failures, passes. + * + * If nil, the framework will try to select an appropriate timeout value itself. + */ +@property (nonatomic, copy, nullable) NSNumber * serverSideProcessingTimeout; +@end + +MTR_PROVISIONALLY_AVAILABLE +@interface MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams : NSObject + +@property (nonatomic, copy) NSNumber * _Nonnull systemTimeUs MTR_PROVISIONALLY_AVAILABLE; + +@property (nonatomic, copy) NSNumber * _Nullable utcTimeUs MTR_PROVISIONALLY_AVAILABLE; + +/** + * Initialize an MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams with a response-value dictionary + * of the sort that MTRDeviceResponseHandler would receive. + * + * Will return nil and hand out an error if the response-value dictionary is not + * a command data response or is not the right command response. + * + * Will return nil and hand out an error if the data response does not match the known + * schema for this command. + */ +- (nullable instancetype)initWithResponseValue:(NSDictionary *)responseValue + error:(NSError * __autoreleasing *)error MTR_PROVISIONALLY_AVAILABLE; +@end + MTR_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) @interface MTRSoftwareDiagnosticsClusterResetWatermarksParams : NSObject /** diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm index 6ffbc9daaa07ae..386d6e02f5799d 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloadsObjc.mm @@ -8529,6 +8529,168 @@ - (CHIP_ERROR)_encodeToTLVReader:(chip::System::PacketBufferTLVReader &)reader } @end +@implementation MTRGeneralDiagnosticsClusterTimeSnapshotParams +- (instancetype)init +{ + if (self = [super init]) { + _timedInvokeTimeoutMs = nil; + _serverSideProcessingTimeout = nil; + } + return self; +} + +- (id)copyWithZone:(NSZone * _Nullable)zone; +{ + auto other = [[MTRGeneralDiagnosticsClusterTimeSnapshotParams alloc] init]; + + other.timedInvokeTimeoutMs = self.timedInvokeTimeoutMs; + other.serverSideProcessingTimeout = self.serverSideProcessingTimeout; + + return other; +} + +- (NSString *)description +{ + NSString * descriptionString = [NSString stringWithFormat:@"<%@: >", NSStringFromClass([self class])]; + return descriptionString; +} + +@end + +@implementation MTRGeneralDiagnosticsClusterTimeSnapshotParams (InternalMethods) + +- (CHIP_ERROR)_encodeToTLVReader:(chip::System::PacketBufferTLVReader &)reader +{ + chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::Type encodableStruct; + ListFreer listFreer; + + auto buffer = chip::System::PacketBufferHandle::New(chip::System::PacketBuffer::kMaxSizeWithoutReserve, 0); + if (buffer.IsNull()) { + return CHIP_ERROR_NO_MEMORY; + } + + chip::System::PacketBufferTLVWriter writer; + // Commands never need chained buffers, since they cannot be chunked. + writer.Init(std::move(buffer), /* useChainedBuffers = */ false); + + ReturnErrorOnFailure(chip::app::DataModel::Encode(writer, chip::TLV::AnonymousTag(), encodableStruct)); + + ReturnErrorOnFailure(writer.Finalize(&buffer)); + + reader.Init(std::move(buffer)); + return reader.Next(chip::TLV::kTLVType_Structure, chip::TLV::AnonymousTag()); +} + +- (NSDictionary * _Nullable)_encodeAsDataValue:(NSError * __autoreleasing *)error +{ + chip::System::PacketBufferTLVReader reader; + CHIP_ERROR err = [self _encodeToTLVReader:reader]; + if (err != CHIP_NO_ERROR) { + if (error) { + *error = [MTRError errorForCHIPErrorCode:err]; + } + return nil; + } + + auto decodedObj = MTRDecodeDataValueDictionaryFromCHIPTLV(&reader); + if (decodedObj == nil) { + if (error) { + *error = [MTRError errorForCHIPErrorCode:CHIP_ERROR_INCORRECT_STATE]; + } + } + return decodedObj; +} +@end + +@implementation MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams +- (instancetype)init +{ + if (self = [super init]) { + + _systemTimeUs = @(0); + + _utcTimeUs = nil; + } + return self; +} + +- (id)copyWithZone:(NSZone * _Nullable)zone; +{ + auto other = [[MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams alloc] init]; + + other.systemTimeUs = self.systemTimeUs; + other.utcTimeUs = self.utcTimeUs; + + return other; +} + +- (NSString *)description +{ + NSString * descriptionString = [NSString stringWithFormat:@"<%@: systemTimeUs:%@; utcTimeUs:%@; >", NSStringFromClass([self class]), _systemTimeUs, _utcTimeUs]; + return descriptionString; +} + +- (nullable instancetype)initWithResponseValue:(NSDictionary *)responseValue + error:(NSError * __autoreleasing *)error +{ + if (!(self = [super init])) { + return nil; + } + + using DecodableType = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType; + chip::System::PacketBufferHandle buffer = [MTRBaseDevice _responseDataForCommand:responseValue + clusterID:DecodableType::GetClusterId() + commandID:DecodableType::GetCommandId() + error:error]; + if (buffer.IsNull()) { + return nil; + } + + chip::TLV::TLVReader reader; + reader.Init(buffer->Start(), buffer->DataLength()); + + CHIP_ERROR err = reader.Next(chip::TLV::AnonymousTag()); + if (err == CHIP_NO_ERROR) { + DecodableType decodedStruct; + err = chip::app::DataModel::Decode(reader, decodedStruct); + if (err == CHIP_NO_ERROR) { + err = [self _setFieldsFromDecodableStruct:decodedStruct]; + if (err == CHIP_NO_ERROR) { + return self; + } + } + } + + NSString * errorStr = [NSString stringWithFormat:@"Command payload decoding failed: %s", err.AsString()]; + MTR_LOG_ERROR("%s", errorStr.UTF8String); + if (error != nil) { + NSDictionary * userInfo = @{ NSLocalizedFailureReasonErrorKey : NSLocalizedString(errorStr, nil) }; + *error = [NSError errorWithDomain:MTRErrorDomain code:MTRErrorCodeSchemaMismatch userInfo:userInfo]; + } + return nil; +} + +@end + +@implementation MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams (InternalMethods) + +- (CHIP_ERROR)_setFieldsFromDecodableStruct:(const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType &)decodableStruct +{ + { + self.systemTimeUs = [NSNumber numberWithUnsignedLongLong:decodableStruct.systemTimeUs]; + } + { + if (decodableStruct.UTCTimeUs.IsNull()) { + self.utcTimeUs = nil; + } else { + self.utcTimeUs = [NSNumber numberWithUnsignedLongLong:decodableStruct.UTCTimeUs.Value()]; + } + } + return CHIP_NO_ERROR; +} + +@end + @implementation MTRSoftwareDiagnosticsClusterResetWatermarksParams - (instancetype)init { diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloads_Internal.h b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloads_Internal.h index c00abea960dec0..cc23f560d8fee7 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloads_Internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRCommandPayloads_Internal.h @@ -514,6 +514,18 @@ NS_ASSUME_NONNULL_BEGIN @end +@interface MTRGeneralDiagnosticsClusterTimeSnapshotParams (InternalMethods) + +- (NSDictionary * _Nullable)_encodeAsDataValue:(NSError * __autoreleasing *)error; + +@end + +@interface MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams (InternalMethods) + +- (CHIP_ERROR)_setFieldsFromDecodableStruct:(const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType &)decodableStruct; + +@end + @interface MTRSoftwareDiagnosticsClusterResetWatermarksParams (InternalMethods) - (NSDictionary * _Nullable)_encodeAsDataValue:(NSError * __autoreleasing *)error; diff --git a/zzz_generated/app-common/app-common/zap-generated/callback.h b/zzz_generated/app-common/app-common/zap-generated/callback.h index 9b692fb362815b..e684a60678084e 100644 --- a/zzz_generated/app-common/app-common/zap-generated/callback.h +++ b/zzz_generated/app-common/app-common/zap-generated/callback.h @@ -8659,6 +8659,12 @@ bool emberAfDiagnosticLogsClusterRetrieveLogsRequestCallback( bool emberAfGeneralDiagnosticsClusterTestEventTriggerCallback( chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, const chip::app::Clusters::GeneralDiagnostics::Commands::TestEventTrigger::DecodableType & commandData); +/** + * @brief General Diagnostics Cluster TimeSnapshot Command callback (from client) + */ +bool emberAfGeneralDiagnosticsClusterTimeSnapshotCallback( + chip::app::CommandHandler * commandObj, const chip::app::ConcreteCommandPath & commandPath, + const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::DecodableType & commandData); /** * @brief Software Diagnostics Cluster ResetWatermarks Command callback (from client) */ diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp index 139fc46ed756bf..c094c10b39790b 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp @@ -6457,6 +6457,65 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) } } } // namespace TestEventTrigger. +namespace TimeSnapshot { +CHIP_ERROR Type::Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const +{ + DataModel::WrappedStructEncoder encoder{ aWriter, aTag }; + return encoder.Finalize(); +} + +CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) +{ + detail::StructDecodeIterator __iterator(reader); + while (true) + { + auto __element = __iterator.Next(); + if (std::holds_alternative(__element)) + { + return std::get(__element); + } + } +} +} // namespace TimeSnapshot. +namespace TimeSnapshotResponse { +CHIP_ERROR Type::Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const +{ + DataModel::WrappedStructEncoder encoder{ aWriter, aTag }; + encoder.Encode(to_underlying(Fields::kSystemTimeUs), systemTimeUs); + encoder.Encode(to_underlying(Fields::kUTCTimeUs), UTCTimeUs); + return encoder.Finalize(); +} + +CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader) +{ + detail::StructDecodeIterator __iterator(reader); + while (true) + { + auto __element = __iterator.Next(); + if (std::holds_alternative(__element)) + { + return std::get(__element); + } + + CHIP_ERROR err = CHIP_NO_ERROR; + const uint8_t __context_tag = std::get(__element); + + if (__context_tag == to_underlying(Fields::kSystemTimeUs)) + { + err = DataModel::Decode(reader, systemTimeUs); + } + else if (__context_tag == to_underlying(Fields::kUTCTimeUs)) + { + err = DataModel::Decode(reader, UTCTimeUs); + } + else + { + } + + ReturnErrorOnFailure(err); + } +} +} // namespace TimeSnapshotResponse. } // namespace Commands namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h index ca8a7867870c28..ae63fcf4a89d02 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h @@ -8176,6 +8176,16 @@ struct Type; struct DecodableType; } // namespace TestEventTrigger +namespace TimeSnapshot { +struct Type; +struct DecodableType; +} // namespace TimeSnapshot + +namespace TimeSnapshotResponse { +struct Type; +struct DecodableType; +} // namespace TimeSnapshotResponse + } // namespace Commands namespace Commands { @@ -8214,6 +8224,69 @@ struct DecodableType CHIP_ERROR Decode(TLV::TLVReader & reader); }; }; // namespace TestEventTrigger +namespace TimeSnapshot { +enum class Fields : uint8_t +{ +}; + +struct Type +{ +public: + // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand + static constexpr CommandId GetCommandId() { return Commands::TimeSnapshot::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; } + + CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const; + + using ResponseType = Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType; + + static constexpr bool MustUseTimedInvoke() { return false; } +}; + +struct DecodableType +{ +public: + static constexpr CommandId GetCommandId() { return Commands::TimeSnapshot::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; } + + CHIP_ERROR Decode(TLV::TLVReader & reader); +}; +}; // namespace TimeSnapshot +namespace TimeSnapshotResponse { +enum class Fields : uint8_t +{ + kSystemTimeUs = 0, + kUTCTimeUs = 1, +}; + +struct Type +{ +public: + // Use GetCommandId instead of commandId directly to avoid naming conflict with CommandIdentification in ExecutionOfACommand + static constexpr CommandId GetCommandId() { return Commands::TimeSnapshotResponse::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; } + + uint64_t systemTimeUs = static_cast(0); + DataModel::Nullable UTCTimeUs; + + CHIP_ERROR Encode(TLV::TLVWriter & aWriter, TLV::Tag aTag) const; + + using ResponseType = DataModel::NullObjectType; + + static constexpr bool MustUseTimedInvoke() { return false; } +}; + +struct DecodableType +{ +public: + static constexpr CommandId GetCommandId() { return Commands::TimeSnapshotResponse::Id; } + static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; } + + uint64_t systemTimeUs = static_cast(0); + DataModel::Nullable UTCTimeUs; + CHIP_ERROR Decode(TLV::TLVReader & reader); +}; +}; // namespace TimeSnapshotResponse } // namespace Commands namespace Attributes { diff --git a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h index 2b957cf72375ed..299da9e744f32c 100644 --- a/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h +++ b/zzz_generated/app-common/app-common/zap-generated/ids/Commands.h @@ -434,6 +434,14 @@ namespace TestEventTrigger { static constexpr CommandId Id = 0x00000000; } // namespace TestEventTrigger +namespace TimeSnapshot { +static constexpr CommandId Id = 0x00000001; +} // namespace TimeSnapshot + +namespace TimeSnapshotResponse { +static constexpr CommandId Id = 0x00000002; +} // namespace TimeSnapshotResponse + } // namespace Commands } // namespace GeneralDiagnostics diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h index f65b3063fba7bd..ad1bbc556ee196 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h @@ -3053,6 +3053,7 @@ class DiagnosticLogsRetrieveLogsRequest : public ClusterCommand |------------------------------------------------------------------------------| | Commands: | | | * TestEventTrigger | 0x00 | +| * TimeSnapshot | 0x01 | |------------------------------------------------------------------------------| | Attributes: | | | * NetworkInterfaces | 0x0000 | @@ -3118,6 +3119,43 @@ class GeneralDiagnosticsTestEventTrigger : public ClusterCommand chip::app::Clusters::GeneralDiagnostics::Commands::TestEventTrigger::Type mRequest; }; +/* + * Command TimeSnapshot + */ +class GeneralDiagnosticsTimeSnapshot : public ClusterCommand +{ +public: + GeneralDiagnosticsTimeSnapshot(CredentialIssuerCommands * credsIssuerConfig) : + ClusterCommand("time-snapshot", credsIssuerConfig) + { + ClusterCommand::AddArguments(); + } + + CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override + { + constexpr chip::ClusterId clusterId = chip::app::Clusters::GeneralDiagnostics::Id; + constexpr chip::CommandId commandId = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::Id; + + ChipLogProgress(chipTool, "Sending cluster (0x%08" PRIX32 ") command (0x%08" PRIX32 ") on endpoint %u", clusterId, + commandId, endpointIds.at(0)); + return ClusterCommand::SendCommand(device, endpointIds.at(0), clusterId, commandId, mRequest); + } + + CHIP_ERROR SendGroupCommand(chip::GroupId groupId, chip::FabricIndex fabricIndex) override + { + constexpr chip::ClusterId clusterId = chip::app::Clusters::GeneralDiagnostics::Id; + constexpr chip::CommandId commandId = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::Id; + + ChipLogProgress(chipTool, "Sending cluster (0x%08" PRIX32 ") command (0x%08" PRIX32 ") on Group %u", clusterId, commandId, + groupId); + + return ClusterCommand::SendGroupCommand(groupId, fabricIndex, clusterId, commandId, mRequest); + } + +private: + chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::Type mRequest; +}; + /*----------------------------------------------------------------------------*\ | Cluster SoftwareDiagnostics | 0x0034 | |------------------------------------------------------------------------------| @@ -13365,6 +13403,7 @@ void registerClusterGeneralDiagnostics(Commands & commands, CredentialIssuerComm // make_unique(Id, credsIssuerConfig), // make_unique(credsIssuerConfig), // + make_unique(credsIssuerConfig), // // // Attributes // diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp index f26ae6d1c32025..a97925574bf5ac 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp @@ -4625,6 +4625,15 @@ CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, DataModelLogger::LogString(indent, "}"); return CHIP_NO_ERROR; } +CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, + const GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType & value) +{ + DataModelLogger::LogString(label, indent, "{"); + ReturnErrorOnFailure(DataModelLogger::LogValue("systemTimeUs", indent + 1, value.systemTimeUs)); + ReturnErrorOnFailure(DataModelLogger::LogValue("UTCTimeUs", indent + 1, value.UTCTimeUs)); + DataModelLogger::LogString(indent, "}"); + return CHIP_NO_ERROR; +} CHIP_ERROR DataModelLogger::LogValue(const char * label, size_t indent, const TimeSynchronization::Commands::SetTimeZoneResponse::DecodableType & value) { @@ -13711,6 +13720,17 @@ CHIP_ERROR DataModelLogger::LogCommand(const chip::app::ConcreteCommandPath & pa } break; } + case GeneralDiagnostics::Id: { + switch (path.mCommandId) + { + case GeneralDiagnostics::Commands::TimeSnapshotResponse::Id: { + GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType value; + ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); + return DataModelLogger::LogValue("TimeSnapshotResponse", 1, value); + } + } + break; + } case TimeSynchronization::Id: { switch (path.mCommandId) { diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h index 96f8b52b007164..6d2ccf1c0fbc68 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.h @@ -460,6 +460,8 @@ LogValue(const char * label, size_t indent, const chip::app::Clusters::NetworkCommissioning::Commands::ConnectNetworkResponse::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, const chip::app::Clusters::DiagnosticLogs::Commands::RetrieveLogsResponse::DecodableType & value); +static CHIP_ERROR LogValue(const char * label, size_t indent, + const chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, const chip::app::Clusters::TimeSynchronization::Commands::SetTimeZoneResponse::DecodableType & value); static CHIP_ERROR LogValue(const char * label, size_t indent, diff --git a/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h index 519a27da8c68ba..07f482a5ab89b7 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/cluster/Commands.h @@ -27930,6 +27930,7 @@ class SubscribeAttributeDiagnosticLogsClusterRevision : public SubscribeAttribut |------------------------------------------------------------------------------| | Commands: | | | * TestEventTrigger | 0x00 | +| * TimeSnapshot | 0x01 | |------------------------------------------------------------------------------| | Attributes: | | | * NetworkInterfaces | 0x0000 | @@ -28005,6 +28006,56 @@ class GeneralDiagnosticsTestEventTrigger : public ClusterCommand { chip::app::Clusters::GeneralDiagnostics::Commands::TestEventTrigger::Type mRequest; }; +/* + * Command TimeSnapshot + */ +class GeneralDiagnosticsTimeSnapshot : public ClusterCommand { +public: + GeneralDiagnosticsTimeSnapshot() + : ClusterCommand("time-snapshot") + { + ClusterCommand::AddArguments(); + } + + CHIP_ERROR SendCommand(MTRBaseDevice * device, chip::EndpointId endpointId) override + { + constexpr chip::ClusterId clusterId = chip::app::Clusters::GeneralDiagnostics::Id; + constexpr chip::CommandId commandId = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshot::Id; + + ChipLogProgress(chipTool, "Sending cluster (0x%08" PRIX32 ") command (0x%08" PRIX32 ") on endpoint %u", clusterId, commandId, endpointId); + + dispatch_queue_t callbackQueue = dispatch_queue_create("com.chip.command", DISPATCH_QUEUE_SERIAL); + __auto_type * cluster = [[MTRBaseClusterGeneralDiagnostics alloc] initWithDevice:device endpointID:@(endpointId) queue:callbackQueue]; + __auto_type * params = [[MTRGeneralDiagnosticsClusterTimeSnapshotParams alloc] init]; + params.timedInvokeTimeoutMs = mTimedInteractionTimeoutMs.HasValue() ? [NSNumber numberWithUnsignedShort:mTimedInteractionTimeoutMs.Value()] : nil; + uint16_t repeatCount = mRepeatCount.ValueOr(1); + uint16_t __block responsesNeeded = repeatCount; + while (repeatCount--) { + [cluster timeSnapshotWithParams:params completion: + ^(MTRGeneralDiagnosticsClusterTimeSnapshotResponseParams * _Nullable values, NSError * _Nullable error) { + NSLog(@"Values: %@", values); + if (error == nil) { + constexpr chip::CommandId responseId = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::Id; + RemoteDataModelLogger::LogCommandAsJSON(@(endpointId), @(clusterId), @(responseId), values); + } + responsesNeeded--; + if (error != nil) { + mError = error; + LogNSError("Error", error); + constexpr chip::CommandId responseId = chip::app::Clusters::GeneralDiagnostics::Commands::TimeSnapshotResponse::Id; + RemoteDataModelLogger::LogCommandErrorAsJSON(@(endpointId), @(clusterId), @(responseId), error); + } + if (responsesNeeded == 0) { + SetCommandExitStatus(mError); + } + }]; + } + return CHIP_NO_ERROR; + } + +private: +}; + /* * Attribute NetworkInterfaces */ @@ -154577,6 +154628,7 @@ void registerClusterGeneralDiagnostics(Commands & commands) commands_list clusterCommands = { make_unique(Id), // make_unique(), // + make_unique(), // make_unique(Id), // make_unique(Id), // make_unique(Id), // diff --git a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h index fe9d1ee034da7c..3c845e5215856e 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h @@ -49324,12 +49324,8 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { err = TestStep4aReadTheGlobalAttributeAttributeList_4(); break; case 5: - ChipLogProgress(chipTool, " ***** Test Step 5 : Step 4b: Read optional attribute(UpTime) in AttributeList\n"); - if (ShouldSkip("DGGEN.S.A0002")) { - NextTest(); - return; - } - err = TestStep4bReadOptionalAttributeUpTimeInAttributeList_5(); + ChipLogProgress(chipTool, " ***** Test Step 5 : Step 4b: Validate presence of mandatory attribute(UpTime) in AttributeList\n"); + err = TestStep4bValidatePresenceOfMandatoryAttributeUpTimeInAttributeList_5(); break; case 6: ChipLogProgress(chipTool, " ***** Test Step 6 : Step 4c: Read optional attribute(TotalOperationalHours) in AttributeList\n"); @@ -49512,7 +49508,7 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { { id actualValue = value; - VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 1U)); + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 2U)); } VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); @@ -49603,7 +49599,7 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestStep4bReadOptionalAttributeUpTimeInAttributeList_5() + CHIP_ERROR TestStep4bValidatePresenceOfMandatoryAttributeUpTimeInAttributeList_5() { MTRBaseDevice * device = GetDevice("alpha"); @@ -49611,7 +49607,7 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); [cluster readAttributeAttributeListWithCompletion:^(NSArray * _Nullable value, NSError * _Nullable err) { - NSLog(@"Step 4b: Read optional attribute(UpTime) in AttributeList Error: %@", err); + NSLog(@"Step 4b: Validate presence of mandatory attribute(UpTime) in AttributeList Error: %@", err); VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); @@ -49743,6 +49739,7 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { VerifyOrReturn(CheckConstraintType("acceptedCommandList", "list", "list")); VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 0UL)); + VerifyOrReturn(CheckConstraintContains("acceptedCommandList", value, 1UL)); NextTest(); }]; @@ -49764,7 +49761,8 @@ class Test_TC_DGGEN_1_1 : public TestCommandBridge { { id actualValue = value; - VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(0))); + VerifyOrReturn(CheckValue("GeneratedCommandList", [actualValue count], static_cast(1))); + VerifyOrReturn(CheckValue("", actualValue[0], 2UL)); } VerifyOrReturn(CheckConstraintType("generatedCommandList", "list", "list"));