diff --git a/.github/.wordlist.txt b/.github/.wordlist.txt
index c2820eee66d529..58a06086679e06 100644
--- a/.github/.wordlist.txt
+++ b/.github/.wordlist.txt
@@ -634,6 +634,7 @@ GPL
GPLv
Gradle
gradlew
+graphviz
Groupcast
GroupId
GroupKeyManagement
diff --git a/.github/workflows/examples-nrfconnect.yaml b/.github/workflows/examples-nrfconnect.yaml
index 18bfc8d25896c3..88c84d72e28080 100644
--- a/.github/workflows/examples-nrfconnect.yaml
+++ b/.github/workflows/examples-nrfconnect.yaml
@@ -49,7 +49,7 @@ jobs:
with:
platform: nrfconnect
- name: Detect changed paths
- uses: dorny/paths-filter@v2
+ uses: dorny/paths-filter@v3
id: changed_paths
with:
filters: |
diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml
index bdfb51adeec423..9fbe9a970a0495 100644
--- a/.github/workflows/tests.yaml
+++ b/.github/workflows/tests.yaml
@@ -118,6 +118,7 @@ jobs:
src/app/zap-templates/zcl/data-model/chip/diagnostic-logs-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/dishwasher-alarm-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/dishwasher-mode-cluster.xml \
+ src/app/zap-templates/zcl/data-model/chip/measurement-and-sensing.xml \
src/app/zap-templates/zcl/data-model/chip/microwave-oven-mode-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/microwave-oven-control-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/door-lock-cluster.xml \
@@ -194,6 +195,8 @@ jobs:
src/app/zap-templates/zcl/data-model/draft/onoff-switch-configuration-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/resource-monitoring-cluster.xml \
src/app/zap-templates/zcl/data-model/chip/sample-mei-cluster.xml \
+ src/app/zap-templates/zcl/data-model/chip/electrical-energy-measurement-cluster.xml \
+ src/app/zap-templates/zcl/data-model/chip/electrical-power-measurement-cluster.xml \
"
- name: Build Apps
run: |
@@ -459,8 +462,8 @@ jobs:
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_RR_1_1.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DeviceBasicComposition.py" --script-args "--storage-path admin_storage.json --manual-code 10054912339 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_SC_3_6.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DA_1_7.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --bool-arg allow_sdk_dac:true --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json --enable-key 000102030405060708090a0b0c0d0e0f" --script "src/python_testing/TC_TestEventTrigger.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --bool-arg allow_sdk_dac:true --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DA_1_7.py" --script-args "--storage-path admin_storage.json --bool-arg allow_sdk_dac:true --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json --enable-key 000102030405060708090a0b0c0d0e0f" --script "src/python_testing/TC_TestEventTrigger.py" --script-args "--storage-path admin_storage.json --bool-arg allow_sdk_dac:true --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_ACE_1_2.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_ACE_1_4.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --int-arg PIXIT.ACE.APPENDPOINT:1 PIXIT.ACE.APPDEVTYPEID:0x0100 --string-arg PIXIT.ACE.APPCLUSTER:OnOff PIXIT.ACE.APPATTRIBUTE:OnOff --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_ACE_1_3.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
@@ -469,20 +472,20 @@ jobs:
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DA_1_2.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TestGroupTableReports.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TestBatchInvoke.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_1.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_2.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_4.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_5.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_6.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_7.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_8.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_9.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_10.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_11.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_12.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_2_13.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_TIMESYNC_3_1.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_DGGEN_2_4.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_1.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_2.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_4.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_5.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_6.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_7.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_8.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_9.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_10.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_11.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_12.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_2_13.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_TIMESYNC_3_1.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DGGEN_2_4.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-lit-icd-ipv6only-no-ble-no-wifi-tsan-clang-test/lit-icd-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_ICDM_2_1.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DA_1_5.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_IDM_1_2.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
@@ -495,15 +498,15 @@ jobs:
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_FAN_3_5.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_RVCCLEANM_1_2.py" --script-args "--int-arg PIXIT_ENDPOINT:1 --storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_RVCRUNM_1_2.py" --script-args "--int-arg PIXIT_ENDPOINT:1 --storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestMatterTestingSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestConformanceSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestSpecParsingSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-lock-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-lock-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DRLK_2_2.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-lock-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-lock-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DRLK_2_3.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-lock-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-lock-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DRLK_2_12.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_AccessChecker.py" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --app out/linux-x64-lock-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-lock-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script "src/python_testing/TC_DeviceConformance.py" --script-args "--storage-path admin_storage.json --manual-code 10054912339 --bool-arg ignore_in_progress:True allow_provisional:True --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto --tests test_TC_IDM_10_2"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestMatterTestingSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestConformanceSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
+ scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TestSpecParsingSupport.py" --script-args "--trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
scripts/run_in_python_env.sh out/venv './scripts/tests/TestTimeSyncTrustedTimeSourceRunner.py'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_AccessChecker.py" --app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --commissioning-method on-network --discriminator 1234 --passcode 20202021 --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto"'
- scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --script "src/python_testing/TC_DeviceConformance.py" --app out/linux-x64-lock-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-lock-app --factoryreset --app-args "--discriminator 1234 --KVS kvs1 --trace-to json:out/trace_data/app-{SCRIPT_BASE_NAME}.json" --script-args "--storage-path admin_storage.json --manual-code 10054912339 --bool-arg ignore_in_progress:True allow_provisional:True --PICS src/app/tests/suites/certification/ci-pics-values --trace-to json:out/trace_data/test-{SCRIPT_BASE_NAME}.json --trace-to perfetto:out/trace_data/test-{SCRIPT_BASE_NAME}.perfetto --tests test_TC_IDM_10_2"'
- name: Uploading core files
uses: actions/upload-artifact@v4
if: ${{ failure() && !env.ACT }}
diff --git a/BUILD.gn b/BUILD.gn
index b51ab7238414e9..89861ea79af5d0 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -16,7 +16,6 @@ import("//build_overrides/build.gni")
import("//build_overrides/chip.gni")
import("//build_overrides/mbedtls.gni")
import("//build_overrides/nlassert.gni")
-import("//build_overrides/nlio.gni")
import("//build_overrides/nlunit_test.gni")
import("//build_overrides/pigweed.gni")
@@ -136,7 +135,6 @@ if (current_toolchain != "${dir_pw_toolchain}/default:default") {
"${chip_root}/src/system",
"${chip_root}/src/transport",
"${nlassert_root}:nlassert",
- "${nlio_root}:nlio",
"${nlunit_test_root}:nlunit-test",
]
diff --git a/data_model/ValveConfigurationControl.xml b/data_model/ValveConfigurationControl.xml
deleted file mode 100644
index 2d1554df10df59..00000000000000
--- a/data_model/ValveConfigurationControl.xml
+++ /dev/null
@@ -1,207 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
- -
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/docs/clusters.md b/docs/clusters.md
index 28a817e0a044a9..d197e1b8bc0ed1 100644
--- a/docs/clusters.md
+++ b/docs/clusters.md
@@ -77,6 +77,7 @@ Generally regenerate using one of:
| 114 | 0x72 | ActivatedCarbonFilterMonitoring |
| 128 | 0x80 | BooleanStateConfiguration |
| 129 | 0x81 | ValveConfigurationAndControl |
+| 144 | 0x90 | ElectricalPowerMeasurement |
| 145 | 0x91 | ElectricalEnergyMeasurement |
| 150 | 0x96 | DemandResponseLoadControl |
| 151 | 0x97 | Messages |
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 c2ab0dc702df53..044a51213fd746 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
@@ -2929,7 +2929,7 @@ cluster RvcRunMode = 84 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -2945,7 +2945,6 @@ cluster RvcRunMode = 84 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -2982,7 +2981,7 @@ cluster RvcCleanMode = 85 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -2998,7 +2997,6 @@ cluster RvcCleanMode = 85 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -3480,10 +3478,6 @@ cluster RvcOperationalState = 97 {
/** Upon receipt, the device SHALL pause its operation if it is possible based on the current function of the server. */
command Pause(): OperationalCommandResponse = 0;
- /** Upon receipt, the device SHALL stop its operation if it is at a position where it is safe to do so and/or permitted. */
- command Stop(): OperationalCommandResponse = 1;
- /** Upon receipt, the device SHALL start its operation if it is safe to do so and the device is in an operational state from which it can be started. */
- command Start(): OperationalCommandResponse = 2;
/** Upon receipt, the device SHALL resume its operation from the point it was at when it received the Pause command, or from the point when it was paused by means outside of this cluster (for example by manual button press). */
command Resume(): OperationalCommandResponse = 3;
/** On receipt of this command, the device SHALL start seeking the charging dock, if possible in the current state of the device. */
@@ -3865,6 +3859,111 @@ provisional cluster ValveConfigurationAndControl = 129 {
command Close(): DefaultSuccess = 1;
}
+/** This cluster provides a mechanism for querying data about electrical power as measured by the server. */
+provisional cluster ElectricalPowerMeasurement = 144 {
+ revision 1;
+
+ enum MeasurementTypeEnum : enum16 {
+ kUnspecified = 0;
+ kVoltage = 1;
+ kActiveCurrent = 2;
+ kReactiveCurrent = 3;
+ kApparentCurrent = 4;
+ kActivePower = 5;
+ kReactivePower = 6;
+ kApparentPower = 7;
+ kRMSVoltage = 8;
+ kRMSCurrent = 9;
+ kRMSPower = 10;
+ kFrequency = 11;
+ kPowerFactor = 12;
+ kNeutralCurrent = 13;
+ kElectricalEnergy = 14;
+ }
+
+ enum PowerModeEnum : enum8 {
+ kUnknown = 0;
+ kDC = 1;
+ kAC = 2;
+ }
+
+ bitmap Feature : bitmap32 {
+ kDirectCurrent = 0x1;
+ kAlternatingCurrent = 0x2;
+ kPolyphasePower = 0x4;
+ kHarmonics = 0x8;
+ kPowerQuality = 0x10;
+ }
+
+ struct MeasurementAccuracyRangeStruct {
+ int64s rangeMin = 0;
+ int64s rangeMax = 1;
+ optional percent100ths percentMax = 2;
+ optional percent100ths percentMin = 3;
+ optional percent100ths percentTypical = 4;
+ optional int64u fixedMax = 5;
+ optional int64u fixedMin = 6;
+ optional int64u fixedTypical = 7;
+ }
+
+ struct MeasurementAccuracyStruct {
+ MeasurementTypeEnum measurementType = 0;
+ boolean measured = 1;
+ int64s minMeasuredValue = 2;
+ int64s maxMeasuredValue = 3;
+ MeasurementAccuracyRangeStruct accuracyRanges[] = 4;
+ }
+
+ struct HarmonicMeasurementStruct {
+ int8u order = 0;
+ nullable int64s measurement = 1;
+ }
+
+ struct MeasurementRangeStruct {
+ MeasurementTypeEnum measurementType = 0;
+ int64s min = 1;
+ int64s max = 2;
+ optional epoch_s startTimestamp = 3;
+ optional epoch_s endTimestamp = 4;
+ optional epoch_s minTimestamp = 5;
+ optional epoch_s maxTimestamp = 6;
+ optional systime_ms startSystime = 7;
+ optional systime_ms endSystime = 8;
+ optional systime_ms minSystime = 9;
+ optional systime_ms maxSystime = 10;
+ }
+
+ info event MeasurementPeriodRanges = 0 {
+ MeasurementRangeStruct ranges[] = 0;
+ }
+
+ readonly attribute PowerModeEnum powerMode = 0;
+ readonly attribute int8u numberOfMeasurementTypes = 1;
+ readonly attribute MeasurementAccuracyStruct accuracy[] = 2;
+ readonly attribute optional MeasurementRangeStruct ranges[] = 3;
+ readonly attribute optional nullable voltage_mv voltage = 4;
+ readonly attribute optional nullable amperage_ma activeCurrent = 5;
+ readonly attribute optional nullable amperage_ma reactiveCurrent = 6;
+ readonly attribute optional nullable amperage_ma apparentCurrent = 7;
+ readonly attribute nullable power_mw activePower = 8;
+ readonly attribute optional nullable power_mw reactivePower = 9;
+ readonly attribute optional nullable power_mw apparentPower = 10;
+ readonly attribute optional nullable voltage_mv RMSVoltage = 11;
+ readonly attribute optional nullable amperage_ma RMSCurrent = 12;
+ readonly attribute optional nullable power_mw RMSPower = 13;
+ readonly attribute optional nullable int64s frequency = 14;
+ readonly attribute optional nullable HarmonicMeasurementStruct harmonicCurrents[] = 15;
+ readonly attribute optional nullable HarmonicMeasurementStruct harmonicPhases[] = 16;
+ readonly attribute optional nullable int64s powerFactor = 17;
+ readonly attribute optional nullable amperage_ma neutralCurrent = 18;
+ readonly attribute command_id generatedCommandList[] = 65528;
+ readonly attribute command_id acceptedCommandList[] = 65529;
+ readonly attribute event_id eventList[] = 65530;
+ readonly attribute attrib_id attributeList[] = 65531;
+ readonly attribute bitmap32 featureMap = 65532;
+ readonly attribute int16u clusterRevision = 65533;
+}
+
/** This cluster provides a mechanism for querying data about the electrical energy imported or provided by the server. */
provisional cluster ElectricalEnergyMeasurement = 145 {
revision 1;
@@ -3913,8 +4012,15 @@ provisional cluster ElectricalEnergyMeasurement = 145 {
MeasurementAccuracyRangeStruct accuracyRanges[] = 4;
}
+ struct CumulativeEnergyResetStruct {
+ optional nullable epoch_s importedResetTimestamp = 0;
+ optional nullable epoch_s exportedResetTimestamp = 1;
+ optional nullable systime_ms importedResetSystime = 2;
+ optional nullable systime_ms exportedResetSystime = 3;
+ }
+
struct EnergyMeasurementStruct {
- int64s energy = 0;
+ energy_mwh energy = 0;
optional epoch_s startTimestamp = 1;
optional epoch_s endTimestamp = 2;
optional systime_ms startSystime = 3;
@@ -3936,6 +4042,7 @@ provisional cluster ElectricalEnergyMeasurement = 145 {
readonly attribute optional nullable EnergyMeasurementStruct cumulativeEnergyExported = 2;
readonly attribute optional nullable EnergyMeasurementStruct periodicEnergyImported = 3;
readonly attribute optional nullable EnergyMeasurementStruct periodicEnergyExported = 4;
+ readonly attribute optional nullable CumulativeEnergyResetStruct cumulativeEnergyReset = 5;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -7807,9 +7914,9 @@ endpoint 1 {
server cluster RvcRunMode {
callback attribute supportedModes;
callback attribute currentMode;
- callback attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
+ callback attribute eventList;
callback attribute attributeList;
callback attribute featureMap;
ram attribute clusterRevision default = 2;
@@ -7821,9 +7928,9 @@ endpoint 1 {
server cluster RvcCleanMode {
callback attribute supportedModes;
callback attribute currentMode;
- callback attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
+ callback attribute eventList;
callback attribute attributeList;
callback attribute featureMap;
ram attribute clusterRevision default = 2;
@@ -7971,6 +8078,7 @@ endpoint 1 {
callback attribute operationalError;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
+ callback attribute eventList;
callback attribute attributeList;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;
@@ -8088,6 +8196,35 @@ endpoint 1 {
handle command Close;
}
+ server cluster ElectricalPowerMeasurement {
+ emits event MeasurementPeriodRanges;
+ callback attribute powerMode;
+ callback attribute numberOfMeasurementTypes;
+ callback attribute accuracy;
+ callback attribute ranges;
+ callback attribute voltage;
+ callback attribute activeCurrent;
+ callback attribute reactiveCurrent;
+ callback attribute apparentCurrent;
+ callback attribute activePower;
+ callback attribute reactivePower;
+ callback attribute apparentPower;
+ callback attribute RMSVoltage;
+ callback attribute RMSCurrent;
+ callback attribute RMSPower;
+ callback attribute frequency;
+ callback attribute harmonicCurrents;
+ callback attribute harmonicPhases;
+ callback attribute powerFactor;
+ callback attribute neutralCurrent;
+ callback attribute generatedCommandList;
+ callback attribute acceptedCommandList;
+ callback attribute eventList;
+ callback attribute attributeList;
+ callback attribute featureMap;
+ ram attribute clusterRevision default = 1;
+ }
+
server cluster ElectricalEnergyMeasurement {
emits event CumulativeEnergyMeasured;
emits event PeriodicEnergyMeasured;
@@ -8096,11 +8233,12 @@ endpoint 1 {
callback attribute cumulativeEnergyExported;
callback attribute periodicEnergyImported;
callback attribute periodicEnergyExported;
+ callback attribute cumulativeEnergyReset;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
- ram attribute featureMap default = 0x000F;
+ callback attribute featureMap;
ram attribute clusterRevision default = 1;
}
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 438aef17a0516e..87d3e856477718 100644
--- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
+++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
@@ -17,12 +17,6 @@
}
],
"package": [
- {
- "pathRelativity": "relativeToZap",
- "path": "../../../src/app/zap-templates/app-templates.json",
- "type": "gen-templates-json",
- "version": "chip-v1"
- },
{
"pathRelativity": "relativeToZap",
"path": "../../../src/app/zap-templates/zcl/zcl-with-test-extensions.json",
@@ -30,6 +24,12 @@
"category": "matter",
"version": 1,
"description": "Matter SDK ZCL data with some extensions"
+ },
+ {
+ "pathRelativity": "relativeToZap",
+ "path": "../../../src/app/zap-templates/app-templates.json",
+ "type": "gen-templates-json",
+ "version": "chip-v1"
}
],
"endpointTypes": [
@@ -9470,11 +9470,11 @@
"reportableChange": 0
},
{
- "name": "OnMode",
- "code": 3,
+ "name": "GeneratedCommandList",
+ "code": 65528,
"mfgCode": null,
"side": "server",
- "type": "int8u",
+ "type": "array",
"included": 1,
"storageOption": "External",
"singleton": 0,
@@ -9486,8 +9486,8 @@
"reportableChange": 0
},
{
- "name": "GeneratedCommandList",
- "code": 65528,
+ "name": "AcceptedCommandList",
+ "code": 65529,
"mfgCode": null,
"side": "server",
"type": "array",
@@ -9502,8 +9502,8 @@
"reportableChange": 0
},
{
- "name": "AcceptedCommandList",
- "code": 65529,
+ "name": "EventList",
+ "code": 65530,
"mfgCode": null,
"side": "server",
"type": "array",
@@ -9626,11 +9626,11 @@
"reportableChange": 0
},
{
- "name": "OnMode",
- "code": 3,
+ "name": "GeneratedCommandList",
+ "code": 65528,
"mfgCode": null,
"side": "server",
- "type": "int8u",
+ "type": "array",
"included": 1,
"storageOption": "External",
"singleton": 0,
@@ -9642,8 +9642,8 @@
"reportableChange": 0
},
{
- "name": "GeneratedCommandList",
- "code": 65528,
+ "name": "AcceptedCommandList",
+ "code": 65529,
"mfgCode": null,
"side": "server",
"type": "array",
@@ -9658,8 +9658,8 @@
"reportableChange": 0
},
{
- "name": "AcceptedCommandList",
- "code": 65529,
+ "name": "EventList",
+ "code": 65530,
"mfgCode": null,
"side": "server",
"type": "array",
@@ -11353,6 +11353,22 @@
"maxInterval": 65534,
"reportableChange": 0
},
+ {
+ "name": "EventList",
+ "code": 65530,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
{
"name": "AttributeList",
"code": 65531,
@@ -12674,6 +12690,426 @@
}
]
},
+ {
+ "name": "Electrical Power Measurement",
+ "code": 144,
+ "mfgCode": null,
+ "define": "ELECTRICAL_POWER_MEASUREMENT_CLUSTER",
+ "side": "server",
+ "enabled": 1,
+ "apiMaturity": "provisional",
+ "attributes": [
+ {
+ "name": "PowerMode",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "PowerModeEnum",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "NumberOfMeasurementTypes",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Accuracy",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Ranges",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Voltage",
+ "code": 4,
+ "mfgCode": null,
+ "side": "server",
+ "type": "voltage_mv",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ActiveCurrent",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ReactiveCurrent",
+ "code": 6,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ApparentCurrent",
+ "code": 7,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ActivePower",
+ "code": 8,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ReactivePower",
+ "code": 9,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ApparentPower",
+ "code": 10,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "RMSVoltage",
+ "code": 11,
+ "mfgCode": null,
+ "side": "server",
+ "type": "voltage_mv",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "RMSCurrent",
+ "code": 12,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "RMSPower",
+ "code": 13,
+ "mfgCode": null,
+ "side": "server",
+ "type": "power_mw",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "Frequency",
+ "code": 14,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64s",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "HarmonicCurrents",
+ "code": 15,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "HarmonicPhases",
+ "code": 16,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PowerFactor",
+ "code": 17,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64s",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "NeutralCurrent",
+ "code": 18,
+ "mfgCode": null,
+ "side": "server",
+ "type": "amperage_ma",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "GeneratedCommandList",
+ "code": 65528,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AcceptedCommandList",
+ "code": 65529,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "EventList",
+ "code": 65530,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AttributeList",
+ "code": 65531,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "FeatureMap",
+ "code": 65532,
+ "mfgCode": null,
+ "side": "server",
+ "type": "bitmap32",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ClusterRevision",
+ "code": 65533,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "1",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ }
+ ],
+ "events": [
+ {
+ "name": "MeasurementPeriodRanges",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ }
+ ]
+ },
{
"name": "Electrical Energy Measurement",
"code": 145,
@@ -12763,6 +13199,22 @@
"maxInterval": 65534,
"reportableChange": 0
},
+ {
+ "name": "CumulativeEnergyReset",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "CumulativeEnergyResetStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
{
"name": "GeneratedCommandList",
"code": 65528,
@@ -12834,10 +13286,10 @@
"side": "server",
"type": "bitmap32",
"included": 1,
- "storageOption": "RAM",
+ "storageOption": "External",
"singleton": 0,
"bounded": 0,
- "defaultValue": "0x000F",
+ "defaultValue": null,
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
diff --git a/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp
index 36716ec69ce52e..fe2ec9050683e8 100644
--- a/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/boolcfg-stub.cpp
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-#include
+#include
#include
#include
diff --git a/examples/all-clusters-app/all-clusters-common/src/electrical-energy-measurement-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/electrical-energy-measurement-stub.cpp
new file mode 100644
index 00000000000000..41716d3033022b
--- /dev/null
+++ b/examples/all-clusters-app/all-clusters-common/src/electrical-energy-measurement-stub.cpp
@@ -0,0 +1,42 @@
+/*
+ *
+ * Copyright (c) 2023 Project CHIP Authors
+ * All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include
+
+using namespace chip;
+using namespace chip::app::Clusters;
+using namespace chip::app::Clusters::ElectricalEnergyMeasurement;
+using namespace chip::app::Clusters::ElectricalEnergyMeasurement::Structs;
+
+static std::unique_ptr gAttrAccess;
+
+void emberAfElectricalEnergyMeasurementClusterInitCallback(chip::EndpointId endpointId)
+{
+ VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
+ VerifyOrDie(!gAttrAccess);
+
+ gAttrAccess = std::make_unique(
+ BitMask(Feature::kImportedEnergy, Feature::kExportedEnergy, Feature::kCumulativeEnergy,
+ Feature::kPeriodicEnergy),
+ BitMask(OptionalAttributes::kOptionalAttributeCumulativeEnergyReset));
+
+ if (gAttrAccess)
+ {
+ gAttrAccess->Init();
+ }
+}
diff --git a/examples/all-clusters-app/all-clusters-common/src/electrical-power-measurement-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/electrical-power-measurement-stub.cpp
new file mode 100644
index 00000000000000..bac73dd0441634
--- /dev/null
+++ b/examples/all-clusters-app/all-clusters-common/src/electrical-power-measurement-stub.cpp
@@ -0,0 +1,265 @@
+/*
+ *
+ * Copyright (c) 2023 Project CHIP Authors
+ * All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include
+
+using namespace chip;
+using namespace chip::app::Clusters;
+using namespace chip::app::Clusters::ElectricalPowerMeasurement;
+using namespace chip::app::Clusters::ElectricalPowerMeasurement::Structs;
+
+namespace chip {
+namespace app {
+namespace Clusters {
+namespace ElectricalPowerMeasurement {
+
+static MeasurementAccuracyRangeStruct::Type activeCurrentAccuracyRanges[] = { { .rangeMin = 500, .rangeMax = 1000 } };
+
+class StubAccuracyIterator : public Delegate::AccuracyIterator
+{
+public:
+ size_t Count() override;
+ bool Next(MeasurementAccuracyStruct::Type & output) override;
+ void Release() override;
+
+private:
+ uint8_t mIndex;
+};
+
+size_t StubAccuracyIterator::Count()
+{
+ return 1;
+}
+
+bool StubAccuracyIterator::Next(MeasurementAccuracyStruct::Type & output)
+{
+ if (mIndex >= 1)
+ {
+ return false;
+ }
+ output.measurementType = MeasurementTypeEnum::kActiveCurrent;
+ output.measured = true;
+ output.minMeasuredValue = -10000000;
+ output.maxMeasuredValue = 10000000;
+ output.accuracyRanges = DataModel::List(activeCurrentAccuracyRanges);
+ mIndex++;
+ return true;
+}
+
+void StubAccuracyIterator::Release()
+{
+ mIndex = 0;
+}
+
+class StubRangeIterator : public Delegate::RangeIterator
+{
+public:
+ size_t Count() override;
+ bool Next(MeasurementRangeStruct::Type & output) override;
+ void Release() override;
+};
+
+size_t StubRangeIterator::Count()
+{
+ return 0;
+}
+
+bool StubRangeIterator::Next(MeasurementRangeStruct::Type & output)
+{
+ return false;
+}
+
+void StubRangeIterator::Release() {}
+
+class StubHarmonicMeasurementIterator : public Delegate::HarmonicMeasurementIterator
+{
+public:
+ size_t Count() override;
+ bool Next(HarmonicMeasurementStruct::Type & output) override;
+ void Release() override;
+};
+
+size_t StubHarmonicMeasurementIterator::Count()
+{
+ return 0;
+}
+
+bool StubHarmonicMeasurementIterator::Next(HarmonicMeasurementStruct::Type & output)
+{
+ return false;
+}
+
+void StubHarmonicMeasurementIterator::Release() {}
+
+static StubAccuracyIterator accuracyIterator;
+static StubRangeIterator rangeIterator;
+static StubHarmonicMeasurementIterator harmonicMeasurementIterator;
+
+class ElectricalPowerMeasurementDelegate : public Delegate
+{
+public:
+ PowerModeEnum GetPowerMode() override;
+ uint8_t GetNumberOfMeasurementTypes() override;
+ AccuracyIterator * IterateAccuracy() override;
+ RangeIterator * IterateRanges() override;
+ DataModel::Nullable GetVoltage() override;
+ DataModel::Nullable GetActiveCurrent() override;
+ DataModel::Nullable GetReactiveCurrent() override;
+ DataModel::Nullable GetApparentCurrent() override;
+ DataModel::Nullable GetActivePower() override;
+ DataModel::Nullable GetReactivePower() override;
+ DataModel::Nullable GetApparentPower() override;
+ DataModel::Nullable GetRMSVoltage() override;
+ DataModel::Nullable GetRMSCurrent() override;
+ DataModel::Nullable GetRMSPower() override;
+ DataModel::Nullable GetFrequency() override;
+ HarmonicMeasurementIterator * IterateHarmonicCurrents() override;
+ HarmonicMeasurementIterator * IterateHarmonicPhases() override;
+ DataModel::Nullable GetPowerFactor() override;
+ DataModel::Nullable GetNeutralCurrent() override;
+
+ ~ElectricalPowerMeasurementDelegate() = default;
+};
+
+PowerModeEnum ElectricalPowerMeasurementDelegate::GetPowerMode()
+{
+ return PowerModeEnum::kAc;
+}
+
+uint8_t ElectricalPowerMeasurementDelegate::GetNumberOfMeasurementTypes()
+{
+ return 1;
+}
+
+Delegate::AccuracyIterator * ElectricalPowerMeasurementDelegate::IterateAccuracy()
+{
+ return &accuracyIterator;
+}
+
+Delegate::RangeIterator * ElectricalPowerMeasurementDelegate::IterateRanges()
+{
+ return &rangeIterator;
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetVoltage()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetActiveCurrent()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetReactiveCurrent()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetApparentCurrent()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetActivePower()
+{
+ return DataModel::Nullable(10000);
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetReactivePower()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetApparentPower()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetRMSVoltage()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetRMSCurrent()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetRMSPower()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetFrequency()
+{
+ return {};
+}
+
+Delegate::HarmonicMeasurementIterator * ElectricalPowerMeasurementDelegate::IterateHarmonicCurrents()
+{
+ return &harmonicMeasurementIterator;
+}
+
+Delegate::HarmonicMeasurementIterator * ElectricalPowerMeasurementDelegate::IterateHarmonicPhases()
+{
+ return &harmonicMeasurementIterator;
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetPowerFactor()
+{
+ return {};
+}
+
+DataModel::Nullable ElectricalPowerMeasurementDelegate::GetNeutralCurrent()
+{
+ return {};
+}
+
+} // namespace ElectricalPowerMeasurement
+} // namespace Clusters
+} // namespace app
+} // namespace chip
+
+static std::unique_ptr gDelegate;
+static std::unique_ptr gInstance;
+
+void emberAfElectricalPowerMeasurementClusterInitCallback(chip::EndpointId endpointId)
+{
+ VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
+ VerifyOrDie(!gInstance);
+
+ gDelegate = std::make_unique();
+ if (gDelegate)
+ {
+ gInstance = std::make_unique(
+ endpointId, *gDelegate,
+ BitMask(Feature::kDirectCurrent, Feature::kAlternatingCurrent, Feature::kPolyphasePower,
+ Feature::kHarmonics, Feature::kPowerQuality),
+ BitMask(
+ OptionalAttributes::kOptionalAttributeRanges, OptionalAttributes::kOptionalAttributeVoltage,
+ OptionalAttributes::kOptionalAttributeActiveCurrent, OptionalAttributes::kOptionalAttributeReactiveCurrent,
+ OptionalAttributes::kOptionalAttributeApparentCurrent, OptionalAttributes::kOptionalAttributeReactivePower,
+ OptionalAttributes::kOptionalAttributeApparentPower, OptionalAttributes::kOptionalAttributeRMSVoltage,
+ OptionalAttributes::kOptionalAttributeRMSCurrent, OptionalAttributes::kOptionalAttributeRMSPower,
+ OptionalAttributes::kOptionalAttributeFrequency, OptionalAttributes::kOptionalAttributePowerFactor,
+ OptionalAttributes::kOptionalAttributeNeutralCurrent));
+
+ gInstance->Init();
+ }
+}
diff --git a/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp b/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp
index 999d62ae48c263..627709a8c30921 100644
--- a/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/rvc-modes.cpp
@@ -17,6 +17,7 @@
*/
#include
#include
+#include
using namespace chip::app::Clusters;
using namespace chip::app::Clusters::RvcRunMode;
@@ -40,14 +41,24 @@ void RvcRunModeDelegate::HandleChangeToMode(uint8_t NewMode, ModeBase::Commands:
{
uint8_t currentMode = mInstance->GetCurrentMode();
- // Our business logic states that we can only switch into the mapping state from the idle state.
- if (NewMode == RvcRunMode::ModeMapping && currentMode != RvcRunMode::ModeIdle)
+ // Our business logic states that we can only switch into a running mode from the idle state.
+ if (NewMode != RvcRunMode::ModeIdle && currentMode != RvcRunMode::ModeIdle)
{
response.status = to_underlying(ModeBase::StatusCode::kInvalidInMode);
- response.statusText.SetValue(chip::CharSpan::fromCharString("Change to the mapping mode is only allowed from idle"));
+ response.statusText.SetValue(chip::CharSpan::fromCharString("Change to a running mode is only allowed from idle"));
return;
}
+ auto rvcOpStateInstance = RvcOperationalState::GetRvcOperationalStateInstance();
+ if (NewMode == RvcRunMode::ModeIdle)
+ {
+ rvcOpStateInstance->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kStopped));
+ }
+ else
+ {
+ rvcOpStateInstance->SetOperationalState(to_underlying(OperationalState::OperationalStateEnum::kRunning));
+ }
+
response.status = to_underlying(ModeBase::StatusCode::kSuccess);
}
@@ -112,7 +123,8 @@ void emberAfRvcRunModeClusterInitCallback(chip::EndpointId endpointId)
VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
VerifyOrDie(gRvcRunModeDelegate == nullptr && gRvcRunModeInstance == nullptr);
gRvcRunModeDelegate = new RvcRunMode::RvcRunModeDelegate;
- gRvcRunModeInstance = new ModeBase::Instance(gRvcRunModeDelegate, 0x1, RvcRunMode::Id, 0);
+ gRvcRunModeInstance =
+ new ModeBase::Instance(gRvcRunModeDelegate, 0x1, RvcRunMode::Id, chip::to_underlying(RvcRunMode::Feature::kNoFeatures));
gRvcRunModeInstance->Init();
}
@@ -201,6 +213,7 @@ void emberAfRvcCleanModeClusterInitCallback(chip::EndpointId endpointId)
VerifyOrDie(endpointId == 1); // this cluster is only enabled for endpoint 1.
VerifyOrDie(gRvcCleanModeDelegate == nullptr && gRvcCleanModeInstance == nullptr);
gRvcCleanModeDelegate = new RvcCleanMode::RvcCleanModeDelegate;
- gRvcCleanModeInstance = new ModeBase::Instance(gRvcCleanModeDelegate, 0x1, RvcCleanMode::Id, 0);
+ gRvcCleanModeInstance =
+ new ModeBase::Instance(gRvcCleanModeDelegate, 0x1, RvcCleanMode::Id, chip::to_underlying(RvcRunMode::Feature::kNoFeatures));
gRvcCleanModeInstance->Init();
}
diff --git a/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp b/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp
index 4b1e883a6b7d17..88c85f71fc3687 100644
--- a/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp
+++ b/examples/all-clusters-app/all-clusters-common/src/smco-stub.cpp
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-#include
+#include
#include
#include
diff --git a/examples/all-clusters-app/ameba/main/SmokeCOAlarmManager.cpp b/examples/all-clusters-app/ameba/main/SmokeCOAlarmManager.cpp
index bede2bcf537a76..027bb055cca44f 100644
--- a/examples/all-clusters-app/ameba/main/SmokeCOAlarmManager.cpp
+++ b/examples/all-clusters-app/ameba/main/SmokeCOAlarmManager.cpp
@@ -16,7 +16,7 @@
*/
#include "SmokeCOAlarmManager.h"
-#include
+#include
#include
using namespace chip;
diff --git a/examples/all-clusters-app/ameba/main/chipinterface.cpp b/examples/all-clusters-app/ameba/main/chipinterface.cpp
index 21280c676154be..20de9cd1ff0124 100644
--- a/examples/all-clusters-app/ameba/main/chipinterface.cpp
+++ b/examples/all-clusters-app/ameba/main/chipinterface.cpp
@@ -140,8 +140,10 @@ static void InitServer(intptr_t context)
static chip::CommonCaseDeviceServerInitParams initParams;
#if CONFIG_ENABLE_AMEBA_TEST_EVENT_TRIGGER
- static AmebaTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ // TODO(#31723): Show to customers that they can do `Server::GetInstance().GetTestEventTriggerDelegate().AddHandler(xxx)`
+ // to add custom handlers during their app init, after InitServer.
+ static AmebaTestEventTriggerDelegate sTestEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
#endif
initParams.InitializeStaticResourcesBeforeServerInit();
diff --git a/examples/all-clusters-app/ameba/main/include/SmokeCOAlarmManager.h b/examples/all-clusters-app/ameba/main/include/SmokeCOAlarmManager.h
index 390ee679d0d255..af6177299a3948 100644
--- a/examples/all-clusters-app/ameba/main/include/SmokeCOAlarmManager.h
+++ b/examples/all-clusters-app/ameba/main/include/SmokeCOAlarmManager.h
@@ -22,8 +22,6 @@
#include
#include
-bool emberAfHandleEventTrigger(uint64_t eventTrigger);
-
class SmokeCoAlarmManager
{
public:
diff --git a/examples/all-clusters-app/esp32/main/CMakeLists.txt b/examples/all-clusters-app/esp32/main/CMakeLists.txt
index f2f432a60d615a..641cbca7b55af0 100644
--- a/examples/all-clusters-app/esp32/main/CMakeLists.txt
+++ b/examples/all-clusters-app/esp32/main/CMakeLists.txt
@@ -36,7 +36,7 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/platform/esp32/shell_extension"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/examples/platform/esp32/mode-support"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/server"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/util"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/reporting"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/administrator-commissioning-server"
@@ -98,6 +98,7 @@ set(SRC_DIRS_LIST
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/laundry-washer-controls-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/laundry-dryer-controls-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/electrical-energy-measurement-server"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/electrical-power-measurement-server"
)
diff --git a/examples/all-clusters-app/linux/BUILD.gn b/examples/all-clusters-app/linux/BUILD.gn
index 20dd248abf2a1a..799c9ab3f1f451 100644
--- a/examples/all-clusters-app/linux/BUILD.gn
+++ b/examples/all-clusters-app/linux/BUILD.gn
@@ -29,6 +29,8 @@ source_set("chip-all-clusters-common") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/dishwasher-alarm-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/dishwasher-mode.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/electrical-energy-measurement-stub.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/electrical-power-measurement-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/laundry-dryer-controls-delegate-impl.cpp",
diff --git a/examples/all-clusters-app/nrfconnect/main/AppTask.cpp b/examples/all-clusters-app/nrfconnect/main/AppTask.cpp
index 9f471943406c80..f8d117790fac3d 100644
--- a/examples/all-clusters-app/nrfconnect/main/AppTask.cpp
+++ b/examples/all-clusters-app/nrfconnect/main/AppTask.cpp
@@ -27,8 +27,9 @@
#include
#include
+#include
#include
-#include
+#include
#include
#include
@@ -204,9 +205,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/all-clusters-app/nxp/mw320/main.cpp b/examples/all-clusters-app/nxp/mw320/main.cpp
index e103359f593400..b778d95fc4430b 100644
--- a/examples/all-clusters-app/nxp/mw320/main.cpp
+++ b/examples/all-clusters-app/nxp/mw320/main.cpp
@@ -1152,12 +1152,10 @@ void task_test_main(void * param)
PRINTF("--> update CurrentPosition [%d] \r\n", value);
Clusters::Switch::Attributes::CurrentPosition::Set(1, value);
#ifdef SUPPORT_MANUAL_CTRL
-#error \
- "This code thinks it's setting the OnOff attribute, but it's actually setting the NumberOfPositions attribute! And passing the wrong size for either case. Figure out what it's trying to do."
- // sync-up the Light attribute (for test event, OO.M.ManuallyControlled)
- PRINTF("--> update [Clusters::Switch::Id]: OnOff::Id [%d] \r\n", value);
- emAfWriteAttribute(1, Clusters::Switch::Id, Clusters::OnOff::Attributes::OnOff::Id, (uint8_t *) &value, sizeof(value),
- true, false);
+#error "Not implemented"
+ // TODO: previous code was trying to write a OnOff cluster attribute id to a switch attribute, generally
+ // not working. Determine if this should maybe be
+ // OnOff::Attributes::OnOff::Set(1, is_on) or similar
#endif // SUPPORT_MANUAL_CTRL
need2sync_sw_attr = false;
diff --git a/examples/all-clusters-app/tizen/BUILD.gn b/examples/all-clusters-app/tizen/BUILD.gn
index e9bb7f56e4bfaa..23a045a7532429 100644
--- a/examples/all-clusters-app/tizen/BUILD.gn
+++ b/examples/all-clusters-app/tizen/BUILD.gn
@@ -28,6 +28,8 @@ source_set("chip-all-clusters-common") {
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/bridged-actions-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/concentration-measurement-instances.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/device-energy-management-stub.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/electrical-energy-measurement-stub.cpp",
+ "${chip_root}/examples/all-clusters-app/all-clusters-common/src/electrical-power-measurement-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/energy-evse-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/fan-stub.cpp",
"${chip_root}/examples/all-clusters-app/all-clusters-common/src/oven-modes.cpp",
diff --git a/examples/chef/NEW_CHEF_DEVICES.md b/examples/chef/NEW_CHEF_DEVICES.md
index 4f52b29966f415..c2e8538e7b8e5a 100644
--- a/examples/chef/NEW_CHEF_DEVICES.md
+++ b/examples/chef/NEW_CHEF_DEVICES.md
@@ -94,13 +94,13 @@ Basic device availability should show when running:
### Compilation
-This example uses `rootnode_contactsensor_lFAGG1bfRO` for commands. Substitute
+This example uses `rootnode_contactsensor_27f76aeaf5` for commands. Substitute
your own device for testing newly created devices.
```
./examples/chef/chef.py \
-t linux \
- -d rootnode_contactsensor_lFAGG1bfRO \
+ -d rootnode_contactsensor_27f76aeaf5 \
-b
```
@@ -113,5 +113,5 @@ Where options used are:
### Execution
Build will be available in
-`examples/chef/linux/out/rootnode_contactsensor_lFAGG1bfRO` (path will vary
+`examples/chef/linux/out/rootnode_contactsensor_27f76aeaf5` (path will vary
based on platform and device being built)
diff --git a/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.matter b/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.matter
index 2fe383530fea5c..51dec4bd2d148c 100644
--- a/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.matter
+++ b/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.matter
@@ -1407,6 +1407,491 @@ cluster BooleanState = 69 {
readonly attribute int16u clusterRevision = 65533;
}
+/** The Test Cluster is meant to validate the generated code */
+internal cluster UnitTesting = 4294048773 {
+ revision 1; // NOTE: Default/not specifically set
+
+ enum SimpleEnum : enum8 {
+ kUnspecified = 0;
+ kValueA = 1;
+ kValueB = 2;
+ kValueC = 3;
+ }
+
+ bitmap Bitmap16MaskMap : bitmap16 {
+ kMaskVal1 = 0x1;
+ kMaskVal2 = 0x2;
+ kMaskVal3 = 0x4;
+ kMaskVal4 = 0x4000;
+ }
+
+ bitmap Bitmap32MaskMap : bitmap32 {
+ kMaskVal1 = 0x1;
+ kMaskVal2 = 0x2;
+ kMaskVal3 = 0x4;
+ kMaskVal4 = 0x40000000;
+ }
+
+ bitmap Bitmap64MaskMap : bitmap64 {
+ kMaskVal1 = 0x1;
+ kMaskVal2 = 0x2;
+ kMaskVal3 = 0x4;
+ kMaskVal4 = 0x4000000000000000;
+ }
+
+ bitmap Bitmap8MaskMap : bitmap8 {
+ kMaskVal1 = 0x1;
+ kMaskVal2 = 0x2;
+ kMaskVal3 = 0x4;
+ kMaskVal4 = 0x40;
+ }
+
+ bitmap SimpleBitmap : bitmap8 {
+ kValueA = 0x1;
+ kValueB = 0x2;
+ kValueC = 0x4;
+ }
+
+ struct SimpleStruct {
+ int8u a = 0;
+ boolean b = 1;
+ SimpleEnum c = 2;
+ octet_string d = 3;
+ char_string e = 4;
+ SimpleBitmap f = 5;
+ single g = 6;
+ double h = 7;
+ }
+
+ fabric_scoped struct TestFabricScoped {
+ fabric_sensitive int8u fabricSensitiveInt8u = 1;
+ optional fabric_sensitive int8u optionalFabricSensitiveInt8u = 2;
+ nullable fabric_sensitive int8u nullableFabricSensitiveInt8u = 3;
+ optional nullable fabric_sensitive int8u nullableOptionalFabricSensitiveInt8u = 4;
+ fabric_sensitive char_string fabricSensitiveCharString = 5;
+ fabric_sensitive SimpleStruct fabricSensitiveStruct = 6;
+ fabric_sensitive int8u fabricSensitiveInt8uList[] = 7;
+ fabric_idx fabricIndex = 254;
+ }
+
+ struct NullablesAndOptionalsStruct {
+ nullable int16u nullableInt = 0;
+ optional int16u optionalInt = 1;
+ optional nullable int16u nullableOptionalInt = 2;
+ nullable char_string nullableString = 3;
+ optional char_string optionalString = 4;
+ optional nullable char_string nullableOptionalString = 5;
+ nullable SimpleStruct nullableStruct = 6;
+ optional SimpleStruct optionalStruct = 7;
+ optional nullable SimpleStruct nullableOptionalStruct = 8;
+ nullable SimpleEnum nullableList[] = 9;
+ optional SimpleEnum optionalList[] = 10;
+ optional nullable SimpleEnum nullableOptionalList[] = 11;
+ }
+
+ struct NestedStruct {
+ int8u a = 0;
+ boolean b = 1;
+ SimpleStruct c = 2;
+ }
+
+ struct NestedStructList {
+ int8u a = 0;
+ boolean b = 1;
+ SimpleStruct c = 2;
+ SimpleStruct d[] = 3;
+ int32u e[] = 4;
+ octet_string f[] = 5;
+ int8u g[] = 6;
+ }
+
+ struct DoubleNestedStructList {
+ NestedStructList a[] = 0;
+ }
+
+ struct TestListStructOctet {
+ int64u member1 = 0;
+ octet_string<32> member2 = 1;
+ }
+
+ info event TestEvent = 1 {
+ int8u arg1 = 1;
+ SimpleEnum arg2 = 2;
+ boolean arg3 = 3;
+ SimpleStruct arg4 = 4;
+ SimpleStruct arg5[] = 5;
+ SimpleEnum arg6[] = 6;
+ }
+
+ fabric_sensitive info event TestFabricScopedEvent = 2 {
+ fabric_idx fabricIndex = 254;
+ }
+
+ info event TestDifferentVendorMeiEvent = 4294050030 {
+ int8u arg1 = 1;
+ }
+
+ attribute boolean boolean = 0;
+ attribute Bitmap8MaskMap bitmap8 = 1;
+ attribute Bitmap16MaskMap bitmap16 = 2;
+ attribute Bitmap32MaskMap bitmap32 = 3;
+ attribute Bitmap64MaskMap bitmap64 = 4;
+ attribute int8u int8u = 5;
+ attribute int16u int16u = 6;
+ attribute int24u int24u = 7;
+ attribute int32u int32u = 8;
+ attribute int40u int40u = 9;
+ attribute int48u int48u = 10;
+ attribute int56u int56u = 11;
+ attribute int64u int64u = 12;
+ attribute int8s int8s = 13;
+ attribute int16s int16s = 14;
+ attribute int24s int24s = 15;
+ attribute int32s int32s = 16;
+ attribute int40s int40s = 17;
+ attribute int48s int48s = 18;
+ attribute int56s int56s = 19;
+ attribute int64s int64s = 20;
+ attribute enum8 enum8 = 21;
+ attribute enum16 enum16 = 22;
+ attribute single floatSingle = 23;
+ attribute double floatDouble = 24;
+ attribute octet_string<10> octetString = 25;
+ attribute int8u listInt8u[] = 26;
+ attribute octet_string listOctetString[] = 27;
+ attribute TestListStructOctet listStructOctetString[] = 28;
+ attribute long_octet_string<1000> longOctetString = 29;
+ attribute char_string<10> charString = 30;
+ attribute long_char_string<1000> longCharString = 31;
+ attribute epoch_us epochUs = 32;
+ attribute epoch_s epochS = 33;
+ attribute vendor_id vendorId = 34;
+ attribute NullablesAndOptionalsStruct listNullablesAndOptionalsStruct[] = 35;
+ attribute SimpleEnum enumAttr = 36;
+ attribute SimpleStruct structAttr = 37;
+ attribute int8u rangeRestrictedInt8u = 38;
+ attribute int8s rangeRestrictedInt8s = 39;
+ attribute int16u rangeRestrictedInt16u = 40;
+ attribute int16s rangeRestrictedInt16s = 41;
+ attribute long_octet_string listLongOctetString[] = 42;
+ attribute TestFabricScoped listFabricScoped[] = 43;
+ timedwrite attribute boolean timedWriteBoolean = 48;
+ attribute boolean generalErrorBoolean = 49;
+ attribute boolean clusterErrorBoolean = 50;
+ attribute optional boolean unsupported = 255;
+ attribute nullable boolean nullableBoolean = 16384;
+ attribute nullable Bitmap8MaskMap nullableBitmap8 = 16385;
+ attribute nullable Bitmap16MaskMap nullableBitmap16 = 16386;
+ attribute nullable Bitmap32MaskMap nullableBitmap32 = 16387;
+ attribute nullable Bitmap64MaskMap nullableBitmap64 = 16388;
+ attribute nullable int8u nullableInt8u = 16389;
+ attribute nullable int16u nullableInt16u = 16390;
+ attribute nullable int24u nullableInt24u = 16391;
+ attribute nullable int32u nullableInt32u = 16392;
+ attribute nullable int40u nullableInt40u = 16393;
+ attribute nullable int48u nullableInt48u = 16394;
+ attribute nullable int56u nullableInt56u = 16395;
+ attribute nullable int64u nullableInt64u = 16396;
+ attribute nullable int8s nullableInt8s = 16397;
+ attribute nullable int16s nullableInt16s = 16398;
+ attribute nullable int24s nullableInt24s = 16399;
+ attribute nullable int32s nullableInt32s = 16400;
+ attribute nullable int40s nullableInt40s = 16401;
+ attribute nullable int48s nullableInt48s = 16402;
+ attribute nullable int56s nullableInt56s = 16403;
+ attribute nullable int64s nullableInt64s = 16404;
+ attribute nullable enum8 nullableEnum8 = 16405;
+ attribute nullable enum16 nullableEnum16 = 16406;
+ attribute nullable single nullableFloatSingle = 16407;
+ attribute nullable double nullableFloatDouble = 16408;
+ attribute nullable octet_string<10> nullableOctetString = 16409;
+ attribute nullable char_string<10> nullableCharString = 16414;
+ attribute nullable SimpleEnum nullableEnumAttr = 16420;
+ attribute nullable SimpleStruct nullableStruct = 16421;
+ attribute nullable int8u nullableRangeRestrictedInt8u = 16422;
+ attribute nullable int8s nullableRangeRestrictedInt8s = 16423;
+ attribute nullable int16u nullableRangeRestrictedInt16u = 16424;
+ attribute nullable int16s nullableRangeRestrictedInt16s = 16425;
+ attribute optional int8u writeOnlyInt8u = 16426;
+ attribute int8u meiInt8u = 4294070017;
+ readonly attribute command_id generatedCommandList[] = 65528;
+ readonly attribute command_id acceptedCommandList[] = 65529;
+ readonly attribute event_id eventList[] = 65530;
+ readonly attribute attrib_id attributeList[] = 65531;
+ readonly attribute bitmap32 featureMap = 65532;
+ readonly attribute int16u clusterRevision = 65533;
+
+ response struct TestSpecificResponse = 0 {
+ int8u returnValue = 0;
+ }
+
+ response struct TestAddArgumentsResponse = 1 {
+ int8u returnValue = 0;
+ }
+
+ response struct TestSimpleArgumentResponse = 2 {
+ boolean returnValue = 0;
+ }
+
+ response struct TestStructArrayArgumentResponse = 3 {
+ NestedStructList arg1[] = 0;
+ SimpleStruct arg2[] = 1;
+ SimpleEnum arg3[] = 2;
+ boolean arg4[] = 3;
+ SimpleEnum arg5 = 4;
+ boolean arg6 = 5;
+ }
+
+ request struct TestAddArgumentsRequest {
+ int8u arg1 = 0;
+ int8u arg2 = 1;
+ }
+
+ response struct TestListInt8UReverseResponse = 4 {
+ int8u arg1[] = 0;
+ }
+
+ request struct TestSimpleArgumentRequestRequest {
+ boolean arg1 = 0;
+ }
+
+ response struct TestEnumsResponse = 5 {
+ vendor_id arg1 = 0;
+ SimpleEnum arg2 = 1;
+ }
+
+ request struct TestStructArrayArgumentRequestRequest {
+ NestedStructList arg1[] = 0;
+ SimpleStruct arg2[] = 1;
+ SimpleEnum arg3[] = 2;
+ boolean arg4[] = 3;
+ SimpleEnum arg5 = 4;
+ boolean arg6 = 5;
+ }
+
+ response struct TestNullableOptionalResponse = 6 {
+ boolean wasPresent = 0;
+ optional boolean wasNull = 1;
+ optional int8u value = 2;
+ optional nullable int8u originalValue = 3;
+ }
+
+ request struct TestStructArgumentRequestRequest {
+ SimpleStruct arg1 = 0;
+ }
+
+ response struct TestComplexNullableOptionalResponse = 7 {
+ boolean nullableIntWasNull = 0;
+ optional int16u nullableIntValue = 1;
+ boolean optionalIntWasPresent = 2;
+ optional int16u optionalIntValue = 3;
+ boolean nullableOptionalIntWasPresent = 4;
+ optional boolean nullableOptionalIntWasNull = 5;
+ optional int16u nullableOptionalIntValue = 6;
+ boolean nullableStringWasNull = 7;
+ optional char_string nullableStringValue = 8;
+ boolean optionalStringWasPresent = 9;
+ optional char_string optionalStringValue = 10;
+ boolean nullableOptionalStringWasPresent = 11;
+ optional boolean nullableOptionalStringWasNull = 12;
+ optional char_string nullableOptionalStringValue = 13;
+ boolean nullableStructWasNull = 14;
+ optional SimpleStruct nullableStructValue = 15;
+ boolean optionalStructWasPresent = 16;
+ optional SimpleStruct optionalStructValue = 17;
+ boolean nullableOptionalStructWasPresent = 18;
+ optional boolean nullableOptionalStructWasNull = 19;
+ optional SimpleStruct nullableOptionalStructValue = 20;
+ boolean nullableListWasNull = 21;
+ optional SimpleEnum nullableListValue[] = 22;
+ boolean optionalListWasPresent = 23;
+ optional SimpleEnum optionalListValue[] = 24;
+ boolean nullableOptionalListWasPresent = 25;
+ optional boolean nullableOptionalListWasNull = 26;
+ optional SimpleEnum nullableOptionalListValue[] = 27;
+ }
+
+ request struct TestNestedStructArgumentRequestRequest {
+ NestedStruct arg1 = 0;
+ }
+
+ response struct BooleanResponse = 8 {
+ boolean value = 0;
+ }
+
+ request struct TestListStructArgumentRequestRequest {
+ SimpleStruct arg1[] = 0;
+ }
+
+ response struct SimpleStructResponse = 9 {
+ SimpleStruct arg1 = 0;
+ }
+
+ request struct TestListInt8UArgumentRequestRequest {
+ int8u arg1[] = 0;
+ }
+
+ response struct TestEmitTestEventResponse = 10 {
+ int64u value = 0;
+ }
+
+ request struct TestNestedStructListArgumentRequestRequest {
+ NestedStructList arg1 = 0;
+ }
+
+ response struct TestEmitTestFabricScopedEventResponse = 11 {
+ int64u value = 0;
+ }
+
+ request struct TestListNestedStructListArgumentRequestRequest {
+ NestedStructList arg1[] = 0;
+ }
+
+ response struct TestBatchHelperResponse = 12 {
+ octet_string<800> buffer = 0;
+ }
+
+ request struct TestListInt8UReverseRequestRequest {
+ int8u arg1[] = 0;
+ }
+
+ request struct TestEnumsRequestRequest {
+ vendor_id arg1 = 0;
+ SimpleEnum arg2 = 1;
+ }
+
+ request struct TestNullableOptionalRequestRequest {
+ optional nullable int8u arg1 = 0;
+ }
+
+ request struct TestComplexNullableOptionalRequestRequest {
+ nullable int16u nullableInt = 0;
+ optional int16u optionalInt = 1;
+ optional nullable int16u nullableOptionalInt = 2;
+ nullable char_string nullableString = 3;
+ optional char_string optionalString = 4;
+ optional nullable char_string nullableOptionalString = 5;
+ nullable SimpleStruct nullableStruct = 6;
+ optional SimpleStruct optionalStruct = 7;
+ optional nullable SimpleStruct nullableOptionalStruct = 8;
+ nullable SimpleEnum nullableList[] = 9;
+ optional SimpleEnum optionalList[] = 10;
+ optional nullable SimpleEnum nullableOptionalList[] = 11;
+ }
+
+ request struct SimpleStructEchoRequestRequest {
+ SimpleStruct arg1 = 0;
+ }
+
+ request struct TestSimpleOptionalArgumentRequestRequest {
+ optional boolean arg1 = 0;
+ }
+
+ request struct TestEmitTestEventRequestRequest {
+ int8u arg1 = 0;
+ SimpleEnum arg2 = 1;
+ boolean arg3 = 2;
+ }
+
+ request struct TestEmitTestFabricScopedEventRequestRequest {
+ int8u arg1 = 0;
+ }
+
+ request struct TestBatchHelperRequestRequest {
+ int16u sleepBeforeResponseTimeMs = 0;
+ int16u sizeOfResponseBuffer = 1;
+ int8u fillCharacter = 2;
+ }
+
+ request struct TestSecondBatchHelperRequestRequest {
+ int16u sleepBeforeResponseTimeMs = 0;
+ int16u sizeOfResponseBuffer = 1;
+ int8u fillCharacter = 2;
+ }
+
+ request struct TestDifferentVendorMeiRequestRequest {
+ int8u arg1 = 0;
+ }
+
+ response struct TestDifferentVendorMeiResponse = 4294049979 {
+ int8u arg1 = 0;
+ int64u eventNumber = 1;
+ }
+
+ /** Simple command without any parameters and without a specific response.
+ To aid in unit testing, this command will re-initialize attribute storage to defaults. */
+ command Test(): DefaultSuccess = 0;
+ /** Simple command without any parameters and without a specific response not handled by the server */
+ command TestNotHandled(): DefaultSuccess = 1;
+ /** Simple command without any parameters and with a specific response */
+ command TestSpecific(): TestSpecificResponse = 2;
+ /** Simple command that should not be added to the server. */
+ command TestUnknownCommand(): DefaultSuccess = 3;
+ /** Command that takes two arguments and returns their sum. */
+ command TestAddArguments(TestAddArgumentsRequest): TestAddArgumentsResponse = 4;
+ /** Command that takes an argument which is bool */
+ command TestSimpleArgumentRequest(TestSimpleArgumentRequestRequest): TestSimpleArgumentResponse = 5;
+ /** Command that takes various arguments that are arrays, including an array of structs which have a list member. */
+ command TestStructArrayArgumentRequest(TestStructArrayArgumentRequestRequest): TestStructArrayArgumentResponse = 6;
+ /** Command that takes an argument which is struct. The response echoes the
+ 'b' field of the single arg. */
+ command TestStructArgumentRequest(TestStructArgumentRequestRequest): BooleanResponse = 7;
+ /** Command that takes an argument which is nested struct. The response
+ echoes the 'b' field of ar1.c. */
+ command TestNestedStructArgumentRequest(TestNestedStructArgumentRequestRequest): BooleanResponse = 8;
+ /** Command that takes an argument which is a list of structs. The response
+ returns false if there is some struct in the list whose 'b' field is
+ false, and true otherwise (including if the list is empty). */
+ command TestListStructArgumentRequest(TestListStructArgumentRequestRequest): BooleanResponse = 9;
+ /** Command that takes an argument which is a list of INT8U. The response
+ returns false if the list contains a 0 in it, true otherwise (including
+ if the list is empty). */
+ command TestListInt8UArgumentRequest(TestListInt8UArgumentRequestRequest): BooleanResponse = 10;
+ /** Command that takes an argument which is a Nested Struct List. The
+ response returns false if there is some struct in arg1 (either directly
+ in arg1.c or in the arg1.d list) whose 'b' field is false, and true
+ otherwise. */
+ command TestNestedStructListArgumentRequest(TestNestedStructListArgumentRequestRequest): BooleanResponse = 11;
+ /** Command that takes an argument which is a list of Nested Struct List.
+ The response returns false if there is some struct in arg1 (either
+ directly in as the 'c' field of an entry 'd' list of an entry) whose 'b'
+ field is false, and true otherwise (including if the list is empty). */
+ command TestListNestedStructListArgumentRequest(TestListNestedStructListArgumentRequestRequest): BooleanResponse = 12;
+ /** Command that takes an argument which is a list of INT8U and expects a
+ response that reverses the list. */
+ command TestListInt8UReverseRequest(TestListInt8UReverseRequestRequest): TestListInt8UReverseResponse = 13;
+ /** Command that sends a vendor id and an enum. The server is expected to
+ echo them back. */
+ command TestEnumsRequest(TestEnumsRequestRequest): TestEnumsResponse = 14;
+ /** Command that takes an argument which is nullable and optional. The
+ response returns a boolean indicating whether the argument was present,
+ if that's true a boolean indicating whether the argument was null, and
+ if that' false the argument it received. */
+ command TestNullableOptionalRequest(TestNullableOptionalRequestRequest): TestNullableOptionalResponse = 15;
+ /** Command that takes various arguments which can be nullable and/or optional. The
+ response returns information about which things were received and what
+ their state was. */
+ command TestComplexNullableOptionalRequest(TestComplexNullableOptionalRequestRequest): TestComplexNullableOptionalResponse = 16;
+ /** Command that takes an argument which is a struct. The response echoes
+ the struct back. */
+ command SimpleStructEchoRequest(SimpleStructEchoRequestRequest): SimpleStructResponse = 17;
+ /** Command that just responds with a success status if the timed invoke
+ conditions are met. */
+ timed command TimedInvokeRequest(): DefaultSuccess = 18;
+ /** Command that takes an optional argument which is bool. It responds with a success value if the optional is set to any value. */
+ command TestSimpleOptionalArgumentRequest(TestSimpleOptionalArgumentRequestRequest): DefaultSuccess = 19;
+ /** Command that takes identical arguments to the fields of the TestEvent and logs the TestEvent to the buffer. Command returns an event ID as the response. */
+ command TestEmitTestEventRequest(TestEmitTestEventRequestRequest): TestEmitTestEventResponse = 20;
+ /** Command that takes identical arguments to the fields of the TestFabricScopedEvent and logs the TestFabricScopedEvent to the buffer. Command returns an event ID as the response. */
+ command TestEmitTestFabricScopedEventRequest(TestEmitTestFabricScopedEventRequestRequest): TestEmitTestFabricScopedEventResponse = 21;
+ /** Command that responds after sleepBeforeResponseTimeMs with an octet_string the size requested with fillCharacter. */
+ command TestBatchHelperRequest(TestBatchHelperRequestRequest): TestBatchHelperResponse = 22;
+ /** Second command that responds after sleepBeforeResponseTimeMs with an octet_string the size requested with fillCharacter. */
+ command TestSecondBatchHelperRequest(TestSecondBatchHelperRequestRequest): TestBatchHelperResponse = 23;
+ /** Command having a different MEI vendor ID than the cluster. Also emits TestDifferentVendorMeiEvent. */
+ command TestDifferentVendorMeiRequest(TestDifferentVendorMeiRequestRequest): TestDifferentVendorMeiResponse = 4294049962;
+}
+
endpoint 0 {
device type ma_rootdevice = 22, version 1;
@@ -1661,6 +2146,127 @@ endpoint 1 {
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;
}
+
+ server cluster UnitTesting {
+ emits event TestEvent;
+ emits event TestFabricScopedEvent;
+ emits event TestDifferentVendorMeiEvent;
+ ram attribute boolean default = false;
+ ram attribute bitmap8 default = 0;
+ ram attribute bitmap16 default = 0;
+ ram attribute bitmap32 default = 0;
+ ram attribute bitmap64 default = 0;
+ ram attribute int8u default = 0;
+ ram attribute int16u default = 0;
+ ram attribute int24u default = 0;
+ ram attribute int32u default = 0;
+ ram attribute int40u default = 0;
+ ram attribute int48u default = 0;
+ ram attribute int56u default = 0;
+ ram attribute int64u default = 0;
+ ram attribute int8s default = 0;
+ ram attribute int16s default = 0;
+ ram attribute int24s default = 0;
+ ram attribute int32s default = 0;
+ ram attribute int40s default = 0;
+ ram attribute int48s default = 0;
+ ram attribute int56s default = 0;
+ ram attribute int64s default = 0;
+ ram attribute enum8 default = 0;
+ ram attribute enum16 default = 0;
+ ram attribute floatSingle default = 0;
+ ram attribute floatDouble default = 0;
+ ram attribute octetString;
+ callback attribute listInt8u;
+ callback attribute listOctetString;
+ callback attribute listStructOctetString;
+ ram attribute longOctetString;
+ ram attribute charString;
+ ram attribute longCharString;
+ ram attribute epochUs;
+ ram attribute epochS;
+ ram attribute vendorId;
+ callback attribute listNullablesAndOptionalsStruct;
+ ram attribute enumAttr;
+ callback attribute structAttr;
+ ram attribute rangeRestrictedInt8u default = 70;
+ ram attribute rangeRestrictedInt8s default = -20;
+ ram attribute rangeRestrictedInt16u default = 200;
+ ram attribute rangeRestrictedInt16s default = -100;
+ callback attribute listLongOctetString;
+ callback attribute listFabricScoped;
+ ram attribute timedWriteBoolean;
+ callback attribute generalErrorBoolean;
+ callback attribute clusterErrorBoolean;
+ ram attribute nullableBoolean default = false;
+ ram attribute nullableBitmap8 default = 0;
+ ram attribute nullableBitmap16 default = 0;
+ ram attribute nullableBitmap32 default = 0;
+ ram attribute nullableBitmap64 default = 0;
+ ram attribute nullableInt8u default = 0;
+ ram attribute nullableInt16u default = 0;
+ ram attribute nullableInt24u default = 0;
+ ram attribute nullableInt32u default = 0;
+ ram attribute nullableInt40u default = 0;
+ ram attribute nullableInt48u default = 0;
+ ram attribute nullableInt56u default = 0;
+ ram attribute nullableInt64u default = 0;
+ ram attribute nullableInt8s default = 0;
+ ram attribute nullableInt16s default = 0;
+ ram attribute nullableInt24s default = 0;
+ ram attribute nullableInt32s default = 0;
+ ram attribute nullableInt40s default = 0;
+ ram attribute nullableInt48s default = 0;
+ ram attribute nullableInt56s default = 0;
+ ram attribute nullableInt64s default = 0;
+ ram attribute nullableEnum8 default = 0;
+ ram attribute nullableEnum16 default = 0;
+ ram attribute nullableFloatSingle default = 0;
+ ram attribute nullableFloatDouble default = 0;
+ ram attribute nullableOctetString;
+ ram attribute nullableCharString;
+ ram attribute nullableEnumAttr;
+ callback attribute nullableStruct;
+ ram attribute nullableRangeRestrictedInt8u default = 70;
+ ram attribute nullableRangeRestrictedInt8s default = -20;
+ ram attribute nullableRangeRestrictedInt16u default = 200;
+ ram attribute nullableRangeRestrictedInt16s default = -100;
+ callback attribute writeOnlyInt8u default = 0;
+ ram attribute featureMap default = 0;
+ ram attribute clusterRevision default = 1;
+ ram attribute meiInt8u default = 0;
+
+ handle command Test;
+ handle command TestSpecificResponse;
+ handle command TestNotHandled;
+ handle command TestAddArgumentsResponse;
+ handle command TestSpecific;
+ handle command TestAddArguments;
+ handle command TestListInt8UReverseResponse;
+ handle command TestEnumsResponse;
+ handle command TestNullableOptionalResponse;
+ handle command TestStructArgumentRequest;
+ handle command TestNestedStructArgumentRequest;
+ handle command TestListStructArgumentRequest;
+ handle command SimpleStructResponse;
+ handle command TestListInt8UArgumentRequest;
+ handle command TestEmitTestEventResponse;
+ handle command TestNestedStructListArgumentRequest;
+ handle command TestEmitTestFabricScopedEventResponse;
+ handle command TestListNestedStructListArgumentRequest;
+ handle command TestListInt8UReverseRequest;
+ handle command TestEnumsRequest;
+ handle command TestNullableOptionalRequest;
+ handle command SimpleStructEchoRequest;
+ handle command TimedInvokeRequest;
+ handle command TestSimpleOptionalArgumentRequest;
+ handle command TestEmitTestEventRequest;
+ handle command TestEmitTestFabricScopedEventRequest;
+ handle command TestBatchHelperRequest;
+ handle command TestSecondBatchHelperRequest;
+ handle command TestDifferentVendorMeiRequest;
+ handle command TestDifferentVendorMeiResponse;
+ }
}
diff --git a/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.zap b/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.zap
index cbbcbea13c6d81..b50f9ae5b24dfd 100644
--- a/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.zap
+++ b/examples/chef/devices/rootnode_contactsensor_27f76aeaf5.zap
@@ -2889,6 +2889,1626 @@
"reportableChange": 0
}
]
+ },
+ {
+ "name": "Unit Testing",
+ "code": 4294048773,
+ "mfgCode": null,
+ "define": "UNIT_TESTING_CLUSTER",
+ "side": "server",
+ "enabled": 1,
+ "apiMaturity": "internal",
+ "commands": [
+ {
+ "name": "Test",
+ "code": 0,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestSpecificResponse",
+ "code": 0,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestNotHandled",
+ "code": 1,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestAddArgumentsResponse",
+ "code": 1,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestSpecific",
+ "code": 2,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestAddArguments",
+ "code": 4,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestListInt8UReverseResponse",
+ "code": 4,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEnumsResponse",
+ "code": 5,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestNullableOptionalResponse",
+ "code": 6,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestStructArgumentRequest",
+ "code": 7,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestNestedStructArgumentRequest",
+ "code": 8,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestListStructArgumentRequest",
+ "code": 9,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "SimpleStructResponse",
+ "code": 9,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestListInt8UArgumentRequest",
+ "code": 10,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEmitTestEventResponse",
+ "code": 10,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestNestedStructListArgumentRequest",
+ "code": 11,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEmitTestFabricScopedEventResponse",
+ "code": 11,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestListNestedStructListArgumentRequest",
+ "code": 12,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestListInt8UReverseRequest",
+ "code": 13,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEnumsRequest",
+ "code": 14,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestNullableOptionalRequest",
+ "code": 15,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "SimpleStructEchoRequest",
+ "code": 17,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TimedInvokeRequest",
+ "code": 18,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestSimpleOptionalArgumentRequest",
+ "code": 19,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEmitTestEventRequest",
+ "code": 20,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestEmitTestFabricScopedEventRequest",
+ "code": 21,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestBatchHelperRequest",
+ "code": 22,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestSecondBatchHelperRequest",
+ "code": 23,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestDifferentVendorMeiRequest",
+ "code": 4294049962,
+ "mfgCode": null,
+ "source": "client",
+ "isIncoming": 1,
+ "isEnabled": 1
+ },
+ {
+ "name": "TestDifferentVendorMeiResponse",
+ "code": 4294049979,
+ "mfgCode": null,
+ "source": "server",
+ "isIncoming": 0,
+ "isEnabled": 1
+ }
+ ],
+ "attributes": [
+ {
+ "name": "boolean",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "false",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "bitmap8",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap8MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "bitmap16",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap16MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "bitmap32",
+ "code": 3,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap32MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "bitmap64",
+ "code": 4,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap64MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int8u",
+ "code": 5,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int16u",
+ "code": 6,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int24u",
+ "code": 7,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int32u",
+ "code": 8,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int32u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int40u",
+ "code": 9,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int40u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int48u",
+ "code": 10,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int48u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int56u",
+ "code": 11,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int56u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int64u",
+ "code": 12,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int8s",
+ "code": 13,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int16s",
+ "code": 14,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int24s",
+ "code": 15,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int32s",
+ "code": 16,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int32s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "int40s",
+ "code": 17,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int40s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int48s",
+ "code": 18,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int48s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int56s",
+ "code": 19,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int56s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "int64s",
+ "code": 20,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "enum8",
+ "code": 21,
+ "mfgCode": null,
+ "side": "server",
+ "type": "enum8",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "enum16",
+ "code": 22,
+ "mfgCode": null,
+ "side": "server",
+ "type": "enum16",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "float_single",
+ "code": 23,
+ "mfgCode": null,
+ "side": "server",
+ "type": "single",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "float_double",
+ "code": 24,
+ "mfgCode": null,
+ "side": "server",
+ "type": "double",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "octet_string",
+ "code": 25,
+ "mfgCode": null,
+ "side": "server",
+ "type": "octet_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_int8u",
+ "code": 26,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_octet_string",
+ "code": 27,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_struct_octet_string",
+ "code": 28,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "long_octet_string",
+ "code": 29,
+ "mfgCode": null,
+ "side": "server",
+ "type": "long_octet_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "char_string",
+ "code": 30,
+ "mfgCode": null,
+ "side": "server",
+ "type": "char_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "long_char_string",
+ "code": 31,
+ "mfgCode": null,
+ "side": "server",
+ "type": "long_char_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "epoch_us",
+ "code": 32,
+ "mfgCode": null,
+ "side": "server",
+ "type": "epoch_us",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "epoch_s",
+ "code": 33,
+ "mfgCode": null,
+ "side": "server",
+ "type": "epoch_s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "vendor_id",
+ "code": 34,
+ "mfgCode": null,
+ "side": "server",
+ "type": "vendor_id",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_nullables_and_optionals_struct",
+ "code": 35,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "enum_attr",
+ "code": 36,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SimpleEnum",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "struct_attr",
+ "code": 37,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SimpleStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "range_restricted_int8u",
+ "code": 38,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "70",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "range_restricted_int8s",
+ "code": 39,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "-20",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "range_restricted_int16u",
+ "code": 40,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "200",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "range_restricted_int16s",
+ "code": 41,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "-100",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_long_octet_string",
+ "code": 42,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "list_fabric_scoped",
+ "code": 43,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "timed_write_boolean",
+ "code": 48,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "general_error_boolean",
+ "code": 49,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "cluster_error_boolean",
+ "code": 50,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_boolean",
+ "code": 16384,
+ "mfgCode": null,
+ "side": "server",
+ "type": "boolean",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "false",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_bitmap8",
+ "code": 16385,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap8MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_bitmap16",
+ "code": 16386,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap16MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_bitmap32",
+ "code": 16387,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap32MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_bitmap64",
+ "code": 16388,
+ "mfgCode": null,
+ "side": "server",
+ "type": "Bitmap64MaskMap",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int8u",
+ "code": 16389,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int16u",
+ "code": 16390,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int24u",
+ "code": 16391,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int32u",
+ "code": 16392,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int32u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int40u",
+ "code": 16393,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int40u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int48u",
+ "code": 16394,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int48u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int56u",
+ "code": 16395,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int56u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int64u",
+ "code": 16396,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int8s",
+ "code": 16397,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int16s",
+ "code": 16398,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int24s",
+ "code": 16399,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int32s",
+ "code": 16400,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int32s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int40s",
+ "code": 16401,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int40s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int48s",
+ "code": 16402,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int48s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int56s",
+ "code": 16403,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int56s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_int64s",
+ "code": 16404,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int64s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_enum8",
+ "code": 16405,
+ "mfgCode": null,
+ "side": "server",
+ "type": "enum8",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_enum16",
+ "code": 16406,
+ "mfgCode": null,
+ "side": "server",
+ "type": "enum16",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_float_single",
+ "code": 16407,
+ "mfgCode": null,
+ "side": "server",
+ "type": "single",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_float_double",
+ "code": 16408,
+ "mfgCode": null,
+ "side": "server",
+ "type": "double",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_octet_string",
+ "code": 16409,
+ "mfgCode": null,
+ "side": "server",
+ "type": "octet_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_char_string",
+ "code": 16414,
+ "mfgCode": null,
+ "side": "server",
+ "type": "char_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_enum_attr",
+ "code": 16420,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SimpleEnum",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_struct",
+ "code": 16421,
+ "mfgCode": null,
+ "side": "server",
+ "type": "SimpleStruct",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": null,
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_range_restricted_int8u",
+ "code": 16422,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "70",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_range_restricted_int8s",
+ "code": 16423,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "-20",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_range_restricted_int16u",
+ "code": 16424,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "200",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "nullable_range_restricted_int16s",
+ "code": 16425,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16s",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "-100",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "write_only_int8u",
+ "code": 16426,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "FeatureMap",
+ "code": 65532,
+ "mfgCode": null,
+ "side": "server",
+ "type": "bitmap32",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ClusterRevision",
+ "code": 65533,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "1",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ },
+ {
+ "name": "mei_int8u",
+ "code": 4294070017,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 0,
+ "maxInterval": 65344,
+ "reportableChange": 0
+ }
+ ],
+ "events": [
+ {
+ "name": "TestEvent",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "TestFabricScopedEvent",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ },
+ {
+ "name": "TestDifferentVendorMeiEvent",
+ "code": 4294050030,
+ "mfgCode": null,
+ "side": "server",
+ "included": 1
+ }
+ ]
}
]
}
diff --git a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
index 58e7d6e04bb19d..dc190ad05ecd31 100644
--- a/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
+++ b/examples/chef/devices/rootnode_roboticvacuumcleaner_1807ff0c49.matter
@@ -1020,7 +1020,7 @@ cluster RvcRunMode = 84 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -1036,7 +1036,6 @@ cluster RvcRunMode = 84 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1073,7 +1072,7 @@ cluster RvcCleanMode = 85 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -1089,7 +1088,6 @@ cluster RvcCleanMode = 85 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1172,10 +1170,6 @@ cluster RvcOperationalState = 97 {
/** Upon receipt, the device SHALL pause its operation if it is possible based on the current function of the server. */
command Pause(): OperationalCommandResponse = 0;
- /** Upon receipt, the device SHALL stop its operation if it is at a position where it is safe to do so and/or permitted. */
- command Stop(): OperationalCommandResponse = 1;
- /** Upon receipt, the device SHALL start its operation if it is safe to do so and the device is in an operational state from which it can be started. */
- command Start(): OperationalCommandResponse = 2;
/** Upon receipt, the device SHALL resume its operation from the point it was at when it received the Pause command, or from the point when it was paused by means outside of this cluster (for example by manual button press). */
command Resume(): OperationalCommandResponse = 3;
/** On receipt of this command, the device SHALL start seeking the charging dock, if possible in the current state of the device. */
@@ -1410,7 +1404,6 @@ endpoint 1 {
server cluster RvcRunMode {
callback attribute supportedModes;
callback attribute currentMode;
- callback attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
@@ -1425,7 +1418,6 @@ endpoint 1 {
server cluster RvcCleanMode {
callback attribute supportedModes;
callback attribute currentMode;
- callback attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
@@ -1454,8 +1446,6 @@ endpoint 1 {
ram attribute clusterRevision default = 1;
handle command Pause;
- handle command Stop;
- handle command Start;
handle command Resume;
handle command OperationalCommandResponse;
}
diff --git a/examples/chef/esp32/main/CMakeLists.txt b/examples/chef/esp32/main/CMakeLists.txt
index 6c342d07b4fa15..e6ab518f3494a9 100644
--- a/examples/chef/esp32/main/CMakeLists.txt
+++ b/examples/chef/esp32/main/CMakeLists.txt
@@ -141,6 +141,17 @@ pw_proto_library(attributes_service
pw_protobuf.common_proto
)
+pw_proto_library(boolean_state_service
+ SOURCES
+ ${CHIP_ROOT}/examples/common/pigweed/protos/boolean_state_service.proto
+ PREFIX
+ boolean_state_service
+ STRIP_PREFIX
+ ${CHIP_ROOT}/examples/common/pigweed/protos
+ DEPS
+ pw_protobuf.common_proto
+)
+
pw_proto_library(button_service
SOURCES
${CHIP_ROOT}/examples/common/pigweed/protos/button_service.proto
@@ -191,6 +202,7 @@ pw_proto_library(wifi_service
target_link_libraries(${COMPONENT_LIB} PUBLIC
attributes_service.nanopb_rpc
+ boolean_state_service.nanopb_rpc
button_service.nanopb_rpc
descriptor_service.nanopb_rpc
device_service.nanopb_rpc
@@ -215,6 +227,7 @@ target_link_options(${COMPONENT_LIB}
target_compile_options(${COMPONENT_LIB} PRIVATE
"-DPW_RPC_ATTRIBUTE_SERVICE=1"
+ "-DPW_RPC_BOOLEAN_STATE_SERVICE=1"
"-DPW_RPC_BUTTON_SERVICE=1"
"-DPW_RPC_DEVICE_SERVICE=1"
"-DPW_RPC_DESCRIPTOR_SERVICE=1"
diff --git a/examples/chef/linux/BUILD.gn b/examples/chef/linux/BUILD.gn
index fa12a79a91a09f..a25c1f5ffa11ce 100644
--- a/examples/chef/linux/BUILD.gn
+++ b/examples/chef/linux/BUILD.gn
@@ -69,6 +69,7 @@ executable("${sample_name}") {
defines = [
"PW_RPC_ENABLED",
"PW_RPC_ATTRIBUTE_SERVICE=1",
+ "PW_RPC_BOOLEAN_STATE_SERVICE=1",
"PW_RPC_BUTTON_SERVICE=1",
"PW_RPC_DESCRIPTOR_SERVICE=1",
"PW_RPC_DEVICE_SERVICE=1",
@@ -95,6 +96,7 @@ executable("${sample_name}") {
"$dir_pw_trace_tokenized:trace_rpc_service",
"${chip_root}/config/linux/lib/pw_rpc:pw_rpc",
"${chip_root}/examples/common/pigweed:attributes_service.nanopb_rpc",
+ "${chip_root}/examples/common/pigweed:boolean_state_service.nanopb_rpc",
"${chip_root}/examples/common/pigweed:button_service.nanopb_rpc",
"${chip_root}/examples/common/pigweed:descriptor_service.nanopb_rpc",
"${chip_root}/examples/common/pigweed:device_service.nanopb_rpc",
diff --git a/examples/chef/nrfconnect/CMakeLists.txt b/examples/chef/nrfconnect/CMakeLists.txt
index 1d9ab2fb436a62..17556ef398b27a 100644
--- a/examples/chef/nrfconnect/CMakeLists.txt
+++ b/examples/chef/nrfconnect/CMakeLists.txt
@@ -133,6 +133,17 @@ pw_proto_library(attributes_service
pw_protobuf.common_proto
)
+pw_proto_library(boolean_state_service
+ SOURCES
+ ${CHIP_ROOT}/examples/common/pigweed/protos/boolean_state_service.proto
+ PREFIX
+ boolean_state_service
+ STRIP_PREFIX
+ ${CHIP_ROOT}/examples/common/pigweed/protos
+ DEPS
+ pw_protobuf.common_proto
+)
+
pw_proto_library(descriptor_service
SOURCES
${CHIP_ROOT}/examples/common/pigweed/protos/descriptor_service.proto
@@ -202,6 +213,7 @@ target_include_directories(app PRIVATE
target_compile_options(app PRIVATE
"-DPW_RPC_ATTRIBUTE_SERVICE=1"
+ "-DPW_RPC_BOOLEAN_STATE_SERVICE=1"
"-DPW_RPC_DESCRIPTOR_SERVICE=1"
"-DPW_RPC_DEVICE_SERVICE=1"
"-DPW_RPC_THREAD_SERVICE=1"
@@ -209,6 +221,7 @@ target_compile_options(app PRIVATE
target_link_libraries(app PRIVATE
attributes_service.nanopb_rpc
+ boolean_state_service.nanopb_rpc
descriptor_service.nanopb_rpc
device_service.nanopb_rpc
thread_service.nanopb_rpc
diff --git a/examples/chip-tool/BUILD.gn b/examples/chip-tool/BUILD.gn
index c6f5edc819ba95..a27c3cd65716bd 100644
--- a/examples/chip-tool/BUILD.gn
+++ b/examples/chip-tool/BUILD.gn
@@ -110,6 +110,7 @@ static_library("chip-tool-utils") {
"${chip_root}/src/controller/data_model",
"${chip_root}/src/credentials:file_attestation_trust_store",
"${chip_root}/src/lib",
+ "${chip_root}/src/lib/core:types",
"${chip_root}/src/lib/support/jsontlv",
"${chip_root}/src/platform",
"${chip_root}/third_party/inipp",
diff --git a/examples/chip-tool/commands/clusters/ModelCommand.cpp b/examples/chip-tool/commands/clusters/ModelCommand.cpp
index 31fd2e14a15a1f..c908f9fa71b548 100644
--- a/examples/chip-tool/commands/clusters/ModelCommand.cpp
+++ b/examples/chip-tool/commands/clusters/ModelCommand.cpp
@@ -19,6 +19,7 @@
#include "ModelCommand.h"
#include
+#include
#include
using namespace ::chip;
@@ -35,6 +36,7 @@ CHIP_ERROR ModelCommand::RunCommand()
}
ChipLogProgress(chipTool, "Sending command to node 0x%" PRIx64, mDestinationId);
+ CheckPeerICDType();
CommissioneeDeviceProxy * commissioneeDeviceProxy = nullptr;
if (CHIP_NO_ERROR == CurrentCommissioner().GetDeviceBeingCommissioned(mDestinationId, &commissioneeDeviceProxy))
@@ -73,3 +75,31 @@ void ModelCommand::Shutdown()
CHIPCommand::Shutdown();
}
+
+void ModelCommand::CheckPeerICDType()
+{
+ if (mIsPeerLIT.HasValue())
+ {
+ ChipLogProgress(chipTool, "Peer ICD type is set to %s", mIsPeerLIT.Value() == 1 ? "LIT-ICD" : "non LIT-ICD");
+ return;
+ }
+
+ app::ICDClientInfo info;
+ auto destinationPeerId = chip::ScopedNodeId(mDestinationId, CurrentCommissioner().GetFabricIndex());
+ auto iter = CHIPCommand::sICDClientStorage.IterateICDClientInfo();
+ if (iter == nullptr)
+ {
+ return;
+ }
+ app::DefaultICDClientStorage::ICDClientInfoIteratorWrapper clientInfoIteratorWrapper(iter);
+
+ while (iter->Next(info))
+ {
+ if (ScopedNodeId(info.peer_node.GetNodeId(), info.peer_node.GetFabricIndex()) == destinationPeerId)
+ {
+ ChipLogProgress(chipTool, "Peer is a registered LIT ICD.");
+ mIsPeerLIT.SetValue(true);
+ return;
+ }
+ }
+}
diff --git a/examples/chip-tool/commands/clusters/ModelCommand.h b/examples/chip-tool/commands/clusters/ModelCommand.h
index 0b6339ab60f5ed..9561932c9b74e0 100644
--- a/examples/chip-tool/commands/clusters/ModelCommand.h
+++ b/examples/chip-tool/commands/clusters/ModelCommand.h
@@ -52,6 +52,10 @@ class ModelCommand : public CHIPCommand
"Endpoint the command is targeted at.");
}
}
+ AddArgument(
+ "lit-icd-peer", 0, 1, &mIsPeerLIT,
+ "Whether to treat the peer as a LIT ICD. false: Always no, true: Always yes, (not set): Yes if the peer is registered "
+ "to this controller.");
AddArgument("timeout", 0, UINT16_MAX, &mTimeout);
}
@@ -66,11 +70,16 @@ class ModelCommand : public CHIPCommand
void Shutdown() override;
protected:
+ bool IsPeerLIT() { return mIsPeerLIT.ValueOr(false); }
+
chip::Optional mTimeout;
private:
chip::NodeId mDestinationId;
std::vector mEndPointId;
+ chip::Optional mIsPeerLIT;
+
+ void CheckPeerICDType();
static void OnDeviceConnectedFn(void * context, chip::Messaging::ExchangeManager & exchangeMgr,
const chip::SessionHandle & sessionHandle);
diff --git a/examples/chip-tool/commands/clusters/ReportCommand.h b/examples/chip-tool/commands/clusters/ReportCommand.h
index eefd938c2d0717..e2c0f1db785900 100644
--- a/examples/chip-tool/commands/clusters/ReportCommand.h
+++ b/examples/chip-tool/commands/clusters/ReportCommand.h
@@ -277,6 +277,7 @@ class SubscribeAttribute : public SubscribeCommand
CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override
{
+ SubscribeCommand::SetPeerLIT(IsPeerLIT());
return SubscribeCommand::SubscribeAttribute(device, endpointIds, mClusterIds, mAttributeIds);
}
@@ -407,6 +408,7 @@ class SubscribeEvent : public SubscribeCommand
CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override
{
+ SubscribeCommand::SetPeerLIT(IsPeerLIT());
return SubscribeCommand::SubscribeEvent(device, endpointIds, mClusterIds, mEventIds);
}
@@ -538,6 +540,7 @@ class SubscribeAll : public SubscribeCommand
CHIP_ERROR SendCommand(chip::DeviceProxy * device, std::vector endpointIds) override
{
+ SubscribeCommand::SetPeerLIT(IsPeerLIT());
return SubscribeCommand::SubscribeAll(device, endpointIds, mClusterIds, mAttributeIds, mEventIds);
}
diff --git a/examples/chip-tool/commands/icd/ICDCommand.cpp b/examples/chip-tool/commands/icd/ICDCommand.cpp
index 4d8ab7e93452d1..fbfc6a2083a5d5 100644
--- a/examples/chip-tool/commands/icd/ICDCommand.cpp
+++ b/examples/chip-tool/commands/icd/ICDCommand.cpp
@@ -18,6 +18,7 @@
#include "ICDCommand.h"
+#include
#include
#include
@@ -29,6 +30,11 @@ CHIP_ERROR ICDListCommand::RunCommand()
auto iter = CHIPCommand::sICDClientStorage.IterateICDClientInfo();
char icdAesKeyHex[Crypto::kAES_CCM128_Key_Length * 2 + 1];
char icdHmacKeyHex[Crypto::kHMAC_CCM128_Key_Length * 2 + 1];
+ if (iter == nullptr)
+ {
+ return CHIP_ERROR_NO_MEMORY;
+ }
+ app::DefaultICDClientStorage::ICDClientInfoIteratorWrapper clientInfoIteratorWrapper(iter);
fprintf(stderr, " +-----------------------------------------------------------------------------+\n");
fprintf(stderr, " | %-75s |\n", "Known ICDs:");
fprintf(stderr, " +-----------------------------------------------------------------------------+\n");
@@ -54,8 +60,6 @@ CHIP_ERROR ICDListCommand::RunCommand()
}
fprintf(stderr, " +-----------------------------------------------------------------------------+\n");
-
- iter->Release();
SetCommandExitStatus(CHIP_NO_ERROR);
return CHIP_NO_ERROR;
}
diff --git a/examples/common/pigweed/BUILD.gn b/examples/common/pigweed/BUILD.gn
index d190b07fd85082..e056f2ef228a8a 100644
--- a/examples/common/pigweed/BUILD.gn
+++ b/examples/common/pigweed/BUILD.gn
@@ -43,6 +43,13 @@ pw_proto_library("attributes_service") {
prefix = "attributes_service"
}
+pw_proto_library("boolean_state_service") {
+ sources = [ "protos/boolean_state_service.proto" ]
+ deps = [ "$dir_pw_protobuf:common_protos" ]
+ strip_prefix = "protos"
+ prefix = "boolean_state_service"
+}
+
pw_proto_library("device_service") {
sources = [ "protos/device_service.proto" ]
inputs = [ "protos/device_service.options" ]
diff --git a/examples/common/pigweed/protos/boolean_state_service.proto b/examples/common/pigweed/protos/boolean_state_service.proto
new file mode 100644
index 00000000000000..ea15c0174f33b9
--- /dev/null
+++ b/examples/common/pigweed/protos/boolean_state_service.proto
@@ -0,0 +1,37 @@
+syntax = "proto3";
+
+import 'pw_protobuf_protos/common.proto';
+
+package chip.rpc;
+
+// This may eventually contain more attributes.
+message BooleanStateState {
+ bool state_value = 1;
+}
+
+message BooleanStateSetRequest {
+ uint32 endpoint_id = 1;
+ bool state_value = 2;
+}
+
+message BooleanStateSetResponse {
+ uint64 event_number = 1;
+}
+
+message BooleanStateGetRequest {
+ uint32 endpoint_id = 1;
+}
+
+message BooleanStateGetResponse {
+ BooleanStateState state = 1;
+}
+
+service BooleanState {
+ // Set will return generated event number (caused by change) if all supported fields are successfully applied, any
+ // unsupported fields will be ignored.
+ rpc Set(BooleanStateSetRequest) returns (BooleanStateSetResponse){}
+
+ // Get will populate all of the supported boolean state cluster state fields
+ // with the current values.
+ rpc Get(BooleanStateGetRequest) returns (BooleanStateGetResponse){}
+}
diff --git a/examples/common/pigweed/rpc_console/py/BUILD.gn b/examples/common/pigweed/rpc_console/py/BUILD.gn
index 5c74b7b2599544..a050fb64747302 100644
--- a/examples/common/pigweed/rpc_console/py/BUILD.gn
+++ b/examples/common/pigweed/rpc_console/py/BUILD.gn
@@ -40,6 +40,7 @@ pw_python_package("chip_rpc") {
"$dir_pw_system/py",
"$dir_pw_tokenizer/py",
"${chip_root}/examples/common/pigweed:attributes_service.python",
+ "${chip_root}/examples/common/pigweed:boolean_state_service.python",
"${chip_root}/examples/common/pigweed:button_service.python",
"${chip_root}/examples/common/pigweed:descriptor_service.python",
"${chip_root}/examples/common/pigweed:device_service.python",
diff --git a/examples/common/pigweed/rpc_console/py/chip_rpc/console.py b/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
index 6d2b06fd73208f..f5ed5b5ab4d582 100644
--- a/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
+++ b/examples/common/pigweed/rpc_console/py/chip_rpc/console.py
@@ -47,6 +47,7 @@
# Protos
# isort: off
from attributes_service import attributes_service_pb2
+from boolean_state_service import boolean_state_service_pb2
from button_service import button_service_pb2
from descriptor_service import descriptor_service_pb2
from device_service import device_service_pb2
@@ -128,6 +129,7 @@ def show_console(device: str, baudrate: int,
use_ipython=True,
compiled_protos=[
attributes_service_pb2,
+ boolean_state_service_pb2,
button_service_pb2,
descriptor_service_pb2,
device_service_pb2,
diff --git a/examples/common/pigweed/rpc_services/BooleanState.h b/examples/common/pigweed/rpc_services/BooleanState.h
new file mode 100644
index 00000000000000..bb4b524459d03d
--- /dev/null
+++ b/examples/common/pigweed/rpc_services/BooleanState.h
@@ -0,0 +1,72 @@
+/*
+ *
+ * Copyright (c) 2024 Project CHIP Authors
+ * All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#pragma once
+
+#include "app/util/attribute-storage.h"
+#include "boolean_state_service/boolean_state_service.rpc.pb.h"
+#include "pigweed/rpc_services/internal/StatusUtils.h"
+#include
+#include
+#include
+
+namespace chip {
+namespace rpc {
+
+class BooleanState final : public pw_rpc::nanopb::BooleanState::Service
+{
+public:
+ virtual ~BooleanState() = default;
+
+ virtual pw::Status Set(const chip_rpc_BooleanStateSetRequest & request, chip_rpc_BooleanStateSetResponse & response)
+ {
+ EndpointId endpointId = request.endpoint_id;
+ bool newState = request.state_value;
+
+ EventNumber eventNumber;
+ {
+ DeviceLayer::StackLock lock;
+
+ // Update attribute first, then emit StateChange event only on success.
+ RETURN_STATUS_IF_NOT_OK(app::Clusters::BooleanState::Attributes::StateValue::Set(endpointId, newState));
+
+ chip::app::Clusters::BooleanState::Events::StateChange::Type event{ newState };
+ RETURN_STATUS_IF_NOT_OK(app::LogEvent(event, endpointId, eventNumber));
+ }
+
+ response.event_number = static_cast(eventNumber);
+ return pw::OkStatus();
+ }
+
+ virtual pw::Status Get(const chip_rpc_BooleanStateGetRequest & request, chip_rpc_BooleanStateGetResponse & response)
+ {
+ EndpointId endpointId = request.endpoint_id;
+ bool state_value = false;
+
+ {
+ DeviceLayer::StackLock lock;
+ RETURN_STATUS_IF_NOT_OK(app::Clusters::BooleanState::Attributes::StateValue::Get(endpointId, &state_value));
+ }
+
+ response.state.state_value = state_value;
+ return pw::OkStatus();
+ }
+};
+
+} // namespace rpc
+} // namespace chip
diff --git a/examples/common/pigweed/rpc_services/internal/StatusUtils.h b/examples/common/pigweed/rpc_services/internal/StatusUtils.h
index 444759f818efa2..f92ee66afc44bb 100644
--- a/examples/common/pigweed/rpc_services/internal/StatusUtils.h
+++ b/examples/common/pigweed/rpc_services/internal/StatusUtils.h
@@ -20,12 +20,13 @@
#pragma once
#include "app/util/attribute-storage.h"
+#include "protocols/interaction_model/StatusCode.h"
#include "pw_status/status.h"
#define RETURN_STATUS_IF_NOT_OK(expr) \
do \
{ \
- pw::Status __status = chip::rpc::EmberStatusToPwStatus(expr); \
+ pw::Status __status = chip::rpc::ToPwStatus(expr); \
if (!__status.ok()) \
{ \
return __status; \
@@ -35,7 +36,7 @@
namespace chip {
namespace rpc {
-constexpr pw::Status EmberStatusToPwStatus(EmberAfStatus ember_status)
+constexpr pw::Status ToPwStatus(EmberAfStatus ember_status)
{
switch (ember_status)
{
@@ -50,5 +51,26 @@ constexpr pw::Status EmberStatusToPwStatus(EmberAfStatus ember_status)
}
}
+constexpr pw::Status ToPwStatus(CHIP_ERROR chip_error_status)
+{
+ switch (chip_error_status.AsInteger())
+ {
+ case CHIP_NO_ERROR.AsInteger():
+ return pw::OkStatus();
+ case CHIP_IM_GLOBAL_STATUS(UnsupportedAttribute).AsInteger():
+ case CHIP_IM_GLOBAL_STATUS(UnsupportedCommand).AsInteger():
+ case CHIP_IM_GLOBAL_STATUS(UnsupportedEndpoint).AsInteger():
+ case CHIP_IM_GLOBAL_STATUS(UnsupportedEvent).AsInteger():
+ return pw::Status::NotFound();
+ case CHIP_IM_GLOBAL_STATUS(UnsupportedAccess).AsInteger():
+ return pw::Status::PermissionDenied();
+ case CHIP_IM_GLOBAL_STATUS(InvalidAction).AsInteger():
+ case CHIP_IM_GLOBAL_STATUS(InvalidCommand).AsInteger():
+ return pw::Status::InvalidArgument();
+ default:
+ return pw::Status::Unknown();
+ }
+}
+
} // namespace rpc
} // namespace chip
diff --git a/examples/common/tracing/BUILD.gn b/examples/common/tracing/BUILD.gn
index 266c3fc0f31581..cf6fdc2da525b4 100644
--- a/examples/common/tracing/BUILD.gn
+++ b/examples/common/tracing/BUILD.gn
@@ -93,7 +93,10 @@ source_set("trace_handlers_decoder") {
public_configs = [ ":default_config" ]
- deps = [ "${chip_root}/src/lib" ]
+ deps = [
+ "${chip_root}/src/lib",
+ "${chip_root}/src/lib/core:types",
+ ]
public_deps = [ "${chip_root}/third_party/jsoncpp" ]
cflags = [ "-Wconversion" ]
@@ -121,6 +124,7 @@ executable("chip-trace-decoder") {
public_deps = [
"${chip_root}/src/lib",
+ "${chip_root}/src/lib/core:types",
"${chip_root}/third_party/jsoncpp",
]
diff --git a/examples/common/websocket-server/BUILD.gn b/examples/common/websocket-server/BUILD.gn
index 1ea2687ce6afda..7eee9e2a40c967 100644
--- a/examples/common/websocket-server/BUILD.gn
+++ b/examples/common/websocket-server/BUILD.gn
@@ -34,6 +34,7 @@ static_library("websocket-server") {
]
public_deps = [
+ "${chip_root}/src/lib/core:types",
"${chip_root}/src/lib/support",
"${chip_root}/third_party/libwebsockets",
]
diff --git a/examples/darwin-framework-tool/BUILD.gn b/examples/darwin-framework-tool/BUILD.gn
index 1973c64a889e20..e31acadec076b6 100644
--- a/examples/darwin-framework-tool/BUILD.gn
+++ b/examples/darwin-framework-tool/BUILD.gn
@@ -42,6 +42,9 @@ declare_args() {
}
enable_provisional_features = config_enable_yaml_tests
+
+ # Disable generating compiler database by default
+ generate_compilation_database = false
}
sdk = "macosx"
@@ -107,6 +110,12 @@ action("build-darwin-framework") {
args += [ "--no-clang" ]
}
+ if (generate_compilation_database) {
+ args += [ "--compdb" ]
+ } else {
+ args += [ "--no-compdb" ]
+ }
+
if (config_enable_yaml_tests) {
args += [ "--enable-encoding-sentinel-enum-values" ]
} else {
diff --git a/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.h b/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.h
index d8130143e20d8c..39605e6fb56390 100644
--- a/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.h
+++ b/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.h
@@ -31,5 +31,6 @@ CHIP_ERROR LogAttributeAsJSON(NSNumber * endpointId, NSNumber * clusterId, NSNum
CHIP_ERROR LogCommandAsJSON(NSNumber * endpointId, NSNumber * clusterId, NSNumber * commandId, id result);
CHIP_ERROR LogAttributeErrorAsJSON(NSNumber * endpointId, NSNumber * clusterId, NSNumber * attributeId, NSError * error);
CHIP_ERROR LogCommandErrorAsJSON(NSNumber * endpointId, NSNumber * clusterId, NSNumber * commandId, NSError * error);
+CHIP_ERROR LogGetCommissionerNodeId(NSNumber * nodeId);
void SetDelegate(RemoteDataModelLoggerDelegate * delegate);
}; // namespace RemoteDataModelLogger
diff --git a/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.mm b/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.mm
index 196af6048356a4..760fe0bc998ed5 100644
--- a/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.mm
+++ b/examples/darwin-framework-tool/commands/common/RemoteDataModelLogger.mm
@@ -34,6 +34,7 @@
constexpr char kErrorIdKey[] = "error";
constexpr char kClusterErrorIdKey[] = "clusterError";
constexpr char kValueKey[] = "value";
+constexpr char kNodeIdKey[] = "nodeId";
constexpr char kBase64Header[] = "base64:";
@@ -191,5 +192,17 @@ CHIP_ERROR LogCommandErrorAsJSON(NSNumber * endpointId, NSNumber * clusterId, NS
return LogError(value, status);
}
+CHIP_ERROR LogGetCommissionerNodeId(NSNumber * value)
+{
+ VerifyOrReturnError(gDelegate != nullptr, CHIP_NO_ERROR);
+
+ Json::Value rootValue;
+ rootValue[kValueKey] = Json::Value();
+ rootValue[kValueKey][kNodeIdKey] = [value unsignedLongLongValue];
+
+ auto valueStr = JsonToString(rootValue);
+ return gDelegate->LogJSON(valueStr.c_str());
+}
+
void SetDelegate(RemoteDataModelLoggerDelegate * delegate) { gDelegate = delegate; }
}; // namespace RemoteDataModelLogger
diff --git a/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.h b/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.h
index 04d65bdf565db0..7f621afcfe80ea 100644
--- a/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.h
+++ b/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.h
@@ -31,5 +31,6 @@
- (void)controller:(MTRDeviceController *)controller statusUpdate:(MTRCommissioningStatus)status;
- (void)controller:(MTRDeviceController *)controller commissioningSessionEstablishmentDone:(NSError *)error;
- (void)controller:(MTRDeviceController *)controller commissioningComplete:(NSError *)error;
+- (void)controller:(MTRDeviceController *)controller commissioningComplete:(NSError *)error nodeID:(NSNumber *)nodeID metrics:(MTRMetrics *)metrics;
@end
diff --git a/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.mm b/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.mm
index 7b9f4369a79c7d..c8594a6f4fa87c 100644
--- a/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.mm
+++ b/examples/darwin-framework-tool/commands/pairing/DeviceControllerDelegateBridge.mm
@@ -63,4 +63,11 @@ - (void)controller:(MTRDeviceController *)controller commissioningComplete:(NSEr
_commandBridge->SetCommandExitStatus(error, "Pairing Commissioning Complete");
}
+- (void)controller:(MTRDeviceController *)controller commissioningComplete:(NSError *)error nodeID:(NSNumber *)nodeID metrics:(MTRMetrics *)metrics
+{
+ (void) nodeID;
+ NSString * message = [NSString stringWithFormat:@"Pairing Commissioning Complete with metrics %@", metrics];
+ _commandBridge->SetCommandExitStatus(error, [message UTF8String]);
+}
+
@end
diff --git a/examples/darwin-framework-tool/commands/pairing/GetCommissionerNodeIdCommand.mm b/examples/darwin-framework-tool/commands/pairing/GetCommissionerNodeIdCommand.mm
index 1dd852bd4d0817..34d3c87603d2f3 100644
--- a/examples/darwin-framework-tool/commands/pairing/GetCommissionerNodeIdCommand.mm
+++ b/examples/darwin-framework-tool/commands/pairing/GetCommissionerNodeIdCommand.mm
@@ -19,15 +19,17 @@
#import
#include "GetCommissionerNodeIdCommand.h"
+#include "RemoteDataModelLogger.h"
CHIP_ERROR GetCommissionerNodeIdCommand::RunCommand()
{
auto * controller = CurrentCommissioner();
VerifyOrReturnError(nil != controller, CHIP_ERROR_INCORRECT_STATE);
- ChipLogProgress(
- chipTool, "Commissioner Node Id 0x" ChipLogFormatX64, ChipLogValueX64(controller.controllerNodeId.unsignedLongLongValue));
+ auto controllerNodeId = controller.controllerNodeId;
+ ChipLogProgress(chipTool, "Commissioner Node Id 0x" ChipLogFormatX64, ChipLogValueX64(controllerNodeId.unsignedLongLongValue));
+ ReturnErrorOnFailure(RemoteDataModelLogger::LogGetCommissionerNodeId(controllerNodeId));
SetCommandExitStatus(CHIP_NO_ERROR);
return CHIP_NO_ERROR;
}
diff --git a/examples/energy-management-app/energy-management-common/energy-management-app.matter b/examples/energy-management-app/energy-management-common/energy-management-app.matter
index dae189309d4dbb..0e997312433125 100644
--- a/examples/energy-management-app/energy-management-common/energy-management-app.matter
+++ b/examples/energy-management-app/energy-management-common/energy-management-app.matter
@@ -948,8 +948,15 @@ provisional cluster ElectricalEnergyMeasurement = 145 {
MeasurementAccuracyRangeStruct accuracyRanges[] = 4;
}
+ struct CumulativeEnergyResetStruct {
+ optional nullable epoch_s importedResetTimestamp = 0;
+ optional nullable epoch_s exportedResetTimestamp = 1;
+ optional nullable systime_ms importedResetSystime = 2;
+ optional nullable systime_ms exportedResetSystime = 3;
+ }
+
struct EnergyMeasurementStruct {
- int64s energy = 0;
+ energy_mwh energy = 0;
optional epoch_s startTimestamp = 1;
optional epoch_s endTimestamp = 2;
optional systime_ms startSystime = 3;
@@ -971,6 +978,7 @@ provisional cluster ElectricalEnergyMeasurement = 145 {
readonly attribute optional nullable EnergyMeasurementStruct cumulativeEnergyExported = 2;
readonly attribute optional nullable EnergyMeasurementStruct periodicEnergyImported = 3;
readonly attribute optional nullable EnergyMeasurementStruct periodicEnergyExported = 4;
+ readonly attribute optional nullable CumulativeEnergyResetStruct cumulativeEnergyReset = 5;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1685,7 +1693,7 @@ endpoint 1 {
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
- ram attribute featureMap default = 5;
+ callback attribute featureMap;
ram attribute clusterRevision default = 1;
}
diff --git a/examples/energy-management-app/energy-management-common/src/EVSEManufacturerImpl.cpp b/examples/energy-management-app/energy-management-common/src/EVSEManufacturerImpl.cpp
index 70cd63e7926c8d..0f204671a9feca 100644
--- a/examples/energy-management-app/energy-management-common/src/EVSEManufacturerImpl.cpp
+++ b/examples/energy-management-app/energy-management-common/src/EVSEManufacturerImpl.cpp
@@ -18,9 +18,9 @@
#include
#include
-#include
+#include
#include
-#include
+#include
using namespace chip;
using namespace chip::app;
diff --git a/examples/energy-management-app/linux/README.md b/examples/energy-management-app/linux/README.md
index d316dd807c13e2..424ef46d58e259 100644
--- a/examples/energy-management-app/linux/README.md
+++ b/examples/energy-management-app/linux/README.md
@@ -366,7 +366,7 @@ If you haven't implemented a real EVSE but want to simulate plugging in an EV
then you can use a few of the test event triggers to simulate these scenarios.
The test event triggers values can be found in:
-[EnergyEvseTestEventTriggerDelegate.h](../../../src/app/clusters/energy-evse-server/EnergyEvseTestEventTriggerDelegate.h)
+[EnergyEvseTestEventTriggerHandler.h](../../../src/app/clusters/energy-evse-server/EnergyEvseTestEventTriggerHandler.h)
- 0x0099000000000000 - Simulates the EVSE being installed on a 32A supply
- 0x0099000000000002 - Simulates the EVSE being plugged in (this should
diff --git a/examples/light-switch-app/esp32/main/CMakeLists.txt b/examples/light-switch-app/esp32/main/CMakeLists.txt
index 5bdac22300b33f..210cbcefee9a23 100644
--- a/examples/light-switch-app/esp32/main/CMakeLists.txt
+++ b/examples/light-switch-app/esp32/main/CMakeLists.txt
@@ -31,7 +31,7 @@ idf_component_register(PRIV_INCLUDE_DIRS
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/util"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/reporting"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/access-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/administrator-commissioning-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/basic-information"
diff --git a/examples/light-switch-app/infineon/cyw30739/src/main.cpp b/examples/light-switch-app/infineon/cyw30739/src/main.cpp
index dbfdb81b875b3f..483a475b51cee0 100644
--- a/examples/light-switch-app/infineon/cyw30739/src/main.cpp
+++ b/examples/light-switch-app/infineon/cyw30739/src/main.cpp
@@ -26,8 +26,9 @@
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include
#endif
+#include
#include
-#include
+#include
#include
#include
#include
@@ -192,10 +193,13 @@ void InitApp(intptr_t args)
// Print QR Code URL
PrintOnboardingCodes(chip::RendezvousInformationFlag(chip::RendezvousInformationFlag::kBLE));
/* Start CHIP datamodel server */
- static chip::OTATestEventTriggerDelegate testEventTriggerDelegate{ chip::ByteSpan(sTestEventTriggerEnableKey) };
+ static chip::SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static chip::OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(chip::ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
static chip::CommonCaseDeviceServerInitParams initParams;
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
gExampleDeviceInfoProvider.SetStorageDelegate(initParams.persistentStorageDelegate);
chip::DeviceLayer::SetDeviceInfoProvider(&gExampleDeviceInfoProvider);
chip::Inet::EndPointStateOpenThread::OpenThreadEndpointInitParam nativeParams;
diff --git a/examples/light-switch-app/nrfconnect/main/AppTask.cpp b/examples/light-switch-app/nrfconnect/main/AppTask.cpp
index a4b5ac5b47b318..06ac797f6a6899 100644
--- a/examples/light-switch-app/nrfconnect/main/AppTask.cpp
+++ b/examples/light-switch-app/nrfconnect/main/AppTask.cpp
@@ -24,8 +24,9 @@
#include "LightSwitch.h"
#include
+#include
#include
-#include
+#include
#include
#include
#include
@@ -215,9 +216,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/light-switch-app/qpg/BUILD.gn b/examples/light-switch-app/qpg/BUILD.gn
index 659f2d4ab1efd3..055cfd46f95abb 100644
--- a/examples/light-switch-app/qpg/BUILD.gn
+++ b/examples/light-switch-app/qpg/BUILD.gn
@@ -51,7 +51,7 @@ qpg_executable("light_switch_app") {
output_name = "chip-${qpg_target_ic}-light-switch-example.out"
sources = [
- "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerDelegate.cpp",
+ "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerHandler.cpp",
"${examples_plat_dir}/app/main.cpp",
"${examples_plat_dir}/ota/ota.cpp",
"src/AppTask.cpp",
diff --git a/examples/light-switch-app/qpg/src/AppTask.cpp b/examples/light-switch-app/qpg/src/AppTask.cpp
index 9f6662206f2e74..f02823b178220d 100644
--- a/examples/light-switch-app/qpg/src/AppTask.cpp
+++ b/examples/light-switch-app/qpg/src/AppTask.cpp
@@ -31,7 +31,8 @@ using namespace ::chip;
#include
-#include
+#include
+#include
#include
#include
#include
@@ -191,10 +192,13 @@ void AppTask::InitServer(intptr_t arg)
nativeParams.openThreadInstancePtr = chip::DeviceLayer::ThreadStackMgrImpl().OTInstance();
initParams.endpointNativeParams = static_cast(&nativeParams);
- // Use GenericFaultTestEventTriggerDelegate to inject faults
- static GenericFaultTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ // Use GenericFaultTestEventTriggerHandler to inject faults
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static GenericFaultTestEventTriggerHandler sFaultTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sFaultTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
chip::Server::GetInstance().Init(initParams);
diff --git a/examples/light-switch-app/silabs/README.md b/examples/light-switch-app/silabs/README.md
index a7e19ba18b2e98..615b27c7bc3cd9 100644
--- a/examples/light-switch-app/silabs/README.md
+++ b/examples/light-switch-app/silabs/README.md
@@ -59,8 +59,9 @@ Silicon Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools(likely already present for CHIP developers):
diff --git a/examples/lighting-app/infineon/cyw30739/src/main.cpp b/examples/lighting-app/infineon/cyw30739/src/main.cpp
index 14730252de08b3..f851e2e8819664 100644
--- a/examples/lighting-app/infineon/cyw30739/src/main.cpp
+++ b/examples/lighting-app/infineon/cyw30739/src/main.cpp
@@ -26,8 +26,9 @@
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include
#endif
+#include
#include
-#include
+#include
#include
#include
#include
@@ -191,10 +192,13 @@ void InitApp(intptr_t args)
// Print QR Code URL
PrintOnboardingCodes(chip::RendezvousInformationFlag(chip::RendezvousInformationFlag::kBLE));
/* Start CHIP datamodel server */
- static chip::OTATestEventTriggerDelegate testEventTriggerDelegate{ chip::ByteSpan(sTestEventTriggerEnableKey) };
+ static chip::SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static chip::OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(chip::ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
static chip::CommonCaseDeviceServerInitParams initParams;
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
gExampleDeviceInfoProvider.SetStorageDelegate(initParams.persistentStorageDelegate);
chip::DeviceLayer::SetDeviceInfoProvider(&gExampleDeviceInfoProvider);
chip::Inet::EndPointStateOpenThread::OpenThreadEndpointInitParam nativeParams;
diff --git a/examples/lighting-app/nrfconnect/main/AppTask.cpp b/examples/lighting-app/nrfconnect/main/AppTask.cpp
index 03632106fc8667..494095e04de9dc 100644
--- a/examples/lighting-app/nrfconnect/main/AppTask.cpp
+++ b/examples/lighting-app/nrfconnect/main/AppTask.cpp
@@ -27,8 +27,9 @@
#include
#include
#include
+#include
#include
-#include
+#include
#include
#include
#include
@@ -243,9 +244,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp b/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp
index 557293f6bac2aa..b1fc51c7c29360 100644
--- a/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp
+++ b/examples/lighting-app/nxp/k32w/k32w0/main/AppTask.cpp
@@ -286,8 +286,8 @@ void AppTask::InitServer(intptr_t arg)
chip::DeviceLayer::SetDeviceInfoProvider(&infoProvider);
// Init ZCL Data Model and start server
- static DefaultTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ static DefaultTestEventTriggerDelegate sTestEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
chip::Inet::EndPointStateOpenThread::OpenThreadEndpointInitParam nativeParams;
nativeParams.lockCb = LockOpenThreadTask;
nativeParams.unlockCb = UnlockOpenThreadTask;
diff --git a/examples/lighting-app/nxp/k32w/k32w1/main/AppTask.cpp b/examples/lighting-app/nxp/k32w/k32w1/main/AppTask.cpp
index 66eee725c581c2..7150003f599588 100644
--- a/examples/lighting-app/nxp/k32w/k32w1/main/AppTask.cpp
+++ b/examples/lighting-app/nxp/k32w/k32w1/main/AppTask.cpp
@@ -214,8 +214,8 @@ void AppTask::InitServer(intptr_t arg)
#endif
// Init ZCL Data Model and start server
- static DefaultTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ static DefaultTestEventTriggerDelegate sTestEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
chip::Inet::EndPointStateOpenThread::OpenThreadEndpointInitParam nativeParams;
nativeParams.lockCb = LockOpenThreadTask;
nativeParams.unlockCb = UnlockOpenThreadTask;
diff --git a/examples/lighting-app/qpg/BUILD.gn b/examples/lighting-app/qpg/BUILD.gn
index d8f86311d627eb..c835e0bf3cdaed 100644
--- a/examples/lighting-app/qpg/BUILD.gn
+++ b/examples/lighting-app/qpg/BUILD.gn
@@ -51,7 +51,7 @@ qpg_executable("lighting_app") {
output_name = "chip-${qpg_target_ic}-lighting-example.out"
sources = [
- "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerDelegate.cpp",
+ "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerHandler.cpp",
"${examples_plat_dir}/app/main.cpp",
"${examples_plat_dir}/ota/ota.cpp",
"${examples_plat_dir}/powercycle_counting.c",
diff --git a/examples/lighting-app/qpg/src/AppTask.cpp b/examples/lighting-app/qpg/src/AppTask.cpp
index 1dd1aa85514a7a..4dafde6ac41960 100644
--- a/examples/lighting-app/qpg/src/AppTask.cpp
+++ b/examples/lighting-app/qpg/src/AppTask.cpp
@@ -33,7 +33,8 @@
#include
#include
-#include
+#include
+#include
#include
#include
#include
@@ -264,10 +265,13 @@ void AppTask::InitServer(intptr_t arg)
nativeParams.openThreadInstancePtr = chip::DeviceLayer::ThreadStackMgrImpl().OTInstance();
initParams.endpointNativeParams = static_cast(&nativeParams);
- // Use GenericFaultTestEventTriggerDelegate to inject faults
- static GenericFaultTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ // Use GenericFaultTestEventTriggerHandler to inject faults
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static GenericFaultTestEventTriggerHandler sFaultTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sFaultTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
chip::Server::GetInstance().Init(initParams);
diff --git a/examples/lighting-app/silabs/README.md b/examples/lighting-app/silabs/README.md
index 639afd163fe7ef..08db63d9d3f0ea 100644
--- a/examples/lighting-app/silabs/README.md
+++ b/examples/lighting-app/silabs/README.md
@@ -57,8 +57,9 @@ Silicon Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools (likely already present for CHIP developers):
diff --git a/examples/lit-icd-app/linux/BUILD.gn b/examples/lit-icd-app/linux/BUILD.gn
index 6a2a26c7b8a034..fd8c0dfbbad343 100644
--- a/examples/lit-icd-app/linux/BUILD.gn
+++ b/examples/lit-icd-app/linux/BUILD.gn
@@ -21,7 +21,7 @@ executable("lit-icd-app") {
deps = [
"${chip_root}/examples/lit-icd-app/lit-icd-common",
"${chip_root}/examples/platform/linux:app-main",
- "${chip_root}/src/app/icd:manager",
+ "${chip_root}/src/app/icd/server:manager",
"${chip_root}/src/lib",
"${chip_root}/third_party/jsoncpp",
]
diff --git a/examples/lit-icd-app/silabs/README.md b/examples/lit-icd-app/silabs/README.md
index 4a5b6b35851581..f359eacbd23cf4 100644
--- a/examples/lit-icd-app/silabs/README.md
+++ b/examples/lit-icd-app/silabs/README.md
@@ -59,8 +59,9 @@ Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools(likely already present for CHIP developers):
diff --git a/examples/lock-app/esp32/main/CMakeLists.txt b/examples/lock-app/esp32/main/CMakeLists.txt
index 7efc567f107ffd..e7266908ff3c1d 100644
--- a/examples/lock-app/esp32/main/CMakeLists.txt
+++ b/examples/lock-app/esp32/main/CMakeLists.txt
@@ -50,7 +50,7 @@ idf_component_register(INCLUDE_DIRS
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/util"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/reporting"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/access-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/administrator-commissioning-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/basic-information"
@@ -163,7 +163,7 @@ idf_component_register(PRIV_INCLUDE_DIRS
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/util"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/reporting"
- "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd"
+ "${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/icd/server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/access-control-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/administrator-commissioning-server"
"${CMAKE_SOURCE_DIR}/third_party/connectedhomeip/src/app/clusters/basic-information"
diff --git a/examples/lock-app/infineon/cyw30739/src/main.cpp b/examples/lock-app/infineon/cyw30739/src/main.cpp
index 76fa8484ce74eb..a0a92487a807bc 100644
--- a/examples/lock-app/infineon/cyw30739/src/main.cpp
+++ b/examples/lock-app/infineon/cyw30739/src/main.cpp
@@ -28,9 +28,10 @@
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
#include
#endif
+#include
#include
#include
-#include
+#include
#include
#include
#include
@@ -191,10 +192,13 @@ void InitApp(intptr_t args)
// Print QR Code URL
PrintOnboardingCodes(chip::RendezvousInformationFlag(chip::RendezvousInformationFlag::kBLE));
/* Start CHIP datamodel server */
- static chip::OTATestEventTriggerDelegate testEventTriggerDelegate{ chip::ByteSpan(sTestEventTriggerEnableKey) };
+ static chip::SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static chip::OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(chip::ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
static chip::CommonCaseDeviceServerInitParams initParams;
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
gExampleDeviceInfoProvider.SetStorageDelegate(initParams.persistentStorageDelegate);
chip::DeviceLayer::SetDeviceInfoProvider(&gExampleDeviceInfoProvider);
chip::Inet::EndPointStateOpenThread::OpenThreadEndpointInitParam nativeParams;
diff --git a/examples/lock-app/nrfconnect/main/AppTask.cpp b/examples/lock-app/nrfconnect/main/AppTask.cpp
index d64a4950ace777..07a96b6d6c29b2 100644
--- a/examples/lock-app/nrfconnect/main/AppTask.cpp
+++ b/examples/lock-app/nrfconnect/main/AppTask.cpp
@@ -25,9 +25,10 @@
#include
#include
+#include
#include
#include
-#include
+#include
#include
#include
#include
@@ -209,9 +210,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/lock-app/qpg/BUILD.gn b/examples/lock-app/qpg/BUILD.gn
index 2426fa7c3179d5..30794878fd1ae8 100644
--- a/examples/lock-app/qpg/BUILD.gn
+++ b/examples/lock-app/qpg/BUILD.gn
@@ -51,7 +51,7 @@ qpg_executable("lock_app") {
output_name = "chip-${qpg_target_ic}-lock-example.out"
sources = [
- "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerDelegate.cpp",
+ "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerHandler.cpp",
"${examples_plat_dir}/app/main.cpp",
"${examples_plat_dir}/ota/ota.cpp",
"src/AppTask.cpp",
diff --git a/examples/lock-app/qpg/src/AppTask.cpp b/examples/lock-app/qpg/src/AppTask.cpp
index 8bbd6b7ce19a8a..54a4b2a5d2a3f3 100644
--- a/examples/lock-app/qpg/src/AppTask.cpp
+++ b/examples/lock-app/qpg/src/AppTask.cpp
@@ -26,7 +26,8 @@
#include
#include
-#include
+#include
+#include
#include
#include
#include
@@ -189,10 +190,13 @@ void AppTask::InitServer(intptr_t arg)
nativeParams.openThreadInstancePtr = chip::DeviceLayer::ThreadStackMgrImpl().OTInstance();
initParams.endpointNativeParams = static_cast(&nativeParams);
- // Use GenericFaultTestEventTriggerDelegate to inject faults
- static GenericFaultTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ // Use GenericFaultTestEventTriggerHandler to inject faults
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static GenericFaultTestEventTriggerHandler sFaultTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sFaultTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
chip::Server::GetInstance().Init(initParams);
diff --git a/examples/lock-app/silabs/README.md b/examples/lock-app/silabs/README.md
index 7d8d576c68492c..1bce8c431bee54 100644
--- a/examples/lock-app/silabs/README.md
+++ b/examples/lock-app/silabs/README.md
@@ -54,8 +54,9 @@ Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools(likely already present for CHIP developers):
diff --git a/examples/placeholder/templates/tests-commands.zapt b/examples/placeholder/templates/tests-commands.zapt
index c1d87417bc5906..be0474f4632605 100644
--- a/examples/placeholder/templates/tests-commands.zapt
+++ b/examples/placeholder/templates/tests-commands.zapt
@@ -4,7 +4,7 @@
#include "TestCommand.h"
-#include
+#include
{{>test_cluster tests="../linux/apps/app1/ciTests.json" credsIssuerConfigArg=false needsWaitDuration=false}}
diff --git a/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.cpp b/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.cpp
index 9cfddd6f3de9fa..8bbae5e1978097 100644
--- a/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.cpp
+++ b/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.cpp
@@ -28,10 +28,4 @@ bool AmebaTestEventTriggerDelegate::DoesEnableKeyMatch(const ByteSpan & enableKe
return !mEnableKey.empty() && mEnableKey.data_equal(enableKey);
}
-CHIP_ERROR AmebaTestEventTriggerDelegate::HandleEventTrigger(uint64_t eventTrigger)
-{
- bool success = emberAfHandleEventTrigger(eventTrigger);
- return success ? CHIP_NO_ERROR : CHIP_ERROR_INVALID_ARGUMENT;
-}
-
} // namespace chip
diff --git a/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.h b/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.h
index d461194de9b642..9e770406303645 100644
--- a/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.h
+++ b/examples/platform/ameba/test_event_trigger/AmebaTestEventTriggerDelegate.h
@@ -18,15 +18,38 @@
#pragma once
-#include "SmokeCOAlarmManager.h"
+#include
+
#include
+#include
+#include
+#include
+
+/**
+ * @brief User handler for handling the test event trigger
+ *
+ * @note If TestEventTrigger is enabled, it needs to be implemented in the app
+ *
+ * @param eventTrigger Event trigger to handle
+ *
+ * @warning *** DO NOT USE FOR STANDARD CLUSTER EVENT TRIGGERS ***
+ *
+ * TODO(#31723): Rename `emberAfHandleEventTrigger` to `AmebaHandleGlobalTestEventTrigger`
+ *
+ * @retval true on success
+ * @retval false if error happened
+ */
+bool emberAfHandleEventTrigger(uint64_t eventTrigger);
namespace chip {
-class AmebaTestEventTriggerDelegate : public TestEventTriggerDelegate
+class AmebaTestEventTriggerDelegate : public TestEventTriggerDelegate, TestEventTriggerHandler
{
public:
- explicit AmebaTestEventTriggerDelegate(const ByteSpan & enableKey) : mEnableKey(enableKey) {}
+ explicit AmebaTestEventTriggerDelegate(const ByteSpan & enableKey) : mEnableKey(enableKey)
+ {
+ VerifyOrDie(AddHandler(this) == CHIP_NO_ERROR);
+ }
/**
* @brief Checks to see if `enableKey` provided matches value chosen by the manufacturer.
@@ -35,27 +58,14 @@ class AmebaTestEventTriggerDelegate : public TestEventTriggerDelegate
*/
bool DoesEnableKeyMatch(const ByteSpan & enableKey) const override;
- /**
- * @brief User handler for handling the test event trigger based on `eventTrigger` provided.
- * @param eventTrigger Event trigger to handle.
- * @return CHIP_NO_ERROR on success or CHIP_ERROR_INVALID_ARGUMENT on failure.
- */
- CHIP_ERROR HandleEventTrigger(uint64_t eventTrigger) override;
+ CHIP_ERROR HandleEventTrigger(uint64_t eventTrigger) override
+ {
+ // WARNING: LEGACY SUPPORT ONLY, DO NOT EXTEND FOR STANDARD CLUSTERS
+ return (emberAfHandleEventTrigger(eventTrigger)) ? CHIP_NO_ERROR : CHIP_ERROR_INVALID_ARGUMENT;
+ }
private:
ByteSpan mEnableKey;
};
} // namespace chip
-
-/**
- * @brief User handler for handling the test event trigger
- *
- * @note If TestEventTrigger is enabled, it needs to be implemented in the app
- *
- * @param eventTrigger Event trigger to handle
- *
- * @retval true on success
- * @retval false if error happened
- */
-bool emberAfHandleEventTrigger(uint64_t eventTrigger);
diff --git a/examples/platform/esp32/Rpc.cpp b/examples/platform/esp32/Rpc.cpp
index 57f01b8f60b2ae..61efb842f089b7 100644
--- a/examples/platform/esp32/Rpc.cpp
+++ b/examples/platform/esp32/Rpc.cpp
@@ -33,6 +33,10 @@
#include "pigweed/rpc_services/Attributes.h"
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+#include "pigweed/rpc_services/BooleanState.h"
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
#if CONFIG_DEVICE_TYPE_M5STACK
#include "ScreenManager.h"
@@ -275,6 +279,10 @@ StackType_t sRpcTaskStack[RPC_TASK_STACK_SIZE];
Attributes attributes_service;
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+BooleanState boolean_state_service;
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
Esp32Button button_service;
#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
@@ -309,6 +317,10 @@ void RegisterServices(pw::rpc::Server & server)
server.RegisterService(attributes_service);
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+ server.RegisterService(boolean_state_service);
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
server.RegisterService(button_service);
#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
diff --git a/examples/platform/esp32/common/Esp32AppServer.cpp b/examples/platform/esp32/common/Esp32AppServer.cpp
index fee87880d2d9e1..b60685d34debca 100644
--- a/examples/platform/esp32/common/Esp32AppServer.cpp
+++ b/examples/platform/esp32/common/Esp32AppServer.cpp
@@ -19,8 +19,9 @@
#include "Esp32AppServer.h"
#include "CHIPDeviceManager.h"
#include
+#include
#include
-#include
+#include
#include
#include
#include
@@ -169,8 +170,11 @@ void Esp32AppServer::Init(AppDelegate * sAppDelegate)
ESP_LOGE(TAG, "Failed to convert the EnableKey string to octstr type value");
memset(sTestEventTriggerEnableKey, 0, sizeof(sTestEventTriggerEnableKey));
}
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
#endif // CONFIG_TEST_EVENT_TRIGGER_ENABLED
(void) initParams.InitializeStaticResourcesBeforeServerInit();
if (sAppDelegate != nullptr)
diff --git a/examples/platform/linux/AppMain.cpp b/examples/platform/linux/AppMain.cpp
index 04274ab2f33c24..061d7b66c5e4c6 100644
--- a/examples/platform/linux/AppMain.cpp
+++ b/examples/platform/linux/AppMain.cpp
@@ -75,19 +75,19 @@
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
-#include
+#include
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_SMOKE_CO_TRIGGER
-#include
+#include
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_BOOLEAN_STATE_CONFIGURATION_TRIGGER
-#include
+#include
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_ENERGY_EVSE_TRIGGER
-#include
+#include
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_ENERGY_REPORTING_TRIGGER
-#include
+#include
#endif
#include
@@ -331,34 +331,13 @@ static bool EnsureWiFiIsStarted()
}
#endif
-class SampleTestEventTriggerDelegate : public TestEventTriggerDelegate
+class SampleTestEventTriggerHandler : public TestEventTriggerHandler
{
-public:
- /// NOTE: If you copy this, please use the reserved range FFFF_FFFF__xxxx for your trigger codes.
+ /// NOTE: If you copy this for NON-STANDARD CLUSTERS OR USAGES, please use the reserved range FFFF_FFFF__xxxx for your
+ /// trigger codes. NOTE: Standard codes are _xxxx_xxxx_xxxx.
static constexpr uint64_t kSampleTestEventTriggerAlwaysSuccess = static_cast(0xFFFF'FFFF'FFF1'0000ull);
- SampleTestEventTriggerDelegate() { memset(&mEnableKey[0], 0, sizeof(mEnableKey)); }
-
- /**
- * @brief Initialize the delegate with a key and an optional other handler
- *
- * The `otherDelegate` will be called if there is no match of the eventTrigger
- * when HandleEventTrigger is called, if it is non-null.
- *
- * @param enableKey - EnableKey to use for this instance.
- * @param otherDelegate - Other delegate (e.g. OTA delegate) where defer trigger. Can be nullptr
- * @return CHIP_NO_ERROR on success, CHIP_ERROR_INVALID_ARGUMENT if enableKey is wrong size.
- */
- CHIP_ERROR Init(ByteSpan enableKey, TestEventTriggerDelegate * otherDelegate)
- {
- VerifyOrReturnError(enableKey.size() == sizeof(mEnableKey), CHIP_ERROR_INVALID_ARGUMENT);
- mOtherDelegate = otherDelegate;
- MutableByteSpan ourEnableKeySpan(mEnableKey);
- return CopySpanToMutableSpan(enableKey, ourEnableKeySpan);
- }
-
- bool DoesEnableKeyMatch(const ByteSpan & enableKey) const override { return enableKey.data_equal(ByteSpan(mEnableKey)); }
-
+public:
CHIP_ERROR HandleEventTrigger(uint64_t eventTrigger) override
{
ChipLogProgress(Support, "Saw TestEventTrigger: " ChipLogFormatX64, ChipLogValueX64(eventTrigger));
@@ -370,12 +349,8 @@ class SampleTestEventTriggerDelegate : public TestEventTriggerDelegate
return CHIP_NO_ERROR;
}
- return (mOtherDelegate != nullptr) ? mOtherDelegate->HandleEventTrigger(eventTrigger) : CHIP_ERROR_INVALID_ARGUMENT;
+ return CHIP_ERROR_INVALID_ARGUMENT;
}
-
-private:
- uint8_t mEnableKey[TestEventTriggerDelegate::kEnableKeyLength];
- TestEventTriggerDelegate * mOtherDelegate = nullptr;
};
int ChipLinuxAppInit(int argc, char * const argv[], OptionSet * customOptions,
@@ -549,44 +524,36 @@ void ChipLinuxAppMainLoop(AppMainLoopImplementation * impl)
initParams.operationalKeystore = &LinuxDeviceOptions::GetInstance().mCSRResponseOptions.badCsrOperationalKeyStoreForTest;
}
- TestEventTriggerDelegate * otherDelegate = nullptr;
+ // For general testing of TestEventTrigger, we have a common "core" event trigger delegate.
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate;
+ static SampleTestEventTriggerHandler sTestEventTriggerHandler;
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey)) ==
+ CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sTestEventTriggerHandler) == CHIP_NO_ERROR);
+
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
// We want to allow triggering OTA queries if OTA requestor is enabled
- static OTATestEventTriggerDelegate otaTestEventTriggerDelegate{ ByteSpan(
- LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey) };
- otherDelegate = &otaTestEventTriggerDelegate;
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler;
+ sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler);
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_SMOKE_CO_TRIGGER
- static SmokeCOTestEventTriggerDelegate smokeCOTestEventTriggerDelegate{
- ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey), otherDelegate
- };
- otherDelegate = &smokeCOTestEventTriggerDelegate;
+ static SmokeCOTestEventTriggerHandler sSmokeCOTestEventTriggerHandler;
+ sTestEventTriggerDelegate.AddHandler(&sSmokeCOTestEventTriggerHandler);
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_BOOLEAN_STATE_CONFIGURATION_TRIGGER
- static BooleanStateConfigurationTestEventTriggerDelegate booleanStateConfigurationTestEventTriggerDelegate{
- ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey), otherDelegate
- };
- otherDelegate = &booleanStateConfigurationTestEventTriggerDelegate;
+ static BooleanStateConfigurationTestEventTriggerHandler sBooleanStateConfigurationTestEventTriggerHandler;
+ sTestEventTriggerDelegate.AddHandler(&sBooleanStateConfigurationTestEventTriggerHandler);
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_ENERGY_EVSE_TRIGGER
- static EnergyEvseTestEventTriggerDelegate energyEvseTestEventTriggerDelegate{
- ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey), otherDelegate
- };
- otherDelegate = &energyEvseTestEventTriggerDelegate;
+ static EnergyEvseTestEventTriggerHandler sEnergyEvseTestEventTriggerHandler;
+ sTestEventTriggerDelegate.AddHandler(&sEnergyEvseTestEventTriggerHandler);
#endif
#if CHIP_DEVICE_CONFIG_ENABLE_ENERGY_REPORTING_TRIGGER
- static EnergyReportingTestEventTriggerDelegate energyReportingTestEventTriggerDelegate{
- ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey), otherDelegate
- };
- otherDelegate = &energyReportingTestEventTriggerDelegate;
+ static EnergyReportingTestEventTriggerHandler sEnergyReportingTestEventTriggerHandler;
+ sTestEventTriggerDelegate.AddHandler(&sEnergyReportingTestEventTriggerHandler);
#endif
- // For general testing of TestEventTrigger, we have a common "core" event trigger delegate.
- static SampleTestEventTriggerDelegate testEventTriggerDelegate;
- VerifyOrDie(testEventTriggerDelegate.Init(ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey),
- otherDelegate) == CHIP_NO_ERROR);
-
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
// We need to set DeviceInfoProvider before Server::Init to setup the storage of DeviceInfoProvider properly.
DeviceLayer::SetDeviceInfoProvider(&gExampleDeviceInfoProvider);
diff --git a/examples/platform/linux/BUILD.gn b/examples/platform/linux/BUILD.gn
index f82702be227709..8cf00c5be5e62c 100644
--- a/examples/platform/linux/BUILD.gn
+++ b/examples/platform/linux/BUILD.gn
@@ -32,24 +32,24 @@ config("app-main-config") {
source_set("ota-test-event-trigger") {
sources = [
- "${chip_root}/src/app/clusters/ota-requestor/OTATestEventTriggerDelegate.h",
+ "${chip_root}/src/app/clusters/ota-requestor/OTATestEventTriggerHandler.h",
]
}
source_set("smco-test-event-trigger") {
- sources = [ "${chip_root}/src/app/clusters/smoke-co-alarm-server/SmokeCOTestEventTriggerDelegate.h" ]
+ sources = [ "${chip_root}/src/app/clusters/smoke-co-alarm-server/SmokeCOTestEventTriggerHandler.h" ]
}
source_set("boolean-state-configuration-test-event-trigger") {
- sources = [ "${chip_root}/src/app/clusters/boolean-state-configuration-server/BooleanStateConfigurationTestEventTriggerDelegate.h" ]
+ sources = [ "${chip_root}/src/app/clusters/boolean-state-configuration-server/BooleanStateConfigurationTestEventTriggerHandler.h" ]
}
source_set("energy-evse-test-event-trigger") {
- sources = [ "${chip_root}/src/app/clusters/energy-evse-server/EnergyEvseTestEventTriggerDelegate.h" ]
+ sources = [ "${chip_root}/src/app/clusters/energy-evse-server/EnergyEvseTestEventTriggerHandler.h" ]
}
source_set("energy-reporting-test-event-trigger") {
- sources = [ "${chip_root}/src/app/clusters/electrical-energy-measurement-server/EnergyReportingTestEventTriggerDelegate.h" ]
+ sources = [ "${chip_root}/src/app/clusters/electrical-energy-measurement-server/EnergyReportingTestEventTriggerHandler.h" ]
}
source_set("app-main") {
diff --git a/examples/platform/linux/Rpc.cpp b/examples/platform/linux/Rpc.cpp
index f45df32d750a81..da6b73b9135c13 100644
--- a/examples/platform/linux/Rpc.cpp
+++ b/examples/platform/linux/Rpc.cpp
@@ -26,6 +26,10 @@
#include "pigweed/rpc_services/Attributes.h"
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+#include "pigweed/rpc_services/BooleanState.h"
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
#include "pigweed/rpc_services/Descriptor.h"
#endif // defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
@@ -68,6 +72,10 @@ namespace {
Attributes attributes_service;
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+BooleanState boolean_state_service;
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
Descriptor descriptor_service;
#endif // defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
@@ -90,6 +98,10 @@ void RegisterServices(pw::rpc::Server & server)
server.RegisterService(attributes_service);
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+ server.RegisterService(boolean_state_service);
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
server.RegisterService(descriptor_service);
#endif // defined(PW_RPC_DESCRIPTOR_SERVICE) && PW_RPC_DESCRIPTOR_SERVICE
diff --git a/examples/platform/nrfconnect/Rpc.cpp b/examples/platform/nrfconnect/Rpc.cpp
index ec21fd7e379f05..8b47215d6a0680 100644
--- a/examples/platform/nrfconnect/Rpc.cpp
+++ b/examples/platform/nrfconnect/Rpc.cpp
@@ -32,6 +32,10 @@ LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL);
#include "pigweed/rpc_services/Attributes.h"
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+#include "pigweed/rpc_services/BooleanState.h"
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
#include "pigweed/rpc_services/Button.h"
#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
@@ -139,6 +143,10 @@ struct k_thread rpc_thread_data;
Attributes attributes_service;
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+BooleanState boolean_state_service;
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
NrfButton button_service;
#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
@@ -177,6 +185,10 @@ void RegisterServices(pw::rpc::Server & server)
server.RegisterService(attributes_service);
#endif // defined(PW_RPC_ATTRIBUTE_SERVICE) && PW_RPC_ATTRIBUTE_SERVICE
+#if defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+ server.RegisterService(boolean_state_service);
+#endif // defined(PW_RPC_BOOLEAN_STATE_SERVICE) && PW_RPC_BOOLEAN_STATE_SERVICE
+
#if defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
server.RegisterService(button_service);
#endif // defined(PW_RPC_BUTTON_SERVICE) && PW_RPC_BUTTON_SERVICE
diff --git a/examples/platform/nxp/se05x/linux/AppMain.cpp b/examples/platform/nxp/se05x/linux/AppMain.cpp
index 2c04b81b0ce8bb..bd13e249683fcb 100644
--- a/examples/platform/nxp/se05x/linux/AppMain.cpp
+++ b/examples/platform/nxp/se05x/linux/AppMain.cpp
@@ -69,7 +69,8 @@
#endif // CHIP_CONFIG_TRANSPORT_TRACE_ENABLED
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
-#include
+#include
+#include
#endif
#include
@@ -315,9 +316,12 @@ void ChipLinuxAppMainLoop(AppMainLoopImplementation * impl)
}
#if CHIP_DEVICE_CONFIG_ENABLE_OTA_REQUESTOR
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(
- LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(LinuxDeviceOptions::GetInstance().testEventTriggerEnableKey)) ==
+ CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
#endif
// We need to set DeviceInfoProvider before Server::Init to setup the storage of DeviceInfoProvider properly.
diff --git a/examples/platform/nxp/se05x/linux/BUILD.gn b/examples/platform/nxp/se05x/linux/BUILD.gn
index 2a93a4bf085a3e..a5efe460745ddd 100644
--- a/examples/platform/nxp/se05x/linux/BUILD.gn
+++ b/examples/platform/nxp/se05x/linux/BUILD.gn
@@ -25,7 +25,7 @@ config("app-main-config") {
source_set("ota-test-event-trigger") {
sources = [
- "${chip_root}/src/app/clusters/ota-requestor/OTATestEventTriggerDelegate.h",
+ "${chip_root}/src/app/clusters/ota-requestor/OTATestEventTriggerHandler.h",
]
}
diff --git a/examples/platform/silabs/BaseApplication.cpp b/examples/platform/silabs/BaseApplication.cpp
index 3677c1bed72b83..d2c6266a58382b 100644
--- a/examples/platform/silabs/BaseApplication.cpp
+++ b/examples/platform/silabs/BaseApplication.cpp
@@ -36,7 +36,7 @@
#include "SilabsDeviceDataProvider.h"
#if CHIP_CONFIG_ENABLE_ICD_SERVER == 1
-#include // nogncheck
+#include // nogncheck
#endif
#include
#include
diff --git a/examples/platform/silabs/MatterConfig.cpp b/examples/platform/silabs/MatterConfig.cpp
index 1197e4d48cd83b..3a78cf774c8c5a 100644
--- a/examples/platform/silabs/MatterConfig.cpp
+++ b/examples/platform/silabs/MatterConfig.cpp
@@ -219,8 +219,9 @@ CHIP_ERROR SilabsMatterConfig::InitMatter(const char * appName)
SILABS_LOG("Failed to convert the EnableKey string to octstr type value");
memset(sTestEventTriggerEnableKey, 0, sizeof(sTestEventTriggerEnableKey));
}
- static SilabsTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ // TODO(#31723): Show to customers that they can do `Server::GetInstance().GetTestEventTriggerDelegate().AddHandler()`
+ static SilabsTestEventTriggerDelegate sTestEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
#endif // SILABS_TEST_EVENT_TRIGGER_ENABLED
#if CHIP_CRYPTO_PLATFORM && !(defined(SIWX_917))
@@ -232,8 +233,9 @@ CHIP_ERROR SilabsMatterConfig::InitMatter(const char * appName)
#ifdef PERFORMANCE_TEST_ENABLED
// Set up Test Event Trigger command of the General Diagnostics cluster. Used only in performance testing
- static SilabsTestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(kTestEventTriggerEnableKey) };
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ // TODO(#31723): Show to customers that they can do `Server::GetInstance().GetTestEventTriggerDelegate().AddHandler()`
+ static SilabsTestEventTriggerDelegate sTestEventTriggerDelegate{ ByteSpan(kTestEventTriggerEnableKey) };
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
#endif
// Initialize the remaining (not overridden) providers to the SDK example defaults
diff --git a/examples/platform/silabs/SilabsTestEventTriggerDelegate.cpp b/examples/platform/silabs/SilabsTestEventTriggerDelegate.cpp
index f231067cec851b..f9a11df74d7ae9 100644
--- a/examples/platform/silabs/SilabsTestEventTriggerDelegate.cpp
+++ b/examples/platform/silabs/SilabsTestEventTriggerDelegate.cpp
@@ -27,10 +27,4 @@ bool SilabsTestEventTriggerDelegate::DoesEnableKeyMatch(const ByteSpan & enableK
return !mEnableKey.empty() && mEnableKey.data_equal(enableKey);
}
-CHIP_ERROR SilabsTestEventTriggerDelegate::HandleEventTrigger(uint64_t eventTrigger)
-{
- bool success = emberAfHandleEventTrigger(eventTrigger);
- return success ? CHIP_NO_ERROR : CHIP_ERROR_INVALID_ARGUMENT;
-}
-
} // namespace chip
diff --git a/examples/platform/silabs/SilabsTestEventTriggerDelegate.h b/examples/platform/silabs/SilabsTestEventTriggerDelegate.h
index e9cd62fb813e50..03ceabd69a7898 100644
--- a/examples/platform/silabs/SilabsTestEventTriggerDelegate.h
+++ b/examples/platform/silabs/SilabsTestEventTriggerDelegate.h
@@ -18,14 +18,38 @@
#pragma once
+#include
+
#include
+#include
+#include
+#include
+
+/**
+ * @brief User handler for handling the test event trigger
+ *
+ * @note If TestEventTrigger is enabled, it needs to be implemented in the app
+ *
+ * @param eventTrigger Event trigger to handle
+ *
+ * @warning *** DO NOT USE FOR STANDARD CLUSTER EVENT TRIGGERS ***
+ *
+ * TODO(#31723): Rename `emberAfHandleEventTrigger` to `SilabsHandleGlobalTestEventTrigger`
+ *
+ * @retval true on success
+ * @retval false if error happened
+ */
+bool emberAfHandleEventTrigger(uint64_t eventTrigger);
namespace chip {
-class SilabsTestEventTriggerDelegate : public TestEventTriggerDelegate
+class SilabsTestEventTriggerDelegate : public TestEventTriggerDelegate, TestEventTriggerHandler
{
public:
- explicit SilabsTestEventTriggerDelegate(const ByteSpan & enableKey) : mEnableKey(enableKey) {}
+ explicit SilabsTestEventTriggerDelegate(const ByteSpan & enableKey) : mEnableKey(enableKey)
+ {
+ VerifyOrDie(AddHandler(this) == CHIP_NO_ERROR);
+ }
/**
* @brief Checks to see if `enableKey` provided matches value chosen by the manufacturer.
@@ -35,26 +59,19 @@ class SilabsTestEventTriggerDelegate : public TestEventTriggerDelegate
bool DoesEnableKeyMatch(const ByteSpan & enableKey) const override;
/**
- * @brief User handler for handling the test event trigger based on `eventTrigger` provided.
- * @param eventTrigger Event trigger to handle.
- * @return CHIP_NO_ERROR on success or CHIP_ERROR_INVALID_ARGUMENT on failure.
+ * @brief Delegates handling to global `emberAfHandleEventTrigger` function. DO NOT EXTEND.
+ *
+ * @param eventTrigger - trigger to process.
+ * @return CHIP_NO_ERROR if properly handled, else another CHIP_ERROR.
*/
- CHIP_ERROR HandleEventTrigger(uint64_t eventTrigger) override;
+ CHIP_ERROR HandleEventTrigger(uint64_t eventTrigger) override
+ {
+ // WARNING: LEGACY SUPPORT ONLY, DO NOT EXTEND FOR STANDARD CLUSTERS
+ return (emberAfHandleEventTrigger(eventTrigger)) ? CHIP_NO_ERROR : CHIP_ERROR_INVALID_ARGUMENT;
+ }
private:
ByteSpan mEnableKey;
};
} // namespace chip
-
-/**
- * @brief User handler for handling the test event trigger
- *
- * @note If TestEventTrigger is enabled, it needs to be implemented in the app
- *
- * @param eventTrigger Event trigger to handle
- *
- * @retval true on success
- * @retval false if error happened
- */
-bool emberAfHandleEventTrigger(uint64_t eventTrigger);
diff --git a/examples/providers/DeviceInfoProviderImpl.cpp b/examples/providers/DeviceInfoProviderImpl.cpp
index 5524b770c0585a..7b07561c2caf98 100644
--- a/examples/providers/DeviceInfoProviderImpl.cpp
+++ b/examples/providers/DeviceInfoProviderImpl.cpp
@@ -100,8 +100,8 @@ bool DeviceInfoProviderImpl::FixedLabelIteratorImpl::Next(FixedLabelType & outpu
VerifyOrReturnError(std::strlen(labelPtr) <= kMaxLabelNameLength, false);
VerifyOrReturnError(std::strlen(valuePtr) <= kMaxLabelValueLength, false);
- Platform::CopyString(mFixedLabelNameBuf, kMaxLabelNameLength + 1, labelPtr);
- Platform::CopyString(mFixedLabelValueBuf, kMaxLabelValueLength + 1, valuePtr);
+ Platform::CopyString(mFixedLabelNameBuf, labelPtr);
+ Platform::CopyString(mFixedLabelValueBuf, valuePtr);
output.label = CharSpan::fromCharString(mFixedLabelNameBuf);
output.value = CharSpan::fromCharString(mFixedLabelValueBuf);
diff --git a/examples/pump-app/nrfconnect/main/AppTask.cpp b/examples/pump-app/nrfconnect/main/AppTask.cpp
index fa38eba254853a..329c8d95f64beb 100644
--- a/examples/pump-app/nrfconnect/main/AppTask.cpp
+++ b/examples/pump-app/nrfconnect/main/AppTask.cpp
@@ -25,7 +25,8 @@
#include
#include
-#include
+#include
+#include
#include
#include
#include
@@ -186,9 +187,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/pump-app/silabs/README.md b/examples/pump-app/silabs/README.md
index 9a6e4e2af9be8f..56e6ad938f82db 100644
--- a/examples/pump-app/silabs/README.md
+++ b/examples/pump-app/silabs/README.md
@@ -56,8 +56,9 @@ Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools (likely already present for CHIP developers):
diff --git a/examples/pump-controller-app/nrfconnect/main/AppTask.cpp b/examples/pump-controller-app/nrfconnect/main/AppTask.cpp
index db96480e5acb9d..ca79a41160a9d2 100644
--- a/examples/pump-controller-app/nrfconnect/main/AppTask.cpp
+++ b/examples/pump-controller-app/nrfconnect/main/AppTask.cpp
@@ -25,7 +25,8 @@
#include
#include
-#include
+#include
+#include
#include
#include
#include
@@ -184,9 +185,12 @@ CHIP_ERROR AppTask::Init()
#endif
static CommonCaseDeviceServerInitParams initParams;
- static OTATestEventTriggerDelegate testEventTriggerDelegate{ ByteSpan(sTestEventTriggerEnableKey) };
+ static SimpleTestEventTriggerDelegate sTestEventTriggerDelegate{};
+ static OTATestEventTriggerHandler sOtaTestEventTriggerHandler{};
+ VerifyOrDie(sTestEventTriggerDelegate.Init(ByteSpan(sTestEventTriggerEnableKey)) == CHIP_NO_ERROR);
+ VerifyOrDie(sTestEventTriggerDelegate.AddHandler(&sOtaTestEventTriggerHandler) == CHIP_NO_ERROR);
(void) initParams.InitializeStaticResourcesBeforeServerInit();
- initParams.testEventTriggerDelegate = &testEventTriggerDelegate;
+ initParams.testEventTriggerDelegate = &sTestEventTriggerDelegate;
ReturnErrorOnFailure(chip::Server::GetInstance().Init(initParams));
AppFabricTableDelegate::Init();
diff --git a/examples/rvc-app/rvc-common/rvc-app.matter b/examples/rvc-app/rvc-common/rvc-app.matter
index 4089d016fd603f..6ed9387af4a2db 100644
--- a/examples/rvc-app/rvc-common/rvc-app.matter
+++ b/examples/rvc-app/rvc-common/rvc-app.matter
@@ -943,7 +943,7 @@ cluster RvcRunMode = 84 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -959,7 +959,6 @@ cluster RvcRunMode = 84 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -996,7 +995,7 @@ cluster RvcCleanMode = 85 {
}
bitmap Feature : bitmap32 {
- kOnOff = 0x1;
+ kNoFeatures = 0x0;
}
struct ModeTagStruct {
@@ -1012,7 +1011,6 @@ cluster RvcCleanMode = 85 {
readonly attribute ModeOptionStruct supportedModes[] = 0;
readonly attribute int8u currentMode = 1;
- attribute optional nullable int8u onMode = 3;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
@@ -1095,10 +1093,6 @@ cluster RvcOperationalState = 97 {
/** Upon receipt, the device SHALL pause its operation if it is possible based on the current function of the server. */
command Pause(): OperationalCommandResponse = 0;
- /** Upon receipt, the device SHALL stop its operation if it is at a position where it is safe to do so and/or permitted. */
- command Stop(): OperationalCommandResponse = 1;
- /** Upon receipt, the device SHALL start its operation if it is safe to do so and the device is in an operational state from which it can be started. */
- command Start(): OperationalCommandResponse = 2;
/** Upon receipt, the device SHALL resume its operation from the point it was at when it received the Pause command, or from the point when it was paused by means outside of this cluster (for example by manual button press). */
command Resume(): OperationalCommandResponse = 3;
/** On receipt of this command, the device SHALL start seeking the charging dock, if possible in the current state of the device. */
diff --git a/examples/shell/shell_common/cmd_otcli.cpp b/examples/shell/shell_common/cmd_otcli.cpp
index 590fda96e16fae..98736c2cb4215d 100644
--- a/examples/shell/shell_common/cmd_otcli.cpp
+++ b/examples/shell/shell_common/cmd_otcli.cpp
@@ -48,6 +48,7 @@ static char sTxBuffer[SHELL_OTCLI_TX_BUFFER_SIZE];
static constexpr uint16_t sTxLength = SHELL_OTCLI_TX_BUFFER_SIZE;
#endif // !CHIP_DEVICE_CONFIG_THREAD_ENABLE_CLI)
#endif
+static constexpr uint16_t kMaxLineLength = 384;
#else
#include
#include
@@ -81,8 +82,6 @@ CHIP_ERROR cmd_otcli_dispatch(int argc, char ** argv)
{
CHIP_ERROR error = CHIP_NO_ERROR;
-// From OT CLI internal lib, kMaxLineLength = 128
-#define kMaxLineLength 128
char buff[kMaxLineLength] = { 0 };
char * buff_ptr = buff;
int i = 0;
diff --git a/examples/smoke-co-alarm-app/silabs/README.md b/examples/smoke-co-alarm-app/silabs/README.md
index d62ba82bc59ab4..b5548b69f24f54 100644
--- a/examples/smoke-co-alarm-app/silabs/README.md
+++ b/examples/smoke-co-alarm-app/silabs/README.md
@@ -18,6 +18,7 @@ An example showing the use of CHIP on the Silicon Labs EFR32 MG12 and MG24.
- [Debug build / release build](#debug-build--release-build)
- [Disabling LCD](#disabling-lcd)
- [KVS maximum entry count](#kvs-maximum-entry-count)
+ - [Enabling test event trigger](#enabling-test-event-trigger)
@@ -54,8 +55,9 @@ Silicon Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools(likely already present for CHIP developers):
diff --git a/examples/smoke-co-alarm-app/silabs/src/SmokeCoAlarmManager.cpp b/examples/smoke-co-alarm-app/silabs/src/SmokeCoAlarmManager.cpp
index 85c8bca2193a67..7d64a036371a6f 100644
--- a/examples/smoke-co-alarm-app/silabs/src/SmokeCoAlarmManager.cpp
+++ b/examples/smoke-co-alarm-app/silabs/src/SmokeCoAlarmManager.cpp
@@ -21,7 +21,7 @@
#include "AppTask.h"
#include
-#include
+#include
#include
using namespace chip;
diff --git a/examples/thermostat/qpg/BUILD.gn b/examples/thermostat/qpg/BUILD.gn
index d4285571114721..9989e349fc6c86 100644
--- a/examples/thermostat/qpg/BUILD.gn
+++ b/examples/thermostat/qpg/BUILD.gn
@@ -51,7 +51,7 @@ qpg_executable("thermostat") {
output_name = "chip-${qpg_target_ic}-thermostat-example.out"
sources = [
- "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerDelegate.cpp",
+ "${chip_root}/src/app/clusters/general-diagnostics-server/GenericFaultTestEventTriggerHandler.cpp",
"${examples_plat_dir}/app/main.cpp",
"${examples_plat_dir}/ota/ota.cpp",
"src/AppTask.cpp",
diff --git a/examples/thermostat/silabs/README.md b/examples/thermostat/silabs/README.md
index 0d9c760c5821c6..3440277c64dfee 100644
--- a/examples/thermostat/silabs/README.md
+++ b/examples/thermostat/silabs/README.md
@@ -59,8 +59,9 @@ Silicon Labs platform.
(For Mac OS X, `commander` is located inside
`Commander.app/Contents/MacOS/`.)
-- Download and install a suitable ARM gcc tool chain:
- [GNU Arm Embedded Toolchain 9-2019-q4-major](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
+- Download and install a suitable ARM gcc tool chain (For most Host, the
+ bootstrap already installs the toolchain):
+ [GNU Arm Embedded Toolchain 12.2 Rel1](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads)
- Install some additional tools(likely already present for CHIP developers):
diff --git a/examples/tv-app/android/BUILD.gn b/examples/tv-app/android/BUILD.gn
index 0793b7d2993ef8..63de5a515b0754 100644
--- a/examples/tv-app/android/BUILD.gn
+++ b/examples/tv-app/android/BUILD.gn
@@ -33,8 +33,6 @@ shared_library("jni") {
"include/audio-output/AudioOutputManager.cpp",
"include/audio-output/AudioOutputManager.h",
"include/cluster-init.cpp",
- "include/content-app-observer/ContentAppObserver.cpp",
- "include/content-app-observer/ContentAppObserver.h",
"include/content-control/ContentController.cpp",
"include/content-control/ContentController.h",
"include/content-launcher/AppContentLauncherManager.cpp",
@@ -118,6 +116,8 @@ android_library("java") {
"java/src/com/matter/tv/server/tvapp/ChannelLineupInfo.java",
"java/src/com/matter/tv/server/tvapp/ChannelManager.java",
"java/src/com/matter/tv/server/tvapp/ChannelManagerStub.java",
+ "java/src/com/matter/tv/server/tvapp/ChannelProgramInfo.java",
+ "java/src/com/matter/tv/server/tvapp/ChannelProgramResponse.java",
"java/src/com/matter/tv/server/tvapp/Clusters.java",
"java/src/com/matter/tv/server/tvapp/ContentAppEndpointManager.java",
"java/src/com/matter/tv/server/tvapp/ContentLaunchBrandingInformation.java",
@@ -142,6 +142,7 @@ android_library("java") {
"java/src/com/matter/tv/server/tvapp/MediaPlaybackManager.java",
"java/src/com/matter/tv/server/tvapp/MediaPlaybackManagerStub.java",
"java/src/com/matter/tv/server/tvapp/MediaPlaybackPosition.java",
+ "java/src/com/matter/tv/server/tvapp/MediaTrack.java",
"java/src/com/matter/tv/server/tvapp/OnOffManager.java",
"java/src/com/matter/tv/server/tvapp/OnOffManagerStub.java",
"java/src/com/matter/tv/server/tvapp/TvApp.java",
diff --git a/examples/tv-app/android/java/AppImpl.h b/examples/tv-app/android/java/AppImpl.h
index 7d6bf20c7bb37c..7c0537242657ca 100644
--- a/examples/tv-app/android/java/AppImpl.h
+++ b/examples/tv-app/android/java/AppImpl.h
@@ -35,7 +35,6 @@
#include "../include/account-login/AccountLoginManager.h"
#include "../include/application-basic/ApplicationBasicManager.h"
#include "../include/application-launcher/ApplicationLauncherManager.h"
-#include "../include/content-app-observer/ContentAppObserver.h"
#include "../include/content-control/ContentController.h"
#include "../include/content-launcher/AppContentLauncherManager.h"
#include "../include/media-playback/AppMediaPlaybackManager.h"
@@ -49,7 +48,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -76,7 +74,6 @@ using ApplicationBasicDelegate = app::Clusters::ApplicationBasic::Delegate;
using ApplicationLauncherDelegate = app::Clusters::ApplicationLauncher::Delegate;
using ChannelDelegate = app::Clusters::Channel::Delegate;
using ContentLauncherDelegate = app::Clusters::ContentLauncher::Delegate;
-using ContentAppObserverDelegate = app::Clusters::ContentAppObserver::Delegate;
using ContentControlDelegate = app::Clusters::ContentControl::Delegate;
using KeypadInputDelegate = app::Clusters::KeypadInput::Delegate;
using MediaPlaybackDelegate = app::Clusters::MediaPlayback::Delegate;
@@ -118,11 +115,6 @@ class DLL_EXPORT ContentAppImpl : public ContentApp
mContentLauncherDelegate.SetEndpointId(GetEndpointId());
return &mContentLauncherDelegate;
};
- ContentAppObserverDelegate * GetContentAppObserverDelegate() override
- {
- mContentAppObserverDelegate.SetEndpointId(GetEndpointId());
- return &mContentAppObserverDelegate;
- };
ContentControlDelegate * GetContentControlDelegate() override
{
mContentControlDelegate.SetEndpointId(GetEndpointId());
@@ -146,7 +138,6 @@ class DLL_EXPORT ContentAppImpl : public ContentApp
ApplicationLauncherManager mApplicationLauncherDelegate;
ChannelManager mChannelDelegate;
ContentController mContentControlDelegate;
- ContentAppObserver mContentAppObserverDelegate;
AppContentLauncherManager mContentLauncherDelegate;
KeypadInputManager mKeypadInputDelegate;
AppMediaPlaybackManager mMediaPlaybackDelegate;
diff --git a/examples/tv-app/android/java/ChannelManager.cpp b/examples/tv-app/android/java/ChannelManager.cpp
index 586e56bf99b27f..d471bebf3075f6 100644
--- a/examples/tv-app/android/java/ChannelManager.cpp
+++ b/examples/tv-app/android/java/ChannelManager.cpp
@@ -59,11 +59,12 @@ CHIP_ERROR ChannelManager::HandleGetChannelList(AttributeValueEncoder & aEncoder
{
CHIP_ERROR err = CHIP_NO_ERROR;
JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();
+ VerifyOrReturnError(env != nullptr, CHIP_JNI_ERROR_NULL_OBJECT, ChipLogError(Zcl, "Could not get JNIEnv for current thread"));
+ JniLocalReferenceScope scope(env);
ChipLogProgress(Zcl, "Received ChannelManager::HandleGetChannelList");
VerifyOrExit(mChannelManagerObject != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
VerifyOrExit(mGetChannelListMethod != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
- VerifyOrExit(env != NULL, err = CHIP_JNI_ERROR_NO_ENV);
return aEncoder.EncodeList([this, env](const auto & encoder) -> CHIP_ERROR {
jobjectArray channelInfoList = (jobjectArray) env->CallObjectMethod(mChannelManagerObject, mGetChannelListMethod);
@@ -135,11 +136,12 @@ CHIP_ERROR ChannelManager::HandleGetLineup(AttributeValueEncoder & aEncoder)
chip::app::Clusters::Channel::Structs::LineupInfoStruct::Type lineupInfo;
CHIP_ERROR err = CHIP_NO_ERROR;
JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();
+ VerifyOrReturnError(env != nullptr, CHIP_JNI_ERROR_NULL_OBJECT, ChipLogError(Zcl, "Could not get JNIEnv for current thread"));
+ JniLocalReferenceScope scope(env);
ChipLogProgress(Zcl, "Received ChannelManager::HandleGetLineup");
VerifyOrExit(mChannelManagerObject != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
VerifyOrExit(mGetLineupMethod != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
- VerifyOrExit(env != NULL, err = CHIP_JNI_ERROR_NO_ENV);
{
jobject channelLineupObject = env->CallObjectMethod(mChannelManagerObject, mGetLineupMethod);
@@ -197,10 +199,12 @@ CHIP_ERROR ChannelManager::HandleGetCurrentChannel(AttributeValueEncoder & aEnco
chip::app::Clusters::Channel::Structs::ChannelInfoStruct::Type channelInfo;
CHIP_ERROR err = CHIP_NO_ERROR;
JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();
+ VerifyOrReturnError(env != nullptr, CHIP_JNI_ERROR_NULL_OBJECT, ChipLogError(Zcl, "Could not get JNIEnv for current thread"));
+ JniLocalReferenceScope scope(env);
+
ChipLogProgress(Zcl, "Received ChannelManager::HandleGetCurrentChannel");
VerifyOrExit(mChannelManagerObject != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
VerifyOrExit(mGetCurrentChannelMethod != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
- VerifyOrExit(env != NULL, err = CHIP_JNI_ERROR_NO_ENV);
{
jobject channelInfoObject = env->CallObjectMethod(mChannelManagerObject, mGetCurrentChannelMethod);
@@ -232,6 +236,14 @@ CHIP_ERROR ChannelManager::HandleGetCurrentChannel(AttributeValueEncoder & aEnco
channelInfo.affiliateCallSign = Optional(affiliateCallSign.charSpan());
}
+ jfieldID getJidentifierField = env->GetFieldID(channelClass, "identifier", "Ljava/lang/String;");
+ jstring jidentifier = static_cast(env->GetObjectField(channelInfoObject, getJidentifierField));
+ JniUtfString identifier(env, jidentifier);
+ if (jidentifier != nullptr)
+ {
+ channelInfo.identifier = Optional(identifier.charSpan());
+ }
+
jfieldID majorNumField = env->GetFieldID(channelClass, "majorNumber", "I");
jint jmajorNum = env->GetIntField(channelInfoObject, majorNumField);
channelInfo.majorNumber = static_cast(jmajorNum);
@@ -262,11 +274,12 @@ void ChannelManager::HandleChangeChannel(CommandResponseHelperExceptionClear();
@@ -334,11 +348,12 @@ bool ChannelManager::HandleSkipChannel(const int16_t & count)
{
jboolean ret = JNI_FALSE;
JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();
+ VerifyOrReturnValue(env != nullptr, false, ChipLogError(Zcl, "Could not get JNIEnv for current thread"));
+ JniLocalReferenceScope scope(env);
ChipLogProgress(Zcl, "Received ChannelManager::HandleSkipChannel count %d", count);
VerifyOrExit(mChannelManagerObject != nullptr, ChipLogError(Zcl, "mChannelManagerObject null"));
VerifyOrExit(mSkipChannelMethod != nullptr, ChipLogError(Zcl, "mSkipChannelMethod null"));
- VerifyOrExit(env != NULL, ChipLogError(Zcl, "env null"));
env->ExceptionClear();
@@ -363,30 +378,286 @@ void ChannelManager::HandleGetProgramGuide(
const chip::Optional> & externalIdList,
const chip::Optional & data)
{
-
- // 1. Decode received parameters
- // 2. Perform search
- // 3. Return results
ProgramGuideResponseType response;
- // response.channelPagingStruct;
- // response.programList;
- helper.Success(response);
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNIEnv for current thread"));
+ JniLocalReferenceScope scope(env);
+
+ std::vector needToFreePrograms;
+ std::vector needToFreeChannels;
+ std::vector tempPrograms;
+ std::vector needToFreeStrings;
+
+ ChipLogProgress(Zcl, "Received ChannelManager::HandleGetProgramGuide");
+ VerifyOrExit(mChannelManagerObject != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
+ VerifyOrExit(mGetProgramGuideMethod != nullptr, err = CHIP_ERROR_INCORRECT_STATE);
+
+ {
+ // NOTE: this example app does not pass the Data, PageToken, ChannelsArray or ExternalIdList through to the Java layer
+ UtfString jData(env, "");
+ UtfString jToken(env, "");
+ jobjectArray channelsArray = nullptr;
+ jobjectArray externalIDListArray = (jobjectArray) env->NewObjectArray(0, env->FindClass("java/util/Map$Entry"), NULL);
+
+ jobject resp = env->CallObjectMethod(
+ mChannelManagerObject, mGetProgramGuideMethod, static_cast(startTime.ValueOr(0)),
+ static_cast(endTime.ValueOr(0)), channelsArray, jToken.jniValue(),
+ static_cast(recordingFlag.ValueOr(0).Raw() != 0), externalIDListArray, jData.jniValue());
+ if (env->ExceptionCheck())
+ {
+ ChipLogError(Zcl, "Java exception in ChannelManager::HandleGetProgramGuide");
+ env->ExceptionDescribe();
+ env->ExceptionClear();
+ err = CHIP_ERROR_INCORRECT_STATE;
+ goto exit;
+ }
+
+ VerifyOrExit(resp != nullptr, err = CHIP_JNI_ERROR_NULL_OBJECT);
+ jclass respCls = env->GetObjectClass(resp);
+ jfieldID programsFid = env->GetFieldID(respCls, "programs", "[Lcom/matter/tv/server/tvapp/ChannelProgramInfo;");
+ VerifyOrExit(programsFid != nullptr, err = CHIP_JNI_ERROR_FIELD_NOT_FOUND);
+
+ jobjectArray programsArray = (jobjectArray) env->GetObjectField(resp, programsFid);
+ jint size = env->GetArrayLength(programsArray);
+ for (jint i = 0; i < size; i++)
+ {
+ ProgramType * program = new ProgramType();
+ VerifyOrExit(program != nullptr, err = CHIP_ERROR_NO_MEMORY);
+
+ jobject programObject = env->GetObjectArrayElement(programsArray, i);
+ jclass programClass = env->GetObjectClass(programObject);
+
+ jfieldID getIdentifierField = env->GetFieldID(programClass, "identifier", "Ljava/lang/String;");
+ jstring jidentifier = static_cast